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
691c37ca
Commit
691c37ca
authored
Feb 16, 2012
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Fix font orientation when mirroring in compatible mode.
Inspired by a patch from Alexander Kochetkov.
parent
2b7d8311
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
9 deletions
+20
-9
freetype.c
dlls/gdi32/freetype.c
+17
-9
xrender.c
dlls/winex11.drv/xrender.c
+3
-0
No files found.
dlls/gdi32/freetype.c
View file @
691c37ca
...
...
@@ -3946,21 +3946,29 @@ static HFONT freetype_SelectFont( PHYSDEV dev, HFONT hfont )
lf
.
lfEscapement
);
if
(
dc
->
GraphicsMode
==
GM_ADVANCED
)
{
memcpy
(
&
dcmat
,
&
dc
->
xformWorld2Vport
,
sizeof
(
FMAT2
));
/* Try to avoid not necessary glyph transformations */
if
(
dcmat
.
eM21
==
0
.
0
&&
dcmat
.
eM12
==
0
.
0
&&
dcmat
.
eM11
==
dcmat
.
eM22
)
{
lf
.
lfHeight
*=
fabs
(
dcmat
.
eM11
);
lf
.
lfWidth
*=
fabs
(
dcmat
.
eM11
);
dcmat
.
eM11
=
dcmat
.
eM22
=
1
.
0
;
}
}
else
{
/* Windows 3.1 compatibility mode GM_COMPATIBLE has only limited
font scaling abilities. */
dcmat
.
eM11
=
dcmat
.
eM22
=
dc
->
vport2WorldValid
?
fabs
(
dc
->
xformWorld2Vport
.
eM22
)
:
1
.
0
;
dcmat
.
eM21
=
dcmat
.
eM12
=
0
;
}
/* Try to avoid not necessary glyph transformations */
if
(
dcmat
.
eM21
==
0
.
0
&&
dcmat
.
eM12
==
0
.
0
&&
dcmat
.
eM11
==
dcmat
.
eM22
)
{
lf
.
lfHeight
*=
fabs
(
dcmat
.
eM11
);
lf
.
lfWidth
*=
fabs
(
dcmat
.
eM11
);
dcmat
.
eM11
=
dcmat
.
eM22
=
1
.
0
;
dcmat
.
eM21
=
dcmat
.
eM12
=
0
;
if
(
dc
->
vport2WorldValid
)
{
if
(
dc
->
xformWorld2Vport
.
eM11
*
dc
->
xformWorld2Vport
.
eM22
<
0
)
lf
.
lfOrientation
=
-
lf
.
lfOrientation
;
lf
.
lfHeight
*=
fabs
(
dc
->
xformWorld2Vport
.
eM22
);
lf
.
lfWidth
*=
fabs
(
dc
->
xformWorld2Vport
.
eM22
);
}
}
TRACE
(
"DC transform %f %f %f %f
\n
"
,
dcmat
.
eM11
,
dcmat
.
eM12
,
...
...
dlls/winex11.drv/xrender.c
View file @
691c37ca
...
...
@@ -1132,6 +1132,9 @@ static HFONT xrenderdrv_SelectFont( PHYSDEV dev, HFONT hfont )
TRACE
(
"font transform %f %f %f %f
\n
"
,
lfsz
.
xform
.
eM11
,
lfsz
.
xform
.
eM12
,
lfsz
.
xform
.
eM21
,
lfsz
.
xform
.
eM22
);
if
(
GetGraphicsMode
(
dev
->
hdc
)
==
GM_COMPATIBLE
&&
lfsz
.
xform
.
eM11
*
lfsz
.
xform
.
eM22
<
0
)
lfsz
.
lf
.
lfOrientation
=
-
lfsz
.
lf
.
lfOrientation
;
/* Not used fields, would break hashing */
lfsz
.
xform
.
eDx
=
lfsz
.
xform
.
eDy
=
0
;
...
...
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