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
14e21d95
Commit
14e21d95
authored
Oct 14, 2009
by
Roderick Colenbrander
Committed by
Alexandre Julliard
Oct 14, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winex11: Add X11DRV_XRender_SetDeviceClipping for syncing the clipping region…
winex11: Add X11DRV_XRender_SetDeviceClipping for syncing the clipping region with XRender pictures.
parent
2c725de6
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
11 deletions
+31
-11
graphics.c
dlls/winex11.drv/graphics.c
+3
-0
x11drv.h
dlls/winex11.drv/x11drv.h
+1
-0
xrender.c
dlls/winex11.drv/xrender.c
+27
-11
No files found.
dlls/winex11.drv/graphics.c
View file @
14e21d95
...
@@ -166,6 +166,9 @@ void CDECL X11DRV_SetDeviceClipping( X11DRV_PDEVICE *physDev, HRGN vis_rgn, HRGN
...
@@ -166,6 +166,9 @@ void CDECL X11DRV_SetDeviceClipping( X11DRV_PDEVICE *physDev, HRGN vis_rgn, HRGN
XSetClipRectangles
(
gdi_display
,
physDev
->
gc
,
physDev
->
dc_rect
.
left
,
physDev
->
dc_rect
.
top
,
XSetClipRectangles
(
gdi_display
,
physDev
->
gc
,
physDev
->
dc_rect
.
left
,
physDev
->
dc_rect
.
top
,
(
XRectangle
*
)
data
->
Buffer
,
data
->
rdh
.
nCount
,
YXBanded
);
(
XRectangle
*
)
data
->
Buffer
,
data
->
rdh
.
nCount
,
YXBanded
);
wine_tsx11_unlock
();
wine_tsx11_unlock
();
if
(
physDev
->
xrender
)
X11DRV_XRender_SetDeviceClipping
(
physDev
,
data
);
HeapFree
(
GetProcessHeap
(),
0
,
data
);
HeapFree
(
GetProcessHeap
(),
0
,
data
);
}
}
...
...
dlls/winex11.drv/x11drv.h
View file @
14e21d95
...
@@ -281,6 +281,7 @@ extern int using_client_side_fonts;
...
@@ -281,6 +281,7 @@ extern int using_client_side_fonts;
extern
void
X11DRV_XRender_Init
(
void
);
extern
void
X11DRV_XRender_Init
(
void
);
extern
void
X11DRV_XRender_Finalize
(
void
);
extern
void
X11DRV_XRender_Finalize
(
void
);
extern
BOOL
X11DRV_XRender_SelectFont
(
X11DRV_PDEVICE
*
,
HFONT
);
extern
BOOL
X11DRV_XRender_SelectFont
(
X11DRV_PDEVICE
*
,
HFONT
);
extern
void
X11DRV_XRender_SetDeviceClipping
(
X11DRV_PDEVICE
*
physDev
,
const
RGNDATA
*
data
);
extern
void
X11DRV_XRender_DeleteDC
(
X11DRV_PDEVICE
*
);
extern
void
X11DRV_XRender_DeleteDC
(
X11DRV_PDEVICE
*
);
extern
void
X11DRV_XRender_CopyBrush
(
X11DRV_PDEVICE
*
physDev
,
X_PHYSBITMAP
*
physBitmap
,
int
width
,
int
height
);
extern
void
X11DRV_XRender_CopyBrush
(
X11DRV_PDEVICE
*
physDev
,
X_PHYSBITMAP
*
physBitmap
,
int
width
,
int
height
);
extern
BOOL
X11DRV_XRender_ExtTextOut
(
X11DRV_PDEVICE
*
physDev
,
INT
x
,
INT
y
,
UINT
flags
,
extern
BOOL
X11DRV_XRender_ExtTextOut
(
X11DRV_PDEVICE
*
physDev
,
INT
x
,
INT
y
,
UINT
flags
,
...
...
dlls/winex11.drv/xrender.c
View file @
14e21d95
...
@@ -506,13 +506,19 @@ static Picture get_xrender_picture(X11DRV_PDEVICE *physDev)
...
@@ -506,13 +506,19 @@ static Picture get_xrender_picture(X11DRV_PDEVICE *physDev)
if
(
!
info
->
pict
&&
info
->
format
)
if
(
!
info
->
pict
&&
info
->
format
)
{
{
XRenderPictureAttributes
pa
;
XRenderPictureAttributes
pa
;
RGNDATA
*
clip
=
X11DRV_GetRegionData
(
physDev
->
region
,
0
);
wine_tsx11_lock
();
wine_tsx11_lock
();
pa
.
subwindow_mode
=
IncludeInferiors
;
pa
.
subwindow_mode
=
IncludeInferiors
;
info
->
pict
=
pXRenderCreatePicture
(
gdi_display
,
physDev
->
drawable
,
info
->
format
->
pict_format
,
info
->
pict
=
pXRenderCreatePicture
(
gdi_display
,
physDev
->
drawable
,
info
->
format
->
pict_format
,
CPSubwindowMode
,
&
pa
);
CPSubwindowMode
,
&
pa
);
if
(
info
->
pict
&&
clip
)
pXRenderSetPictureClipRectangles
(
gdi_display
,
info
->
pict
,
physDev
->
dc_rect
.
left
,
physDev
->
dc_rect
.
top
,
(
XRectangle
*
)
clip
->
Buffer
,
clip
->
rdh
.
nCount
);
wine_tsx11_unlock
();
wine_tsx11_unlock
();
TRACE
(
"Allocing pict=%lx dc=%p drawable=%08lx
\n
"
,
info
->
pict
,
physDev
->
hdc
,
physDev
->
drawable
);
TRACE
(
"Allocing pict=%lx dc=%p drawable=%08lx
\n
"
,
info
->
pict
,
physDev
->
hdc
,
physDev
->
drawable
);
HeapFree
(
GetProcessHeap
(),
0
,
clip
);
}
}
return
info
->
pict
;
return
info
->
pict
;
...
@@ -872,6 +878,21 @@ BOOL X11DRV_XRender_SelectFont(X11DRV_PDEVICE *physDev, HFONT hfont)
...
@@ -872,6 +878,21 @@ BOOL X11DRV_XRender_SelectFont(X11DRV_PDEVICE *physDev, HFONT hfont)
}
}
/***********************************************************************
/***********************************************************************
* X11DRV_XRender_SetDeviceClipping
*/
void
X11DRV_XRender_SetDeviceClipping
(
X11DRV_PDEVICE
*
physDev
,
const
RGNDATA
*
data
)
{
if
(
physDev
->
xrender
->
pict
)
{
wine_tsx11_lock
();
pXRenderSetPictureClipRectangles
(
gdi_display
,
physDev
->
xrender
->
pict
,
physDev
->
dc_rect
.
left
,
physDev
->
dc_rect
.
top
,
(
XRectangle
*
)
data
->
Buffer
,
data
->
rdh
.
nCount
);
wine_tsx11_unlock
();
}
}
/***********************************************************************
* X11DRV_XRender_DeleteDC
* X11DRV_XRender_DeleteDC
*/
*/
void
X11DRV_XRender_DeleteDC
(
X11DRV_PDEVICE
*
physDev
)
void
X11DRV_XRender_DeleteDC
(
X11DRV_PDEVICE
*
physDev
)
...
@@ -1465,7 +1486,6 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag
...
@@ -1465,7 +1486,6 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag
const
RECT
*
lprect
,
LPCWSTR
wstr
,
UINT
count
,
const
RECT
*
lprect
,
LPCWSTR
wstr
,
UINT
count
,
const
INT
*
lpDx
)
const
INT
*
lpDx
)
{
{
RGNDATA
*
data
;
XGCValues
xgcval
;
XGCValues
xgcval
;
gsCacheEntry
*
entry
;
gsCacheEntry
*
entry
;
gsCacheEntryFormat
*
formatEntry
;
gsCacheEntryFormat
*
formatEntry
;
...
@@ -1586,16 +1606,6 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag
...
@@ -1586,16 +1606,6 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag
int
render_op
=
PictOpOver
;
int
render_op
=
PictOpOver
;
Picture
pict
=
get_xrender_picture
(
physDev
);
Picture
pict
=
get_xrender_picture
(
physDev
);
if
((
data
=
X11DRV_GetRegionData
(
physDev
->
region
,
0
)))
{
wine_tsx11_lock
();
pXRenderSetPictureClipRectangles
(
gdi_display
,
pict
,
physDev
->
dc_rect
.
left
,
physDev
->
dc_rect
.
top
,
(
XRectangle
*
)
data
->
Buffer
,
data
->
rdh
.
nCount
);
wine_tsx11_unlock
();
HeapFree
(
GetProcessHeap
(),
0
,
data
);
}
/* There's a bug in XRenderCompositeText that ignores the xDst and yDst parameters.
/* There's a bug in XRenderCompositeText that ignores the xDst and yDst parameters.
So we pass zeros to the function and move to our starting position using the first
So we pass zeros to the function and move to our starting position using the first
element of the elts array. */
element of the elts array. */
...
@@ -2186,6 +2196,12 @@ void X11DRV_XRender_DeleteDC(X11DRV_PDEVICE *physDev)
...
@@ -2186,6 +2196,12 @@ void X11DRV_XRender_DeleteDC(X11DRV_PDEVICE *physDev)
return
;
return
;
}
}
void
X11DRV_XRender_SetDeviceClipping
(
X11DRV_PDEVICE
*
physDev
)
{
assert
(
0
);
return
;
}
BOOL
X11DRV_XRender_ExtTextOut
(
X11DRV_PDEVICE
*
physDev
,
INT
x
,
INT
y
,
UINT
flags
,
BOOL
X11DRV_XRender_ExtTextOut
(
X11DRV_PDEVICE
*
physDev
,
INT
x
,
INT
y
,
UINT
flags
,
const
RECT
*
lprect
,
LPCWSTR
wstr
,
UINT
count
,
const
RECT
*
lprect
,
LPCWSTR
wstr
,
UINT
count
,
const
INT
*
lpDx
)
const
INT
*
lpDx
)
...
...
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