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
3aeff98f
Commit
3aeff98f
authored
Aug 01, 2022
by
Nikolay Sivov
Committed by
Alexandre Julliard
Aug 03, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d2d1/commandlist: Implement SetTextRenderingParams() command.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
parent
0e9f8bab
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
4 deletions
+31
-4
command_list.c
dlls/d2d1/command_list.c
+28
-0
d2d1_private.h
dlls/d2d1/d2d1_private.h
+2
-0
device.c
dlls/d2d1/device.c
+1
-4
No files found.
dlls/d2d1/command_list.c
View file @
3aeff98f
...
...
@@ -25,6 +25,7 @@ enum d2d_command_type
D2D_COMMAND_SET_ANTIALIAS_MODE
,
D2D_COMMAND_SET_TAGS
,
D2D_COMMAND_SET_TEXT_ANTIALIAS_MODE
,
D2D_COMMAND_SET_TEXT_RENDERING_PARAMS
,
D2D_COMMAND_SET_TRANSFORM
,
D2D_COMMAND_SET_PRIMITIVE_BLEND
,
D2D_COMMAND_SET_UNIT_MODE
,
...
...
@@ -62,6 +63,12 @@ struct d2d_command_set_text_antialias_mode
D2D1_TEXT_ANTIALIAS_MODE
mode
;
};
struct
d2d_command_set_text_rendering_params
{
struct
d2d_command
c
;
IDWriteRenderingParams
*
params
;
};
struct
d2d_command_set_transform
{
struct
d2d_command
c
;
...
...
@@ -239,6 +246,12 @@ static HRESULT STDMETHODCALLTYPE d2d_command_list_Stream(ID2D1CommandList *iface
hr
=
ID2D1CommandSink_SetTextAntialiasMode
(
sink
,
c
->
mode
);
break
;
}
case
D2D_COMMAND_SET_TEXT_RENDERING_PARAMS
:
{
const
struct
d2d_command_set_text_rendering_params
*
c
=
data
;
hr
=
ID2D1CommandSink_SetTextRenderingParams
(
sink
,
c
->
params
);
break
;
}
case
D2D_COMMAND_SET_TRANSFORM
:
{
const
struct
d2d_command_set_transform
*
c
=
data
;
...
...
@@ -537,6 +550,7 @@ void d2d_command_list_begin_draw(struct d2d_command_list *command_list,
d2d_command_list_set_text_antialias_mode
(
command_list
,
context
->
drawing_state
.
textAntialiasMode
);
d2d_command_list_set_tags
(
command_list
,
context
->
drawing_state
.
tag1
,
context
->
drawing_state
.
tag2
);
d2d_command_list_set_transform
(
command_list
,
&
context
->
drawing_state
.
transform
);
d2d_command_list_set_text_rendering_params
(
command_list
,
context
->
text_rendering_params
);
command_list
->
state
=
D2D_COMMAND_LIST_STATE_OPEN
;
}
...
...
@@ -686,3 +700,17 @@ void d2d_command_list_fill_rectangle(struct d2d_command_list *command_list,
command
->
rect
=
*
rect
;
command
->
brush
=
brush
;
}
void
d2d_command_list_set_text_rendering_params
(
struct
d2d_command_list
*
command_list
,
IDWriteRenderingParams
*
params
)
{
struct
d2d_command_set_text_rendering_params
*
command
;
if
(
!
params
)
return
;
d2d_command_list_reference_object
(
command_list
,
params
);
command
=
d2d_command_list_require_space
(
command_list
,
sizeof
(
*
command
));
command
->
c
.
op
=
D2D_COMMAND_SET_TEXT_RENDERING_PARAMS
;
command
->
params
=
params
;
}
dlls/d2d1/d2d1_private.h
View file @
3aeff98f
...
...
@@ -759,6 +759,8 @@ void d2d_command_list_fill_geometry(struct d2d_command_list *command_list,
ID2D1Brush
*
orig_opacity_brush
)
DECLSPEC_HIDDEN
;
void
d2d_command_list_fill_rectangle
(
struct
d2d_command_list
*
command_list
,
const
struct
d2d_device_context
*
context
,
const
D2D1_RECT_F
*
rect
,
ID2D1Brush
*
orig_brush
)
DECLSPEC_HIDDEN
;
void
d2d_command_list_set_text_rendering_params
(
struct
d2d_command_list
*
command_list
,
IDWriteRenderingParams
*
params
)
DECLSPEC_HIDDEN
;
static
inline
BOOL
d2d_array_reserve
(
void
**
elements
,
size_t
*
capacity
,
size_t
count
,
size_t
size
)
{
...
...
dlls/d2d1/device.c
View file @
3aeff98f
...
...
@@ -1539,10 +1539,7 @@ static void STDMETHODCALLTYPE d2d_device_context_SetTextRenderingParams(ID2D1Dev
TRACE
(
"iface %p, text_rendering_params %p.
\n
"
,
iface
,
text_rendering_params
);
if
(
context
->
target
.
type
==
D2D_TARGET_COMMAND_LIST
)
{
FIXME
(
"Unimplemented for command list target.
\n
"
);
return
;
}
d2d_command_list_set_text_rendering_params
(
context
->
target
.
command_list
,
text_rendering_params
);
if
(
text_rendering_params
)
IDWriteRenderingParams_AddRef
(
text_rendering_params
);
...
...
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