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
bf9aed6f
Commit
bf9aed6f
authored
May 15, 2012
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
May 15, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdiplus: Measure the passed in string without height clipping in order to compute correct Y offset.
parent
c4368874
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
graphics.c
dlls/gdiplus/graphics.c
+6
-2
No files found.
dlls/gdiplus/graphics.c
View file @
bf9aed6f
...
...
@@ -5161,14 +5161,18 @@ GpStatus WINGDIPAPI GdipDrawString(GpGraphics *graphics, GDIPCONST WCHAR *string
/* Should be no need to explicitly test for StringAlignmentNear as
* that is default behavior if no alignment is passed. */
if
(
format
->
vertalign
!=
StringAlignmentNear
){
RectF
bounds
;
GdipMeasureString
(
graphics
,
string
,
length
,
font
,
rect
,
format
,
&
bounds
,
0
,
0
);
RectF
bounds
,
in_rect
=
*
rect
;
in_rect
.
Height
=
0
.
0
;
/* avoid height clipping */
GdipMeasureString
(
graphics
,
string
,
length
,
font
,
&
in_rect
,
format
,
&
bounds
,
0
,
0
);
TRACE
(
"bounds %s
\n
"
,
debugstr_rectf
(
&
bounds
));
if
(
format
->
vertalign
==
StringAlignmentCenter
)
offsety
=
(
rect
->
Height
-
bounds
.
Height
)
/
2
;
else
if
(
format
->
vertalign
==
StringAlignmentFar
)
offsety
=
(
rect
->
Height
-
bounds
.
Height
);
}
TRACE
(
"vertical align %d, offsety %f
\n
"
,
format
->
vertalign
,
offsety
);
}
save_state
=
SaveDC
(
hdc
);
...
...
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