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
c7e860d4
Commit
c7e860d4
authored
Dec 01, 2005
by
Rein Klazes
Committed by
Alexandre Julliard
Dec 01, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make WineEngGetFontData always return the used byte count.
parent
724981bf
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
2 deletions
+14
-2
freetype.c
dlls/gdi/freetype.c
+14
-2
No files found.
dlls/gdi/freetype.c
View file @
c7e860d4
...
...
@@ -3692,9 +3692,15 @@ DWORD WineEngGetFontData(GdiFont font, DWORD table, DWORD offset, LPVOID buf,
}
/* If the FT_Load_Sfnt_Table function is there we'll use it */
if
(
pFT_Load_Sfnt_Table
)
if
(
pFT_Load_Sfnt_Table
)
{
/* make sure value of len is the value freetype says it needs */
if
(
buf
&&
len
)
{
DWORD
needed
=
0
;
err
=
pFT_Load_Sfnt_Table
(
ft_face
,
table
,
offset
,
NULL
,
&
needed
);
if
(
!
err
&&
needed
<
len
)
len
=
needed
;
}
err
=
pFT_Load_Sfnt_Table
(
ft_face
,
table
,
offset
,
buf
,
&
len
);
else
{
/* Do it the hard way */
}
else
{
/* Do it the hard way */
TT_Face
tt_face
=
(
TT_Face
)
ft_face
;
SFNT_Interface
*
sfnt
;
if
(
FT_Version
.
major
==
2
&&
FT_Version
.
minor
==
0
)
...
...
@@ -3707,6 +3713,12 @@ DWORD WineEngGetFontData(GdiFont font, DWORD table, DWORD offset, LPVOID buf,
/* A field was added in the middle of the structure in 2.1.x */
sfnt
=
*
(
SFNT_Interface
**
)((
char
*
)
tt_face
+
532
);
}
/* make sure value of len is the value freetype says it needs */
if
(
buf
&&
len
)
{
DWORD
needed
=
0
;
err
=
sfnt
->
load_any
(
tt_face
,
table
,
offset
,
NULL
,
&
needed
);
if
(
!
err
&&
needed
<
len
)
len
=
needed
;
}
err
=
sfnt
->
load_any
(
tt_face
,
table
,
offset
,
buf
,
&
len
);
}
if
(
err
)
{
...
...
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