Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
a71f25d2
Commit
a71f25d2
authored
Oct 09, 2014
by
Matteo Bruni
Committed by
Alexandre Julliard
Oct 09, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32/tests: Add a test for GetGlyphOutline with an insufficient buffer.
parent
112a7f7f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
font.c
dlls/gdi32/tests/font.c
+12
-0
No files found.
dlls/gdi32/tests/font.c
View file @
a71f25d2
...
...
@@ -4365,7 +4365,11 @@ static void test_GetGlyphOutline(void)
SetLastError
(
0xdeadbeef
);
ret
=
GetGlyphOutlineW
(
hdc
,
' '
,
GGO_NATIVE
,
&
gm
,
0
,
NULL
,
&
mat
);
if
(
GetLastError
()
!=
ERROR_CALL_NOT_IMPLEMENTED
)
{
ok
(
ret
==
0
,
"GetGlyphOutlineW should return 0 buffer size for space char
\n
"
);
ok
(
gm
.
gmBlackBoxX
==
1
,
"Expected 1, got %u
\n
"
,
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"Expected 1, got %u
\n
"
,
gm
.
gmBlackBoxY
);
}
/* requesting buffer size for space char + error */
memset
(
&
gm
,
0
,
sizeof
(
gm
));
...
...
@@ -4375,8 +4379,16 @@ static void test_GetGlyphOutline(void)
{
ok
(
ret
==
GDI_ERROR
,
"GetGlyphOutlineW should return GDI_ERROR
\n
"
);
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
ok
(
gm
.
gmBlackBoxX
==
0
,
"Expected 0, got %u
\n
"
,
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxY
==
0
,
"Expected 0, got %u
\n
"
,
gm
.
gmBlackBoxY
);
}
/* test GetGlyphOutline with a buffer too small */
SetLastError
(
0xdeadbeef
);
ret
=
GetGlyphOutlineA
(
hdc
,
'A'
,
GGO_NATIVE
,
&
gm
,
sizeof
(
i
),
&
i
,
&
mat
);
if
(
GetLastError
()
!=
ERROR_CALL_NOT_IMPLEMENTED
)
ok
(
ret
==
GDI_ERROR
,
"GetGlyphOutlineW should return an error when the buffer size is too small.
\n
"
);
for
(
i
=
0
;
i
<
sizeof
(
fmt
)
/
sizeof
(
fmt
[
0
]);
++
i
)
{
DWORD
dummy
;
...
...
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