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
db86409d
Commit
db86409d
authored
Oct 01, 2013
by
Akihiro Sagawa
Committed by
Alexandre Julliard
Oct 01, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Return fake BBox when requesting empty glyph metrics.
parent
b138c36c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
18 deletions
+10
-18
freetype.c
dlls/gdi32/freetype.c
+2
-2
font.c
dlls/gdi32/tests/font.c
+8
-16
No files found.
dlls/gdi32/freetype.c
View file @
db86409d
...
@@ -6520,8 +6520,8 @@ static DWORD get_glyph_outline(GdiFont *incoming_font, UINT glyph, UINT format,
...
@@ -6520,8 +6520,8 @@ static DWORD get_glyph_outline(GdiFont *incoming_font, UINT glyph, UINT format,
width
=
(
right
-
left
)
>>
6
;
width
=
(
right
-
left
)
>>
6
;
height
=
(
top
-
bottom
)
>>
6
;
height
=
(
top
-
bottom
)
>>
6
;
lpgm
->
gmBlackBoxX
=
width
;
lpgm
->
gmBlackBoxX
=
width
?
width
:
1
;
lpgm
->
gmBlackBoxY
=
height
;
lpgm
->
gmBlackBoxY
=
height
?
height
:
1
;
lpgm
->
gmptGlyphOrigin
.
x
=
origin_x
>>
6
;
lpgm
->
gmptGlyphOrigin
.
x
=
origin_x
>>
6
;
lpgm
->
gmptGlyphOrigin
.
y
=
origin_y
>>
6
;
lpgm
->
gmptGlyphOrigin
.
y
=
origin_y
>>
6
;
abc
->
abcA
=
left
>>
6
;
abc
->
abcA
=
left
>>
6
;
...
...
dlls/gdi32/tests/font.c
View file @
db86409d
...
@@ -4120,10 +4120,8 @@ static void test_GetGlyphOutline(void)
...
@@ -4120,10 +4120,8 @@ static void test_GetGlyphOutline(void)
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
else
else
ok
(
ret
==
0
,
"%2d:GetGlyphOutlineW should return 0, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
==
0
,
"%2d:GetGlyphOutlineW should return 0, got %d
\n
"
,
fmt
[
i
],
ret
);
todo_wine
{
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
}
}
}
memset
(
&
gm
,
0xab
,
sizeof
(
gm
));
memset
(
&
gm
,
0xab
,
sizeof
(
gm
));
...
@@ -4135,10 +4133,8 @@ static void test_GetGlyphOutline(void)
...
@@ -4135,10 +4133,8 @@ static void test_GetGlyphOutline(void)
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
else
else
ok
(
ret
==
0
,
"%2d:GetGlyphOutlineW should return 0, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
==
0
,
"%2d:GetGlyphOutlineW should return 0, got %d
\n
"
,
fmt
[
i
],
ret
);
todo_wine
{
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
}
}
}
memset
(
&
gm
,
0xab
,
sizeof
(
gm
));
memset
(
&
gm
,
0xab
,
sizeof
(
gm
));
...
@@ -4150,10 +4146,8 @@ static void test_GetGlyphOutline(void)
...
@@ -4150,10 +4146,8 @@ static void test_GetGlyphOutline(void)
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
else
else
ok
(
ret
==
0
,
"%2d:GetGlyphOutlineW should return 0, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
==
0
,
"%2d:GetGlyphOutlineW should return 0, got %d
\n
"
,
fmt
[
i
],
ret
);
todo_wine
{
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
}
}
}
memset
(
&
gm
,
0xab
,
sizeof
(
gm
));
memset
(
&
gm
,
0xab
,
sizeof
(
gm
));
...
@@ -4163,10 +4157,8 @@ static void test_GetGlyphOutline(void)
...
@@ -4163,10 +4157,8 @@ static void test_GetGlyphOutline(void)
{
{
if
(
fmt
[
i
]
==
GGO_METRICS
)
{
if
(
fmt
[
i
]
==
GGO_METRICS
)
{
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
!=
GDI_ERROR
,
"%2d:GetGlyphOutlineW should succeed, got %d
\n
"
,
fmt
[
i
],
ret
);
todo_wine
{
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxX
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxX
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
ok
(
gm
.
gmBlackBoxY
==
1
,
"%2d:expected 1, got %u
\n
"
,
fmt
[
i
],
gm
.
gmBlackBoxY
);
}
}
}
else
else
ok
(
ret
==
GDI_ERROR
,
"%2d:GetGlyphOutlineW should return GDI_ERROR, got %d
\n
"
,
fmt
[
i
],
ret
);
ok
(
ret
==
GDI_ERROR
,
"%2d:GetGlyphOutlineW should return GDI_ERROR, got %d
\n
"
,
fmt
[
i
],
ret
);
...
...
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