gdi32: Use ntgdi names for region functions.
Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Huw Davies <huw@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
8df14dac7a
commit
0a42d6a915
|
@ -484,7 +484,7 @@ BOOL CDECL nulldrv_GradientFill( PHYSDEV dev, TRIVERTEX *vert_array, ULONG nvert
|
|||
|
||||
rgn = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
gradient_bitmapinfo( info, bits.ptr, vert_array, nvert, grad_array, ngrad, mode, pts, rgn );
|
||||
OffsetRgn( rgn, dst.visrect.left, dst.visrect.top );
|
||||
NtGdiOffsetRgn( rgn, dst.visrect.left, dst.visrect.top );
|
||||
ret = !dev->funcs->pPutImage( dev, rgn, info, &bits, &src, &dst, SRCCOPY );
|
||||
|
||||
if (bits.free) bits.free( &bits );
|
||||
|
|
|
@ -307,7 +307,7 @@ LONG WINAPI NtGdiSetBitmapBits(
|
|||
src.visrect.right, src.visrect.bottom - 1 );
|
||||
last_row = NtGdiCreateRectRgn( src.visrect.left, src.visrect.bottom - 1,
|
||||
src.visrect.left + extra_pixels, src.visrect.bottom );
|
||||
CombineRgn( clip, clip, last_row, RGN_OR );
|
||||
NtGdiCombineRgn( clip, clip, last_row, RGN_OR );
|
||||
DeleteObject( last_row );
|
||||
}
|
||||
|
||||
|
|
|
@ -84,7 +84,7 @@ BOOL clip_visrect( DC *dc, RECT *dst, const RECT *src )
|
|||
RECT clip;
|
||||
|
||||
if (!clip_device_rect( dc, dst, src )) return FALSE;
|
||||
if (GetRgnBox( get_dc_region(dc), &clip )) return intersect_rect( dst, dst, &clip );
|
||||
if (NtGdiGetRgnBox( get_dc_region(dc), &clip )) return intersect_rect( dst, dst, &clip );
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
@ -106,8 +106,8 @@ void update_dc_clipping( DC * dc )
|
|||
if (count > 1)
|
||||
{
|
||||
if (!dc->region) dc->region = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
CombineRgn( dc->region, regions[0], regions[1], RGN_AND );
|
||||
if (count > 2) CombineRgn( dc->region, dc->region, regions[2], RGN_AND );
|
||||
NtGdiCombineRgn( dc->region, regions[0], regions[1], RGN_AND );
|
||||
if (count > 2) NtGdiCombineRgn( dc->region, dc->region, regions[2], RGN_AND );
|
||||
}
|
||||
else /* only one region, we don't need the total region */
|
||||
{
|
||||
|
@ -179,9 +179,9 @@ INT CDECL nulldrv_ExtSelectClipRgn( PHYSDEV dev, HRGN rgn, INT mode )
|
|||
create_default_clip_region( dc );
|
||||
|
||||
if (mode == RGN_COPY)
|
||||
ret = CombineRgn( dc->hClipRgn, rgn, 0, mode );
|
||||
ret = NtGdiCombineRgn( dc->hClipRgn, rgn, 0, mode );
|
||||
else
|
||||
ret = CombineRgn( dc->hClipRgn, dc->hClipRgn, rgn, mode);
|
||||
ret = NtGdiCombineRgn( dc->hClipRgn, dc->hClipRgn, rgn, mode );
|
||||
|
||||
if (mirrored) DeleteObject( mirrored );
|
||||
}
|
||||
|
@ -198,7 +198,7 @@ INT CDECL nulldrv_ExcludeClipRect( PHYSDEV dev, INT left, INT top, INT right, IN
|
|||
|
||||
if (!(rgn = CreateRectRgnIndirect( &rect ))) return ERROR;
|
||||
if (!dc->hClipRgn) create_default_clip_region( dc );
|
||||
ret = CombineRgn( dc->hClipRgn, dc->hClipRgn, rgn, RGN_DIFF );
|
||||
ret = NtGdiCombineRgn( dc->hClipRgn, dc->hClipRgn, rgn, RGN_DIFF );
|
||||
DeleteObject( rgn );
|
||||
if (ret != ERROR) update_dc_clipping( dc );
|
||||
return ret;
|
||||
|
@ -219,7 +219,7 @@ INT CDECL nulldrv_IntersectClipRect( PHYSDEV dev, INT left, INT top, INT right,
|
|||
else
|
||||
{
|
||||
if (!(rgn = CreateRectRgnIndirect( &rect ))) return ERROR;
|
||||
ret = CombineRgn( dc->hClipRgn, dc->hClipRgn, rgn, RGN_AND );
|
||||
ret = NtGdiCombineRgn( dc->hClipRgn, dc->hClipRgn, rgn, RGN_AND );
|
||||
DeleteObject( rgn );
|
||||
}
|
||||
if (ret != ERROR) update_dc_clipping( dc );
|
||||
|
@ -236,7 +236,7 @@ INT CDECL nulldrv_OffsetClipRgn( PHYSDEV dev, INT x, INT y )
|
|||
x = MulDiv( x, dc->vport_ext.cx, dc->wnd_ext.cx );
|
||||
y = MulDiv( y, dc->vport_ext.cy, dc->wnd_ext.cy );
|
||||
if (dc->layout & LAYOUT_RTL) x = -x;
|
||||
ret = OffsetRgn( dc->hClipRgn, x, y );
|
||||
ret = NtGdiOffsetRgn( dc->hClipRgn, x, y );
|
||||
update_dc_clipping( dc );
|
||||
}
|
||||
return ret;
|
||||
|
@ -285,7 +285,7 @@ void CDECL __wine_set_visible_region( HDC hdc, HRGN hrgn, const RECT *vis_rect,
|
|||
wine_dbgstr_rect(vis_rect), wine_dbgstr_rect(device_rect), surface );
|
||||
|
||||
/* map region to DC coordinates */
|
||||
OffsetRgn( hrgn, -vis_rect->left, -vis_rect->top );
|
||||
NtGdiOffsetRgn( hrgn, -vis_rect->left, -vis_rect->top );
|
||||
|
||||
if (dc->hVisRgn) DeleteObject( dc->hVisRgn );
|
||||
dc->dirty = 0;
|
||||
|
@ -380,7 +380,7 @@ BOOL WINAPI PtVisible( HDC hdc, INT x, INT y )
|
|||
ret = (!get_dc_device_rect( dc, &visrect ) ||
|
||||
(pt.x >= visrect.left && pt.x < visrect.right &&
|
||||
pt.y >= visrect.top && pt.y < visrect.bottom));
|
||||
if (ret && get_dc_region( dc )) ret = PtInRegion( get_dc_region( dc ), pt.x, pt.y );
|
||||
if (ret && get_dc_region( dc )) ret = NtGdiPtInRegion( get_dc_region( dc ), pt.x, pt.y );
|
||||
release_dc_ptr( dc );
|
||||
return ret;
|
||||
}
|
||||
|
@ -403,7 +403,7 @@ BOOL WINAPI RectVisible( HDC hdc, const RECT* rect )
|
|||
|
||||
update_dc( dc );
|
||||
ret = (!get_dc_device_rect( dc, &visrect ) || intersect_rect( &visrect, &visrect, &tmpRect ));
|
||||
if (ret && get_dc_region( dc )) ret = RectInRegion( get_dc_region( dc ), &tmpRect );
|
||||
if (ret && get_dc_region( dc )) ret = NtGdiRectInRegion( get_dc_region( dc ), &tmpRect );
|
||||
release_dc_ptr( dc );
|
||||
return ret;
|
||||
}
|
||||
|
@ -422,7 +422,7 @@ INT WINAPI GetClipBox( HDC hdc, LPRECT rect )
|
|||
update_dc( dc );
|
||||
if (get_dc_region( dc ))
|
||||
{
|
||||
ret = GetRgnBox( get_dc_region( dc ), rect );
|
||||
ret = NtGdiGetRgnBox( get_dc_region( dc ), rect );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -456,7 +456,7 @@ INT WINAPI GetClipRgn( HDC hdc, HRGN hRgn )
|
|||
{
|
||||
if( dc->hClipRgn )
|
||||
{
|
||||
if( CombineRgn(hRgn, dc->hClipRgn, 0, RGN_COPY) != ERROR )
|
||||
if (NtGdiCombineRgn( hRgn, dc->hClipRgn, 0, RGN_COPY ) != ERROR)
|
||||
{
|
||||
ret = 1;
|
||||
if (dc->layout & LAYOUT_RTL)
|
||||
|
@ -480,7 +480,7 @@ INT WINAPI GetMetaRgn( HDC hdc, HRGN hRgn )
|
|||
|
||||
if (dc)
|
||||
{
|
||||
if (dc->hMetaRgn && CombineRgn( hRgn, dc->hMetaRgn, 0, RGN_COPY ) != ERROR)
|
||||
if (dc->hMetaRgn && NtGdiCombineRgn( hRgn, dc->hMetaRgn, 0, RGN_COPY ) != ERROR)
|
||||
{
|
||||
ret = 1;
|
||||
if (dc->layout & LAYOUT_RTL)
|
||||
|
@ -516,30 +516,30 @@ INT WINAPI GetRandomRgn(HDC hDC, HRGN hRgn, INT iCode)
|
|||
switch (iCode)
|
||||
{
|
||||
case 1:
|
||||
if (dc->hClipRgn) CombineRgn( hRgn, dc->hClipRgn, 0, RGN_COPY );
|
||||
if (dc->hClipRgn) NtGdiCombineRgn( hRgn, dc->hClipRgn, 0, RGN_COPY );
|
||||
else ret = 0;
|
||||
break;
|
||||
case 2:
|
||||
if (dc->hMetaRgn) CombineRgn( hRgn, dc->hMetaRgn, 0, RGN_COPY );
|
||||
if (dc->hMetaRgn) NtGdiCombineRgn( hRgn, dc->hMetaRgn, 0, RGN_COPY );
|
||||
else ret = 0;
|
||||
break;
|
||||
case 3:
|
||||
if (dc->hClipRgn && dc->hMetaRgn) CombineRgn( hRgn, dc->hClipRgn, dc->hMetaRgn, RGN_AND );
|
||||
else if (dc->hClipRgn) CombineRgn( hRgn, dc->hClipRgn, 0, RGN_COPY );
|
||||
else if (dc->hMetaRgn) CombineRgn( hRgn, dc->hMetaRgn, 0, RGN_COPY );
|
||||
if (dc->hClipRgn && dc->hMetaRgn) NtGdiCombineRgn( hRgn, dc->hClipRgn, dc->hMetaRgn, RGN_AND );
|
||||
else if (dc->hClipRgn) NtGdiCombineRgn( hRgn, dc->hClipRgn, 0, RGN_COPY );
|
||||
else if (dc->hMetaRgn) NtGdiCombineRgn( hRgn, dc->hMetaRgn, 0, RGN_COPY );
|
||||
else ret = 0;
|
||||
break;
|
||||
case SYSRGN: /* == 4 */
|
||||
update_dc( dc );
|
||||
if (dc->hVisRgn)
|
||||
{
|
||||
CombineRgn( hRgn, dc->hVisRgn, 0, RGN_COPY );
|
||||
NtGdiCombineRgn( hRgn, dc->hVisRgn, 0, RGN_COPY );
|
||||
/* On Windows NT/2000, the SYSRGN returned is in screen coordinates */
|
||||
if (!(GetVersion() & 0x80000000)) OffsetRgn( hRgn, dc->vis_rect.left, dc->vis_rect.top );
|
||||
if (!(GetVersion() & 0x80000000)) NtGdiOffsetRgn( hRgn, dc->vis_rect.left, dc->vis_rect.top );
|
||||
}
|
||||
else if (!is_rect_empty( &dc->device_rect ))
|
||||
SetRectRgn( hRgn, dc->device_rect.left, dc->device_rect.top,
|
||||
dc->device_rect.right, dc->device_rect.bottom );
|
||||
NtGdiSetRectRgn( hRgn, dc->device_rect.left, dc->device_rect.top,
|
||||
dc->device_rect.right, dc->device_rect.bottom );
|
||||
else
|
||||
ret = 0;
|
||||
break;
|
||||
|
@ -569,7 +569,7 @@ INT WINAPI SetMetaRgn( HDC hdc )
|
|||
if (dc->hMetaRgn)
|
||||
{
|
||||
/* the intersection becomes the new meta region */
|
||||
CombineRgn( dc->hMetaRgn, dc->hMetaRgn, dc->hClipRgn, RGN_AND );
|
||||
NtGdiCombineRgn( dc->hMetaRgn, dc->hMetaRgn, dc->hClipRgn, RGN_AND );
|
||||
DeleteObject( dc->hClipRgn );
|
||||
dc->hClipRgn = 0;
|
||||
}
|
||||
|
@ -583,7 +583,7 @@ INT WINAPI SetMetaRgn( HDC hdc )
|
|||
|
||||
/* Note: no need to call update_dc_clipping, the overall clip region hasn't changed */
|
||||
|
||||
ret = GetRgnBox( dc->hMetaRgn, &dummy );
|
||||
ret = NtGdiGetRgnBox( dc->hMetaRgn, &dummy );
|
||||
release_dc_ptr( dc );
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -419,12 +419,12 @@ INT CDECL nulldrv_SaveDC( PHYSDEV dev )
|
|||
if (dc->hClipRgn)
|
||||
{
|
||||
newdc->hClipRgn = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
CombineRgn( newdc->hClipRgn, dc->hClipRgn, 0, RGN_COPY );
|
||||
NtGdiCombineRgn( newdc->hClipRgn, dc->hClipRgn, 0, RGN_COPY );
|
||||
}
|
||||
if (dc->hMetaRgn)
|
||||
{
|
||||
newdc->hMetaRgn = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
CombineRgn( newdc->hMetaRgn, dc->hMetaRgn, 0, RGN_COPY );
|
||||
NtGdiCombineRgn( newdc->hMetaRgn, dc->hMetaRgn, 0, RGN_COPY );
|
||||
}
|
||||
|
||||
if (!PATH_SavePath( newdc, dc ))
|
||||
|
@ -494,7 +494,7 @@ BOOL CDECL nulldrv_RestoreDC( PHYSDEV dev, INT level )
|
|||
if (dcs->hClipRgn)
|
||||
{
|
||||
if (!dc->hClipRgn) dc->hClipRgn = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
CombineRgn( dc->hClipRgn, dcs->hClipRgn, 0, RGN_COPY );
|
||||
NtGdiCombineRgn( dc->hClipRgn, dcs->hClipRgn, 0, RGN_COPY );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -504,7 +504,7 @@ BOOL CDECL nulldrv_RestoreDC( PHYSDEV dev, INT level )
|
|||
if (dcs->hMetaRgn)
|
||||
{
|
||||
if (!dc->hMetaRgn) dc->hMetaRgn = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
CombineRgn( dc->hMetaRgn, dcs->hMetaRgn, 0, RGN_COPY );
|
||||
NtGdiCombineRgn( dc->hMetaRgn, dcs->hMetaRgn, 0, RGN_COPY );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -374,8 +374,8 @@ static BOOL build_rle_bitmap( BITMAPINFO *info, struct gdi_image_bits *bits, HRG
|
|||
{
|
||||
if(left != right && clip)
|
||||
{
|
||||
SetRectRgn( run, left, y, right, y + 1 );
|
||||
CombineRgn( *clip, run, *clip, RGN_OR );
|
||||
NtGdiSetRectRgn( run, left, y, right, y + 1 );
|
||||
NtGdiCombineRgn( *clip, run, *clip, RGN_OR );
|
||||
}
|
||||
switch (data)
|
||||
{
|
||||
|
@ -562,7 +562,7 @@ INT CDECL nulldrv_StretchDIBits( PHYSDEV dev, INT xDst, INT yDst, INT widthDst,
|
|||
|
||||
if (!intersect_vis_rectangles( &dst, &src )) goto done;
|
||||
|
||||
if (clip) OffsetRgn( clip, dst.x - src.x, dst.y - src.y );
|
||||
if (clip) NtGdiOffsetRgn( clip, dst.x - src.x, dst.y - src.y );
|
||||
|
||||
dev = GET_DC_PHYSDEV( dc, pPutImage );
|
||||
copy_bitmapinfo( dst_info, src_info );
|
||||
|
@ -859,7 +859,7 @@ INT CDECL nulldrv_SetDIBitsToDevice( PHYSDEV dev, INT x_dst, INT y_dst, DWORD cx
|
|||
src.visrect = dst.visrect = rect;
|
||||
offset_rect( &src.visrect, src.x - dst.x, src.y - dst.y );
|
||||
if (is_rect_empty( &dst.visrect )) goto done;
|
||||
if (clip) OffsetRgn( clip, dst.x - src.x, dst.y - src.y );
|
||||
if (clip) NtGdiOffsetRgn( clip, dst.x - src.x, dst.y - src.y );
|
||||
|
||||
dev = GET_DC_PHYSDEV( dc, pPutImage );
|
||||
copy_bitmapinfo( dst_info, src_info );
|
||||
|
|
|
@ -1012,7 +1012,7 @@ DWORD CDECL dibdrv_PutImage( PHYSDEV dev, HRGN clip, BITMAPINFO *info,
|
|||
if (clip && pdev->clip)
|
||||
{
|
||||
tmp_rgn = NtGdiCreateRectRgn( 0, 0, 0, 0 );
|
||||
CombineRgn( tmp_rgn, clip, pdev->clip, RGN_AND );
|
||||
NtGdiCombineRgn( tmp_rgn, clip, pdev->clip, RGN_AND );
|
||||
clip = tmp_rgn;
|
||||
}
|
||||
else if (!clip) clip = pdev->clip;
|
||||
|
|
|
@ -81,14 +81,14 @@ static BOOL brush_rect( dibdrv_physdev *pdev, dib_brush *brush, const RECT *rect
|
|||
/* paint a region with the brush (note: the region can be modified) */
|
||||
static BOOL brush_region( dibdrv_physdev *pdev, HRGN region )
|
||||
{
|
||||
if (pdev->clip) CombineRgn( region, region, pdev->clip, RGN_AND );
|
||||
if (pdev->clip) NtGdiCombineRgn( region, region, pdev->clip, RGN_AND );
|
||||
return brush_rect( pdev, &pdev->brush, NULL, region );
|
||||
}
|
||||
|
||||
/* paint a region with the pen (note: the region can be modified) */
|
||||
static BOOL pen_region( dibdrv_physdev *pdev, HRGN region )
|
||||
{
|
||||
if (pdev->clip) CombineRgn( region, region, pdev->clip, RGN_AND );
|
||||
if (pdev->clip) NtGdiCombineRgn( region, region, pdev->clip, RGN_AND );
|
||||
return brush_rect( pdev, &pdev->pen_brush, NULL, region );
|
||||
}
|
||||
|
||||
|
@ -393,7 +393,7 @@ static BOOL draw_arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
|
|||
|
||||
if (interior)
|
||||
{
|
||||
CombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
NtGdiCombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
ret = brush_region( pdev, interior );
|
||||
DeleteObject( interior );
|
||||
}
|
||||
|
@ -458,7 +458,7 @@ static BOOL stroke_and_fill_path( dibdrv_physdev *dev, BOOL stroke, BOOL fill )
|
|||
|
||||
if (interior)
|
||||
{
|
||||
CombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
NtGdiCombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
ret = brush_region( dev, interior );
|
||||
DeleteObject( interior );
|
||||
}
|
||||
|
@ -1000,7 +1000,7 @@ BOOL CDECL dibdrv_Ellipse( PHYSDEV dev, INT left, INT top, INT right, INT bottom
|
|||
static inline BOOL is_interior( dib_info *dib, HRGN clip, int x, int y, DWORD pixel, UINT type)
|
||||
{
|
||||
/* the clip rgn stops the flooding */
|
||||
if (clip && !PtInRegion( clip, x, y )) return FALSE;
|
||||
if (clip && !NtGdiPtInRegion( clip, x, y )) return FALSE;
|
||||
|
||||
if (type == FLOODFILLBORDER)
|
||||
return dib->funcs->get_pixel( dib, x, y ) != pixel;
|
||||
|
@ -1022,12 +1022,12 @@ static inline void do_next_row( dib_info *dib, HRGN clip, const RECT *row, int o
|
|||
if (is_interior( dib, clip, next.right, next.top, pixel, type)) next.right++;
|
||||
else
|
||||
{
|
||||
if (next.left != next.right && !PtInRegion( rgn, next.left, next.top ))
|
||||
if (next.left != next.right && !NtGdiPtInRegion( rgn, next.left, next.top ))
|
||||
fill_row( dib, clip, &next, pixel, type, rgn );
|
||||
next.left = ++next.right;
|
||||
}
|
||||
}
|
||||
if (next.left != next.right && !PtInRegion( rgn, next.left, next.top ))
|
||||
if (next.left != next.right && !NtGdiPtInRegion( rgn, next.left, next.top ))
|
||||
fill_row( dib, clip, &next, pixel, type, rgn );
|
||||
}
|
||||
|
||||
|
@ -1297,7 +1297,7 @@ BOOL CDECL dibdrv_PolyPolygon( PHYSDEV dev, const POINT *pt, const INT *counts,
|
|||
|
||||
if (interior)
|
||||
{
|
||||
CombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
NtGdiCombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
ret = brush_region( pdev, interior );
|
||||
DeleteObject( interior );
|
||||
}
|
||||
|
@ -1442,7 +1442,7 @@ BOOL CDECL dibdrv_Rectangle( PHYSDEV dev, INT left, INT top, INT right, INT bott
|
|||
{
|
||||
HRGN interior = CreateRectRgnIndirect( &rect );
|
||||
|
||||
CombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
NtGdiCombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
brush_region( pdev, interior );
|
||||
DeleteObject( interior );
|
||||
}
|
||||
|
@ -1560,7 +1560,7 @@ BOOL CDECL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bott
|
|||
|
||||
if (interior)
|
||||
{
|
||||
CombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
NtGdiCombineRgn( interior, interior, outline, RGN_DIFF );
|
||||
ret = brush_region( pdev, interior );
|
||||
DeleteObject( interior );
|
||||
}
|
||||
|
|
|
@ -1259,9 +1259,9 @@ static void add_cap( dibdrv_physdev *pdev, HRGN region, HRGN round_cap, const PO
|
|||
default: FIXME( "Unknown end cap %x\n", pdev->pen_endcap );
|
||||
/* fall through */
|
||||
case PS_ENDCAP_ROUND:
|
||||
OffsetRgn( round_cap, pt->x, pt->y );
|
||||
CombineRgn( region, region, round_cap, RGN_OR );
|
||||
OffsetRgn( round_cap, -pt->x, -pt->y );
|
||||
NtGdiOffsetRgn( round_cap, pt->x, pt->y );
|
||||
NtGdiCombineRgn( region, region, round_cap, RGN_OR );
|
||||
NtGdiOffsetRgn( round_cap, -pt->x, -pt->y );
|
||||
return;
|
||||
|
||||
case PS_ENDCAP_SQUARE: /* already been handled */
|
||||
|
@ -1341,13 +1341,13 @@ static void add_join( dibdrv_physdev *pdev, HRGN region, HRGN round_cap, const P
|
|||
default: FIXME( "Unknown line join %x\n", pdev->pen_join );
|
||||
/* fall through */
|
||||
case PS_JOIN_ROUND:
|
||||
GetRgnBox( round_cap, &rect );
|
||||
NtGdiGetRgnBox( round_cap, &rect );
|
||||
offset_rect( &rect, pt->x, pt->y );
|
||||
if (clip_rect_to_dib( &pdev->dib, &rect ))
|
||||
{
|
||||
OffsetRgn( round_cap, pt->x, pt->y );
|
||||
CombineRgn( region, region, round_cap, RGN_OR );
|
||||
OffsetRgn( round_cap, -pt->x, -pt->y );
|
||||
NtGdiOffsetRgn( round_cap, pt->x, pt->y );
|
||||
NtGdiCombineRgn( region, region, round_cap, RGN_OR );
|
||||
NtGdiOffsetRgn( round_cap, -pt->x, -pt->y );
|
||||
}
|
||||
return;
|
||||
|
||||
|
@ -1364,9 +1364,9 @@ static void add_join( dibdrv_physdev *pdev, HRGN region, HRGN round_cap, const P
|
|||
break;
|
||||
}
|
||||
|
||||
GetRgnBox( join, &rect );
|
||||
NtGdiGetRgnBox( join, &rect );
|
||||
if (clip_rect_to_dib( &pdev->dib, &rect ))
|
||||
CombineRgn( region, region, join, RGN_OR );
|
||||
NtGdiCombineRgn( region, region, join, RGN_OR );
|
||||
DeleteObject( join );
|
||||
return;
|
||||
}
|
||||
|
@ -1498,7 +1498,7 @@ static BOOL wide_line_segment( dibdrv_physdev *pdev, HRGN total,
|
|||
if (clip_rect_to_dib( &pdev->dib, &clip_rect ))
|
||||
{
|
||||
segment = CreatePolygonRgn( seg_pts, 4, ALTERNATE );
|
||||
CombineRgn( total, total, segment, RGN_OR );
|
||||
NtGdiCombineRgn( total, total, segment, RGN_OR );
|
||||
DeleteObject( segment );
|
||||
}
|
||||
|
||||
|
|
|
@ -216,11 +216,11 @@ INT CDECL EMFDRV_ExtSelectClipRgn( PHYSDEV dev, HRGN hrgn, INT mode )
|
|||
if (mode != RGN_COPY) return ERROR;
|
||||
rgnsize = 0;
|
||||
}
|
||||
else rgnsize = GetRegionData( hrgn, 0, NULL );
|
||||
else rgnsize = NtGdiGetRegionData( hrgn, 0, NULL );
|
||||
|
||||
size = rgnsize + offsetof(EMREXTSELECTCLIPRGN,RgnData);
|
||||
emr = HeapAlloc( GetProcessHeap(), 0, size );
|
||||
if (rgnsize) GetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
if (rgnsize) NtGdiGetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
|
||||
emr->emr.iType = EMR_EXTSELECTCLIPRGN;
|
||||
emr->emr.nSize = size;
|
||||
|
|
|
@ -687,11 +687,11 @@ BOOL CDECL EMFDRV_FillRgn( PHYSDEV dev, HRGN hrgn, HBRUSH hbrush )
|
|||
index = EMFDRV_CreateBrushIndirect( dev, hbrush );
|
||||
if(!index) return FALSE;
|
||||
|
||||
rgnsize = GetRegionData( hrgn, 0, NULL );
|
||||
rgnsize = NtGdiGetRegionData( hrgn, 0, NULL );
|
||||
size = rgnsize + offsetof(EMRFILLRGN,RgnData);
|
||||
emr = HeapAlloc( GetProcessHeap(), 0, size );
|
||||
|
||||
GetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
NtGdiGetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
|
||||
emr->emr.iType = EMR_FILLRGN;
|
||||
emr->emr.nSize = size;
|
||||
|
@ -720,11 +720,11 @@ BOOL CDECL EMFDRV_FrameRgn( PHYSDEV dev, HRGN hrgn, HBRUSH hbrush, INT width, IN
|
|||
index = EMFDRV_CreateBrushIndirect( dev, hbrush );
|
||||
if(!index) return FALSE;
|
||||
|
||||
rgnsize = GetRegionData( hrgn, 0, NULL );
|
||||
rgnsize = NtGdiGetRegionData( hrgn, 0, NULL );
|
||||
size = rgnsize + offsetof(EMRFRAMERGN,RgnData);
|
||||
emr = HeapAlloc( GetProcessHeap(), 0, size );
|
||||
|
||||
GetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
NtGdiGetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
|
||||
emr->emr.iType = EMR_FRAMERGN;
|
||||
emr->emr.nSize = size;
|
||||
|
@ -756,11 +756,11 @@ static BOOL EMFDRV_PaintInvertRgn( PHYSDEV dev, HRGN hrgn, DWORD iType )
|
|||
BOOL ret;
|
||||
|
||||
|
||||
rgnsize = GetRegionData( hrgn, 0, NULL );
|
||||
rgnsize = NtGdiGetRegionData( hrgn, 0, NULL );
|
||||
size = rgnsize + offsetof(EMRINVERTRGN,RgnData);
|
||||
emr = HeapAlloc( GetProcessHeap(), 0, size );
|
||||
|
||||
GetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
NtGdiGetRegionData( hrgn, rgnsize, (RGNDATA *)&emr->RgnData );
|
||||
|
||||
emr->emr.iType = iType;
|
||||
emr->emr.nSize = size;
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
@ stdcall CloseMetaFile(long)
|
||||
@ stub ColorCorrectPalette
|
||||
@ stub ColorMatchToTarget
|
||||
@ stdcall CombineRgn(long long long long)
|
||||
@ stdcall CombineRgn(long long long long) NtGdiCombineRgn
|
||||
@ stdcall CombineTransform(ptr ptr ptr)
|
||||
@ stdcall CopyEnhMetaFileA(long str)
|
||||
@ stdcall CopyEnhMetaFileW(long wstr)
|
||||
|
@ -120,7 +120,7 @@
|
|||
@ stdcall EnumICMProfilesW(long ptr long)
|
||||
@ stdcall EnumMetaFile(long long ptr ptr)
|
||||
@ stdcall EnumObjects(long long ptr long)
|
||||
@ stdcall EqualRgn(long long)
|
||||
@ stdcall EqualRgn(long long) NtGdiEqualRgn
|
||||
@ stdcall Escape(long long long ptr ptr)
|
||||
# @ stub EudcLoadLinkW
|
||||
# @ stub EudcUnloadLinkW
|
||||
|
@ -333,9 +333,9 @@
|
|||
@ stdcall GetROP2(long)
|
||||
@ stdcall GetRandomRgn(long long long)
|
||||
@ stdcall GetRasterizerCaps(ptr long)
|
||||
@ stdcall GetRegionData(long long ptr)
|
||||
@ stdcall GetRegionData(long long ptr) NtGdiGetRegionData
|
||||
@ stdcall GetRelAbs(long long)
|
||||
@ stdcall GetRgnBox(long ptr)
|
||||
@ stdcall GetRgnBox(long ptr) NtGdiGetRgnBox
|
||||
@ stdcall GetStockObject(long)
|
||||
@ stdcall GetStretchBltMode(long)
|
||||
# @ stub GetStringBitmapA
|
||||
|
@ -383,7 +383,7 @@
|
|||
@ stdcall MoveToEx(long long long ptr)
|
||||
@ stdcall NamedEscape(long wstr long long ptr long ptr)
|
||||
@ stdcall OffsetClipRgn(long long long)
|
||||
@ stdcall OffsetRgn(long long long)
|
||||
@ stdcall OffsetRgn(long long long) NtGdiOffsetRgn
|
||||
@ stdcall OffsetViewportOrgEx(long long long ptr)
|
||||
@ stdcall OffsetWindowOrgEx(long long long ptr)
|
||||
@ stdcall PaintRgn(long long)
|
||||
|
@ -406,11 +406,11 @@
|
|||
@ stdcall Polygon(long ptr long)
|
||||
@ stdcall Polyline(long ptr long)
|
||||
@ stdcall PolylineTo(long ptr long)
|
||||
@ stdcall PtInRegion(long long long)
|
||||
@ stdcall PtInRegion(long long long) NtGdiPtInRegion
|
||||
@ stdcall PtVisible(long long long)
|
||||
# @ stub QueryFontAssocStatus
|
||||
@ stdcall RealizePalette(long)
|
||||
@ stdcall RectInRegion(long ptr)
|
||||
@ stdcall RectInRegion(long ptr) NtGdiRectInRegion
|
||||
@ stdcall RectVisible(long ptr)
|
||||
@ stdcall Rectangle(long long long long long)
|
||||
@ stdcall RemoveFontMemResourceEx(ptr)
|
||||
|
@ -510,7 +510,7 @@
|
|||
@ stdcall SetPixelV(long long long long)
|
||||
@ stdcall SetPolyFillMode(long long)
|
||||
@ stdcall SetROP2(long long)
|
||||
@ stdcall SetRectRgn(long long long long long)
|
||||
@ stdcall SetRectRgn(long long long long long) NtGdiSetRectRgn
|
||||
@ stdcall SetRelAbs(long long)
|
||||
@ stdcall SetStretchBltMode(long long)
|
||||
@ stdcall SetSystemPaletteUse(long long)
|
||||
|
|
|
@ -1296,9 +1296,9 @@ static BOOL MF_Play_MetaCreateRegion( METARECORD *mr, HRGN hrgn )
|
|||
y0 = *(INT16 *)(start + 1);
|
||||
y1 = *(INT16 *)(start + 2);
|
||||
for(pair = 0; pair < *start / 2; pair++) {
|
||||
SetRectRgn( hrgn2, *(INT16 *)(start + 3 + 2*pair), y0,
|
||||
*(INT16 *)(start + 4 + 2*pair), y1 );
|
||||
CombineRgn(hrgn, hrgn, hrgn2, RGN_OR);
|
||||
NtGdiSetRectRgn( hrgn2, *(INT16 *)(start + 3 + 2*pair), y0,
|
||||
*(INT16 *)(start + 4 + 2*pair), y1 );
|
||||
NtGdiCombineRgn( hrgn, hrgn, hrgn2, RGN_OR );
|
||||
}
|
||||
}
|
||||
DeleteObject( hrgn2 );
|
||||
|
|
|
@ -264,12 +264,12 @@ static INT16 MFDRV_CreateRegion(PHYSDEV dev, HRGN hrgn)
|
|||
WORD *Param, *StartBand;
|
||||
BOOL ret;
|
||||
|
||||
if (!(len = GetRegionData( hrgn, 0, NULL ))) return -1;
|
||||
if (!(len = NtGdiGetRegionData( hrgn, 0, NULL ))) return -1;
|
||||
if( !(rgndata = HeapAlloc( GetProcessHeap(), 0, len )) ) {
|
||||
WARN("Can't alloc rgndata buffer\n");
|
||||
return -1;
|
||||
}
|
||||
GetRegionData( hrgn, len, rgndata );
|
||||
NtGdiGetRegionData( hrgn, len, rgndata );
|
||||
|
||||
/* Overestimate of length:
|
||||
* Assume every rect is a separate band -> 6 WORDs per rect
|
||||
|
|
|
@ -518,7 +518,7 @@ static BOOL REGION_OffsetRegion( WINEREGION *rgn, WINEREGION *srcrgn, INT x, INT
|
|||
}
|
||||
|
||||
/***********************************************************************
|
||||
* OffsetRgn (GDI32.@)
|
||||
* NtGdiOffsetRgn (win32u.@)
|
||||
*
|
||||
* Moves a region by the specified X- and Y-axis offsets.
|
||||
*
|
||||
|
@ -535,7 +535,7 @@ static BOOL REGION_OffsetRegion( WINEREGION *rgn, WINEREGION *srcrgn, INT x, INT
|
|||
* one rectangle.
|
||||
* Failure: ERROR
|
||||
*/
|
||||
INT WINAPI OffsetRgn( HRGN hrgn, INT x, INT y )
|
||||
INT WINAPI NtGdiOffsetRgn( HRGN hrgn, INT x, INT y )
|
||||
{
|
||||
WINEREGION *obj = GDI_GetObjPtr( hrgn, OBJ_REGION );
|
||||
INT ret;
|
||||
|
@ -554,7 +554,7 @@ INT WINAPI OffsetRgn( HRGN hrgn, INT x, INT y )
|
|||
|
||||
|
||||
/***********************************************************************
|
||||
* GetRgnBox (GDI32.@)
|
||||
* NtGdiGetRgnBox (win32u.@)
|
||||
*
|
||||
* Retrieves the bounding rectangle of the region. The bounding rectangle
|
||||
* is the smallest rectangle that contains the entire region.
|
||||
|
@ -570,7 +570,7 @@ INT WINAPI OffsetRgn( HRGN hrgn, INT x, INT y )
|
|||
* COMPLEXREGION - The new region can only be represented by more than
|
||||
* one rectangle.
|
||||
*/
|
||||
INT WINAPI GetRgnBox( HRGN hrgn, LPRECT rect )
|
||||
INT WINAPI NtGdiGetRgnBox( HRGN hrgn, RECT *rect )
|
||||
{
|
||||
WINEREGION *obj = GDI_GetObjPtr( hrgn, OBJ_REGION );
|
||||
if (obj)
|
||||
|
@ -617,7 +617,7 @@ HRGN WINAPI NtGdiCreateRectRgn( INT left, INT top, INT right, INT bottom )
|
|||
return 0;
|
||||
}
|
||||
TRACE( "%d,%d-%d,%d returning %p\n", left, top, right, bottom, hrgn );
|
||||
SetRectRgn(hrgn, left, top, right, bottom);
|
||||
NtGdiSetRectRgn( hrgn, left, top, right, bottom );
|
||||
return hrgn;
|
||||
}
|
||||
|
||||
|
@ -641,7 +641,7 @@ HRGN WINAPI CreateRectRgnIndirect( const RECT* rect )
|
|||
|
||||
|
||||
/***********************************************************************
|
||||
* SetRectRgn (GDI32.@)
|
||||
* NtGdiSetRectRgn (win32u.@)
|
||||
*
|
||||
* Sets a region to a simple rectangular region.
|
||||
*
|
||||
|
@ -659,8 +659,7 @@ HRGN WINAPI CreateRectRgnIndirect( const RECT* rect )
|
|||
* NOTES
|
||||
* Allows either or both left and top to be greater than right or bottom.
|
||||
*/
|
||||
BOOL WINAPI SetRectRgn( HRGN hrgn, INT left, INT top,
|
||||
INT right, INT bottom )
|
||||
BOOL WINAPI NtGdiSetRectRgn( HRGN hrgn, INT left, INT top, INT right, INT bottom )
|
||||
{
|
||||
WINEREGION *obj;
|
||||
|
||||
|
@ -846,7 +845,7 @@ HRGN WINAPI CreateEllipticRgnIndirect( const RECT *rect )
|
|||
}
|
||||
|
||||
/***********************************************************************
|
||||
* GetRegionData (GDI32.@)
|
||||
* NtGdiGetRegionData (win32u.@)
|
||||
*
|
||||
* Retrieves the data that specifies the region.
|
||||
*
|
||||
|
@ -867,7 +866,7 @@ HRGN WINAPI CreateEllipticRgnIndirect( const RECT *rect )
|
|||
* is the array of RECT's that specify the region. The length of the array
|
||||
* is specified by the nCount member of the region data header.
|
||||
*/
|
||||
DWORD WINAPI GetRegionData(HRGN hrgn, DWORD count, LPRGNDATA rgndata)
|
||||
DWORD WINAPI NtGdiGetRegionData( HRGN hrgn, DWORD count, RGNDATA *rgndata )
|
||||
{
|
||||
DWORD size;
|
||||
WINEREGION *obj = GDI_GetObjPtr( hrgn, OBJ_REGION );
|
||||
|
@ -969,7 +968,7 @@ HRGN WINAPI NtGdiExtCreateRegion( const XFORM *xform, DWORD count, const RGNDATA
|
|||
|
||||
translate( pt, 4, xform );
|
||||
poly_hrgn = CreatePolyPolygonRgn( pt, &count, 1, WINDING );
|
||||
CombineRgn( hrgn, hrgn, poly_hrgn, RGN_OR );
|
||||
NtGdiCombineRgn( hrgn, hrgn, poly_hrgn, RGN_OR );
|
||||
DeleteObject( poly_hrgn );
|
||||
}
|
||||
return hrgn;
|
||||
|
@ -996,7 +995,7 @@ done:
|
|||
|
||||
|
||||
/***********************************************************************
|
||||
* PtInRegion (GDI32.@)
|
||||
* NtGdiPtInRegion (win32u.@)
|
||||
*
|
||||
* Tests whether the specified point is inside a region.
|
||||
*
|
||||
|
@ -1008,7 +1007,7 @@ done:
|
|||
* RETURNS
|
||||
* Non-zero if the point is inside the region or zero otherwise.
|
||||
*/
|
||||
BOOL WINAPI PtInRegion( HRGN hrgn, INT x, INT y )
|
||||
BOOL WINAPI NtGdiPtInRegion( HRGN hrgn, INT x, INT y )
|
||||
{
|
||||
WINEREGION *obj;
|
||||
BOOL ret = FALSE;
|
||||
|
@ -1024,7 +1023,7 @@ BOOL WINAPI PtInRegion( HRGN hrgn, INT x, INT y )
|
|||
|
||||
|
||||
/***********************************************************************
|
||||
* RectInRegion (GDI32.@)
|
||||
* NtGdiRectInRegion (win32u.@)
|
||||
*
|
||||
* Tests if a rectangle is at least partly inside the specified region.
|
||||
*
|
||||
|
@ -1036,7 +1035,7 @@ BOOL WINAPI PtInRegion( HRGN hrgn, INT x, INT y )
|
|||
* Non-zero if the rectangle is partially inside the region or
|
||||
* zero otherwise.
|
||||
*/
|
||||
BOOL WINAPI RectInRegion( HRGN hrgn, const RECT *rect )
|
||||
BOOL WINAPI NtGdiRectInRegion( HRGN hrgn, const RECT *rect )
|
||||
{
|
||||
WINEREGION *obj;
|
||||
BOOL ret = FALSE;
|
||||
|
@ -1075,7 +1074,7 @@ BOOL WINAPI RectInRegion( HRGN hrgn, const RECT *rect )
|
|||
}
|
||||
|
||||
/***********************************************************************
|
||||
* EqualRgn (GDI32.@)
|
||||
* NtGdiEqualRgn (win32u.@)
|
||||
*
|
||||
* Tests whether one region is identical to another.
|
||||
*
|
||||
|
@ -1086,7 +1085,7 @@ BOOL WINAPI RectInRegion( HRGN hrgn, const RECT *rect )
|
|||
* RETURNS
|
||||
* Non-zero if both regions are identical or zero otherwise.
|
||||
*/
|
||||
BOOL WINAPI EqualRgn( HRGN hrgn1, HRGN hrgn2 )
|
||||
BOOL WINAPI NtGdiEqualRgn( HRGN hrgn1, HRGN hrgn2 )
|
||||
{
|
||||
WINEREGION *obj1, *obj2;
|
||||
BOOL ret = FALSE;
|
||||
|
@ -1191,7 +1190,7 @@ done:
|
|||
|
||||
|
||||
/***********************************************************************
|
||||
* CombineRgn (GDI32.@)
|
||||
* NtGdiCombineRgn (win32u.@)
|
||||
*
|
||||
* Combines two regions with the specified operation and stores the result
|
||||
* in the specified destination region.
|
||||
|
@ -1218,7 +1217,7 @@ done:
|
|||
*| RGN_XOR - Unions of the regions minus any intersection.
|
||||
*| RGN_DIFF - Difference (subtraction) of the regions.
|
||||
*/
|
||||
INT WINAPI CombineRgn(HRGN hDest, HRGN hSrc1, HRGN hSrc2, INT mode)
|
||||
INT WINAPI NtGdiCombineRgn( HRGN hDest, HRGN hSrc1, HRGN hSrc2, INT mode )
|
||||
{
|
||||
WINEREGION *destObj = GDI_GetObjPtr( hDest, OBJ_REGION );
|
||||
INT result = ERROR;
|
||||
|
|
Loading…
Reference in New Issue