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
c8592b97
Commit
c8592b97
authored
Sep 09, 2022
by
Nikolay Sivov
Committed by
Alexandre Julliard
Sep 09, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dwrite: Set initial justification value for default shaper.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
parent
33c56be5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
7 deletions
+22
-7
shape.c
dlls/dwrite/shape.c
+17
-2
arabic.c
dlls/dwrite/shapers/arabic.c
+2
-2
analyzer.c
dlls/dwrite/tests/analyzer.c
+3
-3
No files found.
dlls/dwrite/shape.c
View file @
c8592b97
...
...
@@ -200,7 +200,22 @@ static void shape_merge_features(struct scriptshaping_context *context, struct s
features
->
count
=
j
+
1
;
}
static
const
struct
shaper
null_shaper
;
static
void
default_shaper_setup_masks
(
struct
scriptshaping_context
*
context
,
const
struct
shaping_features
*
features
)
{
unsigned
int
i
;
for
(
i
=
0
;
i
<
context
->
glyph_count
;
++
i
)
{
context
->
u
.
buffer
.
glyph_props
[
i
].
justification
=
iswspace
(
context
->
glyph_infos
[
i
].
codepoint
)
?
SCRIPT_JUSTIFY_BLANK
:
SCRIPT_JUSTIFY_CHARACTER
;
}
}
static
const
struct
shaper
default_shaper
=
{
.
setup_masks
=
default_shaper_setup_masks
};
static
void
shape_set_shaper
(
struct
scriptshaping_context
*
context
)
{
...
...
@@ -211,7 +226,7 @@ static void shape_set_shaper(struct scriptshaping_context *context)
context
->
shaper
=
&
arabic_shaper
;
break
;
default:
context
->
shaper
=
&
null
_shaper
;
context
->
shaper
=
&
default
_shaper
;
}
}
...
...
dlls/dwrite/shapers/arabic.c
View file @
c8592b97
...
...
@@ -183,6 +183,6 @@ static void arabic_setup_masks(struct scriptshaping_context *context,
const
struct
shaper
arabic_shaper
=
{
arabic_collect_features
,
arabic_setup_masks
,
.
collect_features
=
arabic_collect_features
,
.
setup_masks
=
arabic_setup_masks
,
};
dlls/dwrite/tests/analyzer.c
View file @
c8592b97
...
...
@@ -2904,9 +2904,6 @@ static void test_glyph_justification_property(void)
unsigned
int
i
,
j
;
HRESULT
hr
;
if
(
!
strcmp
(
winetest_platform
,
"wine"
))
return
;
analyzer
=
create_text_analyzer
(
&
IID_IDWriteTextAnalyzer
);
ok
(
!!
analyzer
,
"Failed to create analyzer instance.
\n
"
);
...
...
@@ -2914,6 +2911,9 @@ static void test_glyph_justification_property(void)
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
tests
);
++
i
)
{
if
(
tests
[
i
].
script
==
Script_Arabic
&&
!
strcmp
(
winetest_platform
,
"wine"
))
continue
;
winetest_push_context
(
"Test %s"
,
debugstr_w
(
tests
[
i
].
text
));
sa
.
script
=
tests
[
i
].
script
;
...
...
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