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
b8f22f47
Commit
b8f22f47
authored
Jan 10, 2014
by
Akihiro Sagawa
Committed by
Alexandre Julliard
Jan 13, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32/tests: Add more GetCharABCWidths tests for rotated font.
parent
e9188970
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
1 deletion
+26
-1
font.c
dlls/gdi32/tests/font.c
+26
-1
No files found.
dlls/gdi32/tests/font.c
View file @
b8f22f47
...
...
@@ -1300,7 +1300,7 @@ static void test_GetCharABCWidths(void)
memset
(
&
lf
,
0
,
sizeof
(
lf
));
strcpy
(
lf
.
lfFaceName
,
"Tahoma"
);
lf
.
lfHeight
=
20
;
lf
.
lfHeight
=
20
0
;
hfont
=
CreateFontIndirectA
(
&
lf
);
/* test empty glyph's metrics */
...
...
@@ -1312,10 +1312,35 @@ static void test_GetCharABCWidths(void)
ok
(
ret
,
"GetCharABCWidthsW should have succeeded
\n
"
);
ok
(
abcw
[
0
].
abcB
==
1
,
"got %u
\n
"
,
abcw
[
0
].
abcB
);
/* 1) prepare unrotated font metrics */
ret
=
pGetCharABCWidthsW
(
hdc
,
'a'
,
'a'
,
abcw
);
ok
(
ret
,
"GetCharABCWidthsW should have succeeded
\n
"
);
DeleteObject
(
SelectObject
(
hdc
,
hfont
));
/* 2) get rotated font metrics */
lf
.
lfEscapement
=
lf
.
lfOrientation
=
900
;
hfont
=
CreateFontIndirectA
(
&
lf
);
hfont
=
SelectObject
(
hdc
,
hfont
);
ret
=
pGetCharABCWidthsW
(
hdc
,
'a'
,
'a'
,
abc
);
ok
(
ret
,
"GetCharABCWidthsW should have succeeded
\n
"
);
/* 3) compare ABC results */
todo_wine
{
ok
(
match_off_by_1
(
abcw
[
0
].
abcA
,
abc
[
0
].
abcA
,
FALSE
),
"got %d, expected %d (A)
\n
"
,
abc
[
0
].
abcA
,
abcw
[
0
].
abcA
);
ok
(
match_off_by_1
(
abcw
[
0
].
abcB
,
abc
[
0
].
abcB
,
FALSE
),
"got %d, expected %d (B)
\n
"
,
abc
[
0
].
abcB
,
abcw
[
0
].
abcB
);
ok
(
match_off_by_1
(
abcw
[
0
].
abcC
,
abc
[
0
].
abcC
,
FALSE
),
"got %d, expected %d (C)
\n
"
,
abc
[
0
].
abcC
,
abcw
[
0
].
abcC
);
}
DeleteObject
(
SelectObject
(
hdc
,
hfont
));
ReleaseDC
(
NULL
,
hdc
);
trace
(
"ABC sign test for a variety of transforms:
\n
"
);
memset
(
&
lf
,
0
,
sizeof
(
lf
));
strcpy
(
lf
.
lfFaceName
,
"Tahoma"
);
lf
.
lfHeight
=
20
;
hfont
=
CreateFontIndirectA
(
&
lf
);
hwnd
=
CreateWindowExA
(
0
,
"static"
,
""
,
WS_POPUP
,
0
,
0
,
100
,
100
,
0
,
0
,
0
,
NULL
);
...
...
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