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
881f635c
Commit
881f635c
authored
Dec 28, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Extended pens are always transparent.
parent
5f03c6c8
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
6 deletions
+10
-6
dibdrv.h
dlls/gdi32/dibdrv/dibdrv.h
+1
-0
objects.c
dlls/gdi32/dibdrv/objects.c
+9
-6
No files found.
dlls/gdi32/dibdrv/dibdrv.h
View file @
881f635c
...
@@ -84,6 +84,7 @@ typedef struct dibdrv_physdev
...
@@ -84,6 +84,7 @@ typedef struct dibdrv_physdev
/* pen */
/* pen */
COLORREF
pen_colorref
;
COLORREF
pen_colorref
;
DWORD
pen_style
,
pen_endcap
,
pen_join
;
DWORD
pen_style
,
pen_endcap
,
pen_join
;
BOOL
pen_is_ext
;
int
pen_width
;
int
pen_width
;
dash_pattern
pen_pattern
;
dash_pattern
pen_pattern
;
dash_pos
dash_pos
;
dash_pos
dash_pos
;
...
...
dlls/gdi32/dibdrv/objects.c
View file @
881f635c
...
@@ -198,13 +198,13 @@ DWORD get_pixel_color( dibdrv_physdev *pdev, COLORREF color, BOOL mono_fixup )
...
@@ -198,13 +198,13 @@ DWORD get_pixel_color( dibdrv_physdev *pdev, COLORREF color, BOOL mono_fixup )
* of the relevant fg color (which is always set up correctly).
* of the relevant fg color (which is always set up correctly).
*/
*/
static
inline
void
get_color_masks
(
dibdrv_physdev
*
pdev
,
UINT
rop
,
COLORREF
colorref
,
static
inline
void
get_color_masks
(
dibdrv_physdev
*
pdev
,
UINT
rop
,
COLORREF
colorref
,
rop_mask
*
fg_mask
,
rop_mask
*
bg_mask
)
INT
bkgnd_mode
,
rop_mask
*
fg_mask
,
rop_mask
*
bg_mask
)
{
{
DWORD
color
=
get_pixel_color
(
pdev
,
colorref
,
TRUE
);
DWORD
color
=
get_pixel_color
(
pdev
,
colorref
,
TRUE
);
calc_rop_masks
(
rop
,
color
,
fg_mask
);
calc_rop_masks
(
rop
,
color
,
fg_mask
);
if
(
GetBkMode
(
pdev
->
dev
.
hdc
)
==
TRANSPARENT
)
if
(
bkgnd_mode
==
TRANSPARENT
)
{
{
bg_mask
->
and
=
~
0u
;
bg_mask
->
and
=
~
0u
;
bg_mask
->
xor
=
0
;
bg_mask
->
xor
=
0
;
...
@@ -932,6 +932,7 @@ static BOOL dashed_pen_lines(dibdrv_physdev *pdev, int num, POINT *pts, BOOL clo
...
@@ -932,6 +932,7 @@ static BOOL dashed_pen_lines(dibdrv_physdev *pdev, int num, POINT *pts, BOOL clo
int
i
;
int
i
;
get_color_masks
(
pdev
,
GetROP2
(
pdev
->
dev
.
hdc
),
pdev
->
pen_colorref
,
get_color_masks
(
pdev
,
GetROP2
(
pdev
->
dev
.
hdc
),
pdev
->
pen_colorref
,
pdev
->
pen_is_ext
?
TRANSPARENT
:
GetBkMode
(
pdev
->
dev
.
hdc
),
&
pdev
->
dash_masks
[
1
],
&
pdev
->
dash_masks
[
0
]
);
&
pdev
->
dash_masks
[
1
],
&
pdev
->
dash_masks
[
0
]
);
assert
(
num
>=
2
);
assert
(
num
>=
2
);
...
@@ -1265,13 +1266,13 @@ HPEN dibdrv_SelectPen( PHYSDEV dev, HPEN hpen )
...
@@ -1265,13 +1266,13 @@ HPEN dibdrv_SelectPen( PHYSDEV dev, HPEN hpen )
PHYSDEV
next
=
GET_NEXT_PHYSDEV
(
dev
,
pSelectPen
);
PHYSDEV
next
=
GET_NEXT_PHYSDEV
(
dev
,
pSelectPen
);
dibdrv_physdev
*
pdev
=
get_dibdrv_pdev
(
dev
);
dibdrv_physdev
*
pdev
=
get_dibdrv_pdev
(
dev
);
LOGPEN
logpen
;
LOGPEN
logpen
;
EXTLOGPEN
*
elp
=
NULL
;
TRACE
(
"(%p, %p)
\n
"
,
dev
,
hpen
);
TRACE
(
"(%p, %p)
\n
"
,
dev
,
hpen
);
if
(
!
GetObjectW
(
hpen
,
sizeof
(
logpen
),
&
logpen
))
if
(
!
GetObjectW
(
hpen
,
sizeof
(
logpen
),
&
logpen
))
{
{
/* must be an extended pen */
/* must be an extended pen */
EXTLOGPEN
*
elp
;
INT
size
=
GetObjectW
(
hpen
,
0
,
NULL
);
INT
size
=
GetObjectW
(
hpen
,
0
,
NULL
);
if
(
!
size
)
return
0
;
if
(
!
size
)
return
0
;
...
@@ -1285,8 +1286,6 @@ HPEN dibdrv_SelectPen( PHYSDEV dev, HPEN hpen )
...
@@ -1285,8 +1286,6 @@ HPEN dibdrv_SelectPen( PHYSDEV dev, HPEN hpen )
logpen
.
lopnColor
=
elp
->
elpColor
;
logpen
.
lopnColor
=
elp
->
elpColor
;
/* cosmetic ext pens are always 1-pixel wide */
/* cosmetic ext pens are always 1-pixel wide */
if
(
!
(
logpen
.
lopnStyle
&
PS_GEOMETRIC
))
logpen
.
lopnWidth
.
x
=
0
;
if
(
!
(
logpen
.
lopnStyle
&
PS_GEOMETRIC
))
logpen
.
lopnWidth
.
x
=
0
;
HeapFree
(
GetProcessHeap
(),
0
,
elp
);
}
}
pdev
->
pen_join
=
logpen
.
lopnStyle
&
PS_JOIN_MASK
;
pdev
->
pen_join
=
logpen
.
lopnStyle
&
PS_JOIN_MASK
;
...
@@ -1336,6 +1335,9 @@ HPEN dibdrv_SelectPen( PHYSDEV dev, HPEN hpen )
...
@@ -1336,6 +1335,9 @@ HPEN dibdrv_SelectPen( PHYSDEV dev, HPEN hpen )
break
;
break
;
}
}
pdev
->
pen_is_ext
=
(
elp
!=
NULL
);
HeapFree
(
GetProcessHeap
(),
0
,
elp
);
return
next
->
funcs
->
pSelectPen
(
next
,
hpen
);
return
next
->
funcs
->
pSelectPen
(
next
,
hpen
);
}
}
...
@@ -1461,7 +1463,8 @@ static BOOL create_hatch_brush_bits(dibdrv_physdev *pdev, BOOL *needs_reselect)
...
@@ -1461,7 +1463,8 @@ static BOOL create_hatch_brush_bits(dibdrv_physdev *pdev, BOOL *needs_reselect)
hatch
.
bits
.
free
=
hatch
.
bits
.
param
=
NULL
;
hatch
.
bits
.
free
=
hatch
.
bits
.
param
=
NULL
;
hatch
.
bits
.
is_copy
=
FALSE
;
hatch
.
bits
.
is_copy
=
FALSE
;
get_color_masks
(
pdev
,
pdev
->
brush_rop
,
pdev
->
brush_colorref
,
&
fg_mask
,
&
bg_mask
);
get_color_masks
(
pdev
,
pdev
->
brush_rop
,
pdev
->
brush_colorref
,
GetBkMode
(
pdev
->
dev
.
hdc
),
&
fg_mask
,
&
bg_mask
);
if
(
pdev
->
brush_colorref
&
(
1
<<
24
))
/* PALETTEINDEX */
if
(
pdev
->
brush_colorref
&
(
1
<<
24
))
/* PALETTEINDEX */
*
needs_reselect
=
TRUE
;
*
needs_reselect
=
TRUE
;
...
...
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