Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
b8e3fbe0
Commit
b8e3fbe0
authored
Jun 04, 2015
by
Nikolay Sivov
Committed by
Alexandre Julliard
Jun 05, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dwrite: Report strikethrough ranges to renderer.
parent
e31881a6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
127 additions
and
29 deletions
+127
-29
layout.c
dlls/dwrite/layout.c
+103
-28
layout.c
dlls/dwrite/tests/layout.c
+24
-1
No files found.
dlls/dwrite/layout.c
View file @
b8e3fbe0
This diff is collapsed.
Click to expand it.
dlls/dwrite/tests/layout.c
View file @
b8e3fbe0
...
...
@@ -1156,6 +1156,14 @@ static const struct drawcall_entry draw_seq4[] = {
{
DRAW_LAST_KIND
}
};
static
const
struct
drawcall_entry
draw_seq5
[]
=
{
{
DRAW_GLYPHRUN
,
{
's'
,
't'
,
0
}
},
{
DRAW_GLYPHRUN
,
{
'r'
,
'i'
,
0
}
},
{
DRAW_GLYPHRUN
,
{
'n'
,
'g'
,
0
}
},
{
DRAW_STRIKETHROUGH
},
{
DRAW_LAST_KIND
}
};
static
void
test_Draw
(
void
)
{
static
const
WCHAR
strW
[]
=
{
's'
,
't'
,
'r'
,
'i'
,
'n'
,
'g'
,
0
};
...
...
@@ -1238,7 +1246,22 @@ static void test_Draw(void)
hr
=
IDWriteTextLayout_Draw
(
layout
,
NULL
,
&
testrenderer
,
0
.
0
,
0
.
0
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
ok_sequence
(
sequences
,
RENDERER_ID
,
draw_seq4
,
"draw test 4"
,
TRUE
);
ok_sequence
(
sequences
,
RENDERER_ID
,
draw_seq4
,
"draw test 4"
,
FALSE
);
IDWriteTextLayout_Release
(
layout
);
/* strikethrough somewhere in the middle */
hr
=
IDWriteFactory_CreateTextLayout
(
factory
,
strW
,
6
,
format
,
500
.
0
,
100
.
0
,
&
layout
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
flush_sequence
(
sequences
,
RENDERER_ID
);
range
.
startPosition
=
2
;
range
.
length
=
2
;
hr
=
IDWriteTextLayout_SetStrikethrough
(
layout
,
TRUE
,
range
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
hr
=
IDWriteTextLayout_Draw
(
layout
,
NULL
,
&
testrenderer
,
0
.
0
,
0
.
0
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
ok_sequence
(
sequences
,
RENDERER_ID
,
draw_seq5
,
"draw test 5"
,
FALSE
);
IDWriteTextLayout_Release
(
layout
);
IDWriteTextFormat_Release
(
format
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment