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
980c65f1
Commit
980c65f1
authored
Feb 18, 2015
by
Nikolay Sivov
Committed by
Alexandre Julliard
Feb 18, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dwrite: Use vertical variants in GetGlyphs() when appropriate.
parent
3fa8f4ec
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
1 deletion
+18
-1
analyzer.c
dlls/dwrite/analyzer.c
+18
-1
No files found.
dlls/dwrite/analyzer.c
View file @
980c65f1
...
...
@@ -864,8 +864,9 @@ static HRESULT WINAPI dwritetextanalyzer_GetGlyphs(IDWriteTextAnalyzer2 *iface,
const
struct
dwritescript_properties
*
scriptprops
;
struct
scriptshaping_context
context
;
struct
scriptshaping_cache
*
cache
=
NULL
;
BOOL
update_cluster
,
need_vertical
;
IDWriteFontFace1
*
fontface1
;
WCHAR
*
string
;
BOOL
update_cluster
;
UINT32
i
,
g
;
HRESULT
hr
=
S_OK
;
UINT16
script
;
...
...
@@ -909,6 +910,12 @@ static HRESULT WINAPI dwritetextanalyzer_GetGlyphs(IDWriteTextAnalyzer2 *iface,
if
(
!
string
)
return
E_OUTOFMEMORY
;
hr
=
IDWriteFontFace_QueryInterface
(
fontface
,
&
IID_IDWriteFontFace1
,
(
void
**
)
&
fontface1
);
if
(
FAILED
(
hr
))
WARN
(
"failed to get IDWriteFontFace1
\n
"
);
need_vertical
=
is_sideways
&&
fontface1
&&
IDWriteFontFace1_HasVerticalGlyphVariants
(
fontface1
);
for
(
i
=
0
,
g
=
0
,
update_cluster
=
FALSE
;
i
<
length
;
i
++
)
{
UINT32
codepoint
;
...
...
@@ -928,6 +935,14 @@ static HRESULT WINAPI dwritetextanalyzer_GetGlyphs(IDWriteTextAnalyzer2 *iface,
if
(
FAILED
(
hr
))
goto
done
;
if
(
need_vertical
)
{
UINT16
vertical
;
hr
=
IDWriteFontFace1_GetVerticalGlyphVariants
(
fontface1
,
1
,
&
glyph_indices
[
g
],
&
vertical
);
if
(
hr
==
S_OK
)
glyph_indices
[
g
]
=
vertical
;
}
g
++
;
}
else
{
...
...
@@ -969,6 +984,8 @@ static HRESULT WINAPI dwritetextanalyzer_GetGlyphs(IDWriteTextAnalyzer2 *iface,
hr
=
default_shaping_ops
.
set_text_glyphs_props
(
&
context
,
clustermap
,
glyph_indices
,
*
actual_glyph_count
,
text_props
,
glyph_props
);
done:
if
(
fontface1
)
IDWriteFontFace1_Release
(
fontface1
);
release_scriptshaping_cache
(
cache
);
heap_free
(
string
);
...
...
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