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
8768f605
Commit
8768f605
authored
Nov 05, 2020
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Store scale as an integer.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
fe6bb5f7
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
font.c
dlls/gdi32/font.c
+2
-2
freetype.c
dlls/gdi32/freetype.c
+2
-2
gdi_private.h
dlls/gdi32/gdi_private.h
+1
-1
No files found.
dlls/gdi32/font.c
View file @
8768f605
...
...
@@ -1698,7 +1698,7 @@ static struct gdi_font *alloc_gdi_font( const WCHAR *file, void *data_ptr, SIZE_
font
->
refcount
=
1
;
font
->
matrix
.
eM11
=
font
->
matrix
.
eM22
=
1
.
0
;
font
->
scale_y
=
1
.
0
;
font
->
scale_y
=
1
;
font
->
kern_count
=
-
1
;
list_init
(
&
font
->
child_fonts
);
...
...
@@ -3686,8 +3686,8 @@ static struct gdi_font *select_font( LOGFONTW *lf, FMAT2 dcmat, BOOL can_use_bit
/* The jump between unscaled and doubled is delayed by 1 */
else
if
(
scale
==
2
&&
scaled_height
-
height
>
(
face
->
size
.
height
/
4
-
1
))
scale
--
;
font
->
scale_y
=
scale
;
TRACE
(
"font scale y: %d
\n
"
,
font
->
scale_y
);
}
TRACE
(
"font scale y: %f
\n
"
,
font
->
scale_y
);
if
(
!
font_funcs
->
load_font
(
font
))
{
...
...
dlls/gdi32/freetype.c
View file @
8768f605
...
...
@@ -2308,13 +2308,13 @@ static BOOL get_transform_matrices( struct gdi_font *font, BOOL vertical, const
width_ratio
=
font
->
scale_y
;
/* Scaling transform */
if
(
width_ratio
!=
1
.
0
||
font
->
scale_y
!=
1
.
0
)
if
(
width_ratio
!=
1
.
0
||
font
->
scale_y
!=
1
)
{
FT_Matrix
scale_mat
;
scale_mat
.
xx
=
FT_FixedFromFloat
(
width_ratio
);
scale_mat
.
xy
=
0
;
scale_mat
.
yx
=
0
;
scale_mat
.
yy
=
FT_FixedFromFloat
(
font
->
scale_y
)
;
scale_mat
.
yy
=
font
->
scale_y
<<
16
;
pFT_Matrix_Multiply
(
&
scale_mat
,
&
matrices
[
matrix_unrotated
]
);
needs_transform
=
TRUE
;
...
...
dlls/gdi32/gdi_private.h
View file @
8768f605
...
...
@@ -335,7 +335,7 @@ struct gdi_font
LOGFONTW
lf
;
FMAT2
matrix
;
UINT
face_index
;
double
scale_y
;
INT
scale_y
;
INT
aveWidth
;
INT
ppem
;
SHORT
yMax
;
...
...
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