xref: /reactos/win32ss/gdi/gdi32/wine/path.c (revision 333b8f19)
1c2c66affSColin Finck //
2c2c66affSColin Finck //
3c2c66affSColin Finck // Do not remove this file, "Justin Case" future maintenance issues with Path arises.......
4c2c66affSColin Finck //
5c2c66affSColin Finck //
6c2c66affSColin Finck 
7c2c66affSColin Finck #include <precomp.h>
8c2c66affSColin Finck #include "gdi_private.h"
9c2c66affSColin Finck 
10c2c66affSColin Finck #define NDEBUG
11c2c66affSColin Finck #include <debug.h>
12c2c66affSColin Finck 
13c2c66affSColin Finck WINEDC *get_nulldrv_dc( PHYSDEV dev );
14c2c66affSColin Finck const struct gdi_dc_funcs path_driver DECLSPEC_HIDDEN;
15c2c66affSColin Finck 
16c2c66affSColin Finck struct path_physdev
17c2c66affSColin Finck {
18c2c66affSColin Finck     struct gdi_physdev dev;
19c2c66affSColin Finck     //struct gdi_path   *path;
20c2c66affSColin Finck     BOOL HasPathHook;
21c2c66affSColin Finck };
22c2c66affSColin Finck 
get_path_physdev(PHYSDEV dev)23c2c66affSColin Finck static inline struct path_physdev *get_path_physdev( PHYSDEV dev )
24c2c66affSColin Finck {
25c2c66affSColin Finck     return CONTAINING_RECORD( dev, struct path_physdev, dev );
26c2c66affSColin Finck }
27c2c66affSColin Finck 
28c2c66affSColin Finck /***********************************************************************
29c2c66affSColin Finck  *           pathdrv_BeginPath
30c2c66affSColin Finck  */
pathdrv_BeginPath(PHYSDEV dev)31c2c66affSColin Finck static BOOL pathdrv_BeginPath( PHYSDEV dev )
32c2c66affSColin Finck {
33c2c66affSColin Finck     DPRINT("pathdrv_BeginPath dev %p\n",dev);
34c2c66affSColin Finck     return TRUE;
35c2c66affSColin Finck }
36c2c66affSColin Finck 
37c2c66affSColin Finck 
38c2c66affSColin Finck /***********************************************************************
39c2c66affSColin Finck  *           pathdrv_AbortPath
40c2c66affSColin Finck  */
pathdrv_AbortPath(PHYSDEV dev)41c2c66affSColin Finck static BOOL pathdrv_AbortPath( PHYSDEV dev )
42c2c66affSColin Finck {
43c2c66affSColin Finck     DC *dc = get_physdev_dc( dev );
44c2c66affSColin Finck     DPRINT("pathdrv_AbortPath dev %p\n",dev);
45c2c66affSColin Finck     path_driver.pDeleteDC( pop_dc_driver( dc, &path_driver ));
46c2c66affSColin Finck     return TRUE;
47c2c66affSColin Finck }
48c2c66affSColin Finck 
49c2c66affSColin Finck 
50c2c66affSColin Finck /***********************************************************************
51c2c66affSColin Finck  *           pathdrv_EndPath
52c2c66affSColin Finck  */
pathdrv_EndPath(PHYSDEV dev)53c2c66affSColin Finck static BOOL pathdrv_EndPath( PHYSDEV dev )
54c2c66affSColin Finck {
55c2c66affSColin Finck     struct path_physdev *physdev = get_path_physdev( dev );
56c2c66affSColin Finck     DC *dc = get_physdev_dc( dev );
57c2c66affSColin Finck 
58c2c66affSColin Finck     DPRINT("pathdrv_EndPath dev %p\n",dev);
59c2c66affSColin Finck 
60c2c66affSColin Finck     pop_dc_driver( dc, &path_driver );
61c2c66affSColin Finck     HeapFree( GetProcessHeap(), 0, physdev );
62c2c66affSColin Finck 
63c2c66affSColin Finck     return TRUE;
64c2c66affSColin Finck }
65c2c66affSColin Finck 
66c2c66affSColin Finck 
67c2c66affSColin Finck /***********************************************************************
68c2c66affSColin Finck  *           pathdrv_CreateDC
69c2c66affSColin Finck  */
pathdrv_CreateDC(PHYSDEV * dev,LPCWSTR driver,LPCWSTR device,LPCWSTR output,const DEVMODEW * devmode)70c2c66affSColin Finck static BOOL pathdrv_CreateDC( PHYSDEV *dev, LPCWSTR driver, LPCWSTR device,
71c2c66affSColin Finck                               LPCWSTR output, const DEVMODEW *devmode )
72c2c66affSColin Finck {
73c2c66affSColin Finck     struct path_physdev *physdev = HeapAlloc( GetProcessHeap(), 0, sizeof(*physdev) );
74c2c66affSColin Finck     DPRINT("pathdrv_CreateDC dev %p\n",dev);
75c2c66affSColin Finck     if (!physdev) return FALSE;
76c2c66affSColin Finck     push_dc_driver( dev, &physdev->dev, &path_driver );
77c2c66affSColin Finck     return TRUE;
78c2c66affSColin Finck }
79c2c66affSColin Finck 
80c2c66affSColin Finck 
81c2c66affSColin Finck /*************************************************************
82c2c66affSColin Finck  *           pathdrv_DeleteDC
83c2c66affSColin Finck  */
pathdrv_DeleteDC(PHYSDEV dev)84c2c66affSColin Finck static BOOL pathdrv_DeleteDC( PHYSDEV dev )
85c2c66affSColin Finck {
86c2c66affSColin Finck     struct path_physdev *physdev = get_path_physdev( dev );
87c2c66affSColin Finck     DPRINT("pathdrv_DeleteDC dev %p\n",dev);
88c2c66affSColin Finck     HeapFree( GetProcessHeap(), 0, physdev );
89c2c66affSColin Finck     return TRUE;
90c2c66affSColin Finck }
91c2c66affSColin Finck 
92c2c66affSColin Finck /*************************************************************
93c2c66affSColin Finck  *           pathdrv_MoveTo
94c2c66affSColin Finck  */
pathdrv_MoveTo(PHYSDEV dev,INT x,INT y)95c2c66affSColin Finck static BOOL pathdrv_MoveTo( PHYSDEV dev, INT x, INT y )
96c2c66affSColin Finck {
97c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
98c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
99c2c66affSColin Finck     DPRINT("pathdrv_MoveTo dev %p\n",dev);
100c2c66affSColin Finck     return TRUE;
101c2c66affSColin Finck }
102c2c66affSColin Finck 
103c2c66affSColin Finck 
104c2c66affSColin Finck /*************************************************************
105c2c66affSColin Finck  *           pathdrv_LineTo
106c2c66affSColin Finck  */
pathdrv_LineTo(PHYSDEV dev,INT x,INT y)107c2c66affSColin Finck static BOOL pathdrv_LineTo( PHYSDEV dev, INT x, INT y )
108c2c66affSColin Finck {
109c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
110c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
111c2c66affSColin Finck     DPRINT("pathdrv_LineTo dev %p\n",dev);
112c2c66affSColin Finck     return TRUE;
113c2c66affSColin Finck }
114c2c66affSColin Finck 
115c2c66affSColin Finck 
116c2c66affSColin Finck /*************************************************************
117c2c66affSColin Finck  *           pathdrv_Rectangle
118c2c66affSColin Finck  */
pathdrv_Rectangle(PHYSDEV dev,INT x1,INT y1,INT x2,INT y2)119c2c66affSColin Finck static BOOL pathdrv_Rectangle( PHYSDEV dev, INT x1, INT y1, INT x2, INT y2 )
120c2c66affSColin Finck {
121c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
122c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
123c2c66affSColin Finck     DPRINT("pathdrv_Rectangle dev %p\n",dev);
124c2c66affSColin Finck     return TRUE;
125c2c66affSColin Finck }
126c2c66affSColin Finck 
127c2c66affSColin Finck 
128c2c66affSColin Finck /*************************************************************
129c2c66affSColin Finck  *           pathdrv_RoundRect
130c2c66affSColin Finck  */
pathdrv_RoundRect(PHYSDEV dev,INT x1,INT y1,INT x2,INT y2,INT ell_width,INT ell_height)131c2c66affSColin Finck static BOOL pathdrv_RoundRect( PHYSDEV dev, INT x1, INT y1, INT x2, INT y2, INT ell_width, INT ell_height )
132c2c66affSColin Finck {
133c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
134c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
135c2c66affSColin Finck     DPRINT("pathdrv_RoundRect dev %p\n",dev);
136c2c66affSColin Finck     return TRUE;
137c2c66affSColin Finck }
138c2c66affSColin Finck 
139c2c66affSColin Finck 
140c2c66affSColin Finck /*************************************************************
141c2c66affSColin Finck  *           pathdrv_Ellipse
142c2c66affSColin Finck  */
pathdrv_Ellipse(PHYSDEV dev,INT x1,INT y1,INT x2,INT y2)143c2c66affSColin Finck static BOOL pathdrv_Ellipse( PHYSDEV dev, INT x1, INT y1, INT x2, INT y2 )
144c2c66affSColin Finck {
145c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
146c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
147c2c66affSColin Finck     DPRINT("pathdrv_Ellipse dev %p\n",dev);
148c2c66affSColin Finck     return TRUE;
149c2c66affSColin Finck }
150c2c66affSColin Finck 
151c2c66affSColin Finck /*************************************************************
152c2c66affSColin Finck  *           pathdrv_AngleArc
153c2c66affSColin Finck  */
pathdrv_AngleArc(PHYSDEV dev,INT x,INT y,DWORD radius,FLOAT eStartAngle,FLOAT eSweepAngle)154c2c66affSColin Finck static BOOL pathdrv_AngleArc( PHYSDEV dev, INT x, INT y, DWORD radius, FLOAT eStartAngle, FLOAT eSweepAngle)
155c2c66affSColin Finck {
156c2c66affSColin Finck     DPRINT("pathdrv_AngleArc dev %p\n",dev);
157c2c66affSColin Finck     return TRUE;
158c2c66affSColin Finck }
159c2c66affSColin Finck 
160c2c66affSColin Finck 
161c2c66affSColin Finck /*************************************************************
162c2c66affSColin Finck  *           pathdrv_Arc
163c2c66affSColin Finck  */
pathdrv_Arc(PHYSDEV dev,INT left,INT top,INT right,INT bottom,INT xstart,INT ystart,INT xend,INT yend)164c2c66affSColin Finck static BOOL pathdrv_Arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
165c2c66affSColin Finck                          INT xstart, INT ystart, INT xend, INT yend )
166c2c66affSColin Finck {
167c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
168c2c66affSColin Finck     DPRINT("pathdrv_Arc dev %p\n",dev);
169c2c66affSColin Finck     return TRUE;
170c2c66affSColin Finck }
171c2c66affSColin Finck 
172c2c66affSColin Finck 
173c2c66affSColin Finck /*************************************************************
174c2c66affSColin Finck  *           pathdrv_ArcTo
175c2c66affSColin Finck  */
pathdrv_ArcTo(PHYSDEV dev,INT left,INT top,INT right,INT bottom,INT xstart,INT ystart,INT xend,INT yend)176c2c66affSColin Finck static BOOL pathdrv_ArcTo( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
177c2c66affSColin Finck                            INT xstart, INT ystart, INT xend, INT yend )
178c2c66affSColin Finck {
179c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
180c2c66affSColin Finck     DPRINT("pathdrv_ArcTo dev %p\n",dev);
181c2c66affSColin Finck     return TRUE;
182c2c66affSColin Finck }
183c2c66affSColin Finck 
184c2c66affSColin Finck 
185c2c66affSColin Finck /*************************************************************
186c2c66affSColin Finck  *           pathdrv_Chord
187c2c66affSColin Finck  */
pathdrv_Chord(PHYSDEV dev,INT left,INT top,INT right,INT bottom,INT xstart,INT ystart,INT xend,INT yend)188c2c66affSColin Finck static BOOL pathdrv_Chord( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
189c2c66affSColin Finck                            INT xstart, INT ystart, INT xend, INT yend )
190c2c66affSColin Finck {
191c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
192c2c66affSColin Finck     DPRINT("pathdrv_Chord dev %p\n",dev);
193c2c66affSColin Finck     return TRUE;
194c2c66affSColin Finck }
195c2c66affSColin Finck 
196c2c66affSColin Finck 
197c2c66affSColin Finck /*************************************************************
198c2c66affSColin Finck  *           pathdrv_Pie
199c2c66affSColin Finck  */
pathdrv_Pie(PHYSDEV dev,INT left,INT top,INT right,INT bottom,INT xstart,INT ystart,INT xend,INT yend)200c2c66affSColin Finck static BOOL pathdrv_Pie( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
201c2c66affSColin Finck                          INT xstart, INT ystart, INT xend, INT yend )
202c2c66affSColin Finck {
203c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
204c2c66affSColin Finck     DPRINT("pathdrv_Pie dev %p\n",dev);
205c2c66affSColin Finck     return TRUE;
206c2c66affSColin Finck }
207c2c66affSColin Finck 
208c2c66affSColin Finck 
209c2c66affSColin Finck /*************************************************************
210c2c66affSColin Finck  *           pathdrv_PolyBezierTo
211c2c66affSColin Finck  */
pathdrv_PolyBezierTo(PHYSDEV dev,const POINT * pts,DWORD cbPoints)212c2c66affSColin Finck static BOOL pathdrv_PolyBezierTo( PHYSDEV dev, const POINT *pts, DWORD cbPoints )
213c2c66affSColin Finck {
214c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
215c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
216c2c66affSColin Finck     DPRINT("pathdrv_PolyBezierTo dev %p\n",dev);
217c2c66affSColin Finck     return TRUE;
218c2c66affSColin Finck }
219c2c66affSColin Finck 
220c2c66affSColin Finck 
221c2c66affSColin Finck /*************************************************************
222c2c66affSColin Finck  *           pathdrv_PolyBezier
223c2c66affSColin Finck  */
pathdrv_PolyBezier(PHYSDEV dev,const POINT * pts,DWORD cbPoints)224c2c66affSColin Finck static BOOL pathdrv_PolyBezier( PHYSDEV dev, const POINT *pts, DWORD cbPoints )
225c2c66affSColin Finck {
226c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
227c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
228c2c66affSColin Finck     DPRINT("pathdrv_PolyBezier dev %p\n",dev);
229c2c66affSColin Finck     return TRUE;
230c2c66affSColin Finck }
231c2c66affSColin Finck 
232c2c66affSColin Finck 
233c2c66affSColin Finck /*************************************************************
234c2c66affSColin Finck  *           pathdrv_PolyDraw
235c2c66affSColin Finck  */
pathdrv_PolyDraw(PHYSDEV dev,const POINT * pts,const BYTE * types,DWORD cbPoints)236c2c66affSColin Finck static BOOL pathdrv_PolyDraw( PHYSDEV dev, const POINT *pts, const BYTE *types, DWORD cbPoints )
237c2c66affSColin Finck {
238c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
239c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
240c2c66affSColin Finck     DPRINT("pathdrv_PolyDraw dev %p\n",dev);
241c2c66affSColin Finck     return TRUE;
242c2c66affSColin Finck }
243c2c66affSColin Finck 
244c2c66affSColin Finck 
245c2c66affSColin Finck /*************************************************************
246c2c66affSColin Finck  *           pathdrv_Polyline
247c2c66affSColin Finck  */
pathdrv_Polyline(PHYSDEV dev,const POINT * pts,INT count)248c2c66affSColin Finck static BOOL pathdrv_Polyline( PHYSDEV dev, const POINT *pts, INT count )
249c2c66affSColin Finck {
250c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
251c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
252c2c66affSColin Finck     DPRINT("pathdrv_PolyLine dev %p\n",dev);
253c2c66affSColin Finck     return TRUE;
254c2c66affSColin Finck }
255c2c66affSColin Finck 
256c2c66affSColin Finck 
257c2c66affSColin Finck /*************************************************************
258c2c66affSColin Finck  *           pathdrv_PolylineTo
259c2c66affSColin Finck  */
pathdrv_PolylineTo(PHYSDEV dev,const POINT * pts,INT count)260c2c66affSColin Finck static BOOL pathdrv_PolylineTo( PHYSDEV dev, const POINT *pts, INT count )
261c2c66affSColin Finck {
262c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
263c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
264c2c66affSColin Finck     DPRINT("pathdrv_PolyLineTo dev %p\n",dev);
265c2c66affSColin Finck     return TRUE;
266c2c66affSColin Finck }
267c2c66affSColin Finck 
268c2c66affSColin Finck 
269c2c66affSColin Finck /*************************************************************
270c2c66affSColin Finck  *           pathdrv_Polygon
271c2c66affSColin Finck  */
pathdrv_Polygon(PHYSDEV dev,const POINT * pts,INT count)272c2c66affSColin Finck static BOOL pathdrv_Polygon( PHYSDEV dev, const POINT *pts, INT count )
273c2c66affSColin Finck {
274c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
275c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
276c2c66affSColin Finck     DPRINT("pathdrv_Polygon dev %p\n",dev);
277c2c66affSColin Finck     return TRUE;
278c2c66affSColin Finck }
279c2c66affSColin Finck 
280c2c66affSColin Finck 
281c2c66affSColin Finck /*************************************************************
282c2c66affSColin Finck  *           pathdrv_PolyPolygon
283c2c66affSColin Finck  */
pathdrv_PolyPolygon(PHYSDEV dev,const POINT * pts,const INT * counts,UINT polygons)284c2c66affSColin Finck static BOOL pathdrv_PolyPolygon( PHYSDEV dev, const POINT* pts, const INT* counts, UINT polygons )
285c2c66affSColin Finck {
286c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
287c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
288c2c66affSColin Finck     DPRINT("pathdrv_PolyPolygon dev %p\n",dev);
289c2c66affSColin Finck     return TRUE;
290c2c66affSColin Finck }
291c2c66affSColin Finck 
292c2c66affSColin Finck 
293c2c66affSColin Finck /*************************************************************
294c2c66affSColin Finck  *           pathdrv_PolyPolyline
295c2c66affSColin Finck  */
pathdrv_PolyPolyline(PHYSDEV dev,const POINT * pts,const DWORD * counts,DWORD polylines)296c2c66affSColin Finck static BOOL pathdrv_PolyPolyline( PHYSDEV dev, const POINT* pts, const DWORD* counts, DWORD polylines )
297c2c66affSColin Finck {
298c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
299c2c66affSColin Finck //    DC *dc = get_physdev_dc( dev );
300c2c66affSColin Finck     DPRINT("pathdrv_PolyPolyline dev %p\n",dev);
301c2c66affSColin Finck     return TRUE;
302c2c66affSColin Finck }
303c2c66affSColin Finck 
304c2c66affSColin Finck 
305c2c66affSColin Finck /*************************************************************
306c2c66affSColin Finck  *           pathdrv_ExtTextOut
307c2c66affSColin Finck  */
pathdrv_ExtTextOut(PHYSDEV dev,INT x,INT y,UINT flags,const RECT * lprc,LPCWSTR str,UINT count,const INT * dx)308c2c66affSColin Finck static BOOL pathdrv_ExtTextOut( PHYSDEV dev, INT x, INT y, UINT flags, const RECT *lprc,
309c2c66affSColin Finck                                 LPCWSTR str, UINT count, const INT *dx )
310c2c66affSColin Finck {
311c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
312c2c66affSColin Finck     DPRINT("pathdrv_ExtTextOut dev %p\n",dev);
313c2c66affSColin Finck     return TRUE;
314c2c66affSColin Finck }
315c2c66affSColin Finck 
316c2c66affSColin Finck /*************************************************************
317c2c66affSColin Finck  *           pathdrv_CloseFigure
318c2c66affSColin Finck  */
pathdrv_CloseFigure(PHYSDEV dev)319c2c66affSColin Finck static BOOL pathdrv_CloseFigure( PHYSDEV dev )
320c2c66affSColin Finck {
321c2c66affSColin Finck //    struct path_physdev *physdev = get_path_physdev( dev );
322c2c66affSColin Finck     DPRINT("pathdrv_CloseFigure dev %p\n",dev);
323c2c66affSColin Finck     return TRUE;
324c2c66affSColin Finck }
325c2c66affSColin Finck 
326c2c66affSColin Finck 
327c2c66affSColin Finck /***********************************************************************
328c2c66affSColin Finck  *           null driver fallback implementations
329c2c66affSColin Finck  */
330c2c66affSColin Finck 
nulldrv_BeginPath(PHYSDEV dev)331c2c66affSColin Finck BOOL nulldrv_BeginPath( PHYSDEV dev )
332c2c66affSColin Finck {
333c2c66affSColin Finck     DC *dc = get_nulldrv_dc( dev );
334c2c66affSColin Finck     struct path_physdev *physdev;
335c2c66affSColin Finck 
336c2c66affSColin Finck     if (!path_driver.pCreateDC( &dc->physDev, NULL, NULL, NULL, NULL ))
337c2c66affSColin Finck     {
338c2c66affSColin Finck         return FALSE;
339c2c66affSColin Finck     }
340c2c66affSColin Finck     physdev = get_path_physdev( find_dc_driver( dc, &path_driver ));
341c2c66affSColin Finck     physdev->HasPathHook = TRUE;
342c2c66affSColin Finck     DPRINT("nulldrv_BeginPath dev %p\n",dev);
343c2c66affSColin Finck     DPRINT("nulldrv_BeginPath pd %p\n",physdev);
344c2c66affSColin Finck     return TRUE;
345c2c66affSColin Finck }
346c2c66affSColin Finck 
nulldrv_EndPath(PHYSDEV dev)347c2c66affSColin Finck BOOL nulldrv_EndPath( PHYSDEV dev )
348c2c66affSColin Finck {
349c2c66affSColin Finck     DPRINT("nulldrv_EndPath dev %p\n",dev);
350c2c66affSColin Finck     SetLastError( ERROR_CAN_NOT_COMPLETE );
351c2c66affSColin Finck     return FALSE;
352c2c66affSColin Finck }
353c2c66affSColin Finck 
nulldrv_AbortPath(PHYSDEV dev)354c2c66affSColin Finck BOOL nulldrv_AbortPath( PHYSDEV dev )
355c2c66affSColin Finck {
356c2c66affSColin Finck     //DC *dc = get_nulldrv_dc( dev );
357c2c66affSColin Finck     DPRINT("nulldrv_AbortPath dev %p\n",dev);
358c2c66affSColin Finck     //if (dc->path) free_gdi_path( dc->path );
359c2c66affSColin Finck     //dc->path = NULL;
360c2c66affSColin Finck     return TRUE;
361c2c66affSColin Finck }
362c2c66affSColin Finck 
nulldrv_CloseFigure(PHYSDEV dev)363c2c66affSColin Finck BOOL nulldrv_CloseFigure( PHYSDEV dev )
364c2c66affSColin Finck {
365c2c66affSColin Finck     DPRINT("nulldrv_CloseFigure dev %p\n",dev);
366c2c66affSColin Finck     SetLastError( ERROR_CAN_NOT_COMPLETE );
367c2c66affSColin Finck     return FALSE;
368c2c66affSColin Finck }
369c2c66affSColin Finck 
nulldrv_SelectClipPath(PHYSDEV dev,INT mode)370c2c66affSColin Finck BOOL nulldrv_SelectClipPath( PHYSDEV dev, INT mode )
371c2c66affSColin Finck {
372c2c66affSColin Finck     BOOL ret = FALSE;
373c2c66affSColin Finck     HRGN hrgn = PathToRegion( dev->hdc );
374c2c66affSColin Finck     DPRINT("nulldrv_SelectClipPath dev %p\n",dev);
375c2c66affSColin Finck     if (hrgn)
376c2c66affSColin Finck     {
377c2c66affSColin Finck         ret = ExtSelectClipRgn( dev->hdc, hrgn, mode ) != ERROR;
378c2c66affSColin Finck         DeleteObject( hrgn );
379c2c66affSColin Finck     }
380c2c66affSColin Finck     return ret;
381c2c66affSColin Finck //    return TRUE;
382c2c66affSColin Finck }
383c2c66affSColin Finck 
nulldrv_FillPath(PHYSDEV dev)384c2c66affSColin Finck BOOL nulldrv_FillPath( PHYSDEV dev )
385c2c66affSColin Finck {
386c2c66affSColin Finck     DPRINT("nulldrv_FillPath dev %p\n",dev);
387c2c66affSColin Finck     //if (GetPath( dev->hdc, NULL, NULL, 0 ) == -1) return FALSE;
388c2c66affSColin Finck     //AbortPath( dev->hdc );
389c2c66affSColin Finck     return TRUE;
390c2c66affSColin Finck }
391c2c66affSColin Finck 
nulldrv_StrokeAndFillPath(PHYSDEV dev)392c2c66affSColin Finck BOOL nulldrv_StrokeAndFillPath( PHYSDEV dev )
393c2c66affSColin Finck {
394c2c66affSColin Finck     DPRINT("nulldrv_StrokeAndFillPath dev %p\n",dev);
395c2c66affSColin Finck     //if (GetPath( dev->hdc, NULL, NULL, 0 ) == -1) return FALSE;
396c2c66affSColin Finck     //AbortPath( dev->hdc );
397c2c66affSColin Finck     return TRUE;
398c2c66affSColin Finck }
399c2c66affSColin Finck 
nulldrv_StrokePath(PHYSDEV dev)400c2c66affSColin Finck BOOL nulldrv_StrokePath( PHYSDEV dev )
401c2c66affSColin Finck {
402c2c66affSColin Finck     DPRINT("nulldrv_StrokePath dev %p\n",dev);
403c2c66affSColin Finck     //if (GetPath( dev->hdc, NULL, NULL, 0 ) == -1) return FALSE;
404c2c66affSColin Finck     //AbortPath( dev->hdc );
405c2c66affSColin Finck     return TRUE;
406c2c66affSColin Finck }
407c2c66affSColin Finck 
nulldrv_FlattenPath(PHYSDEV dev)408c2c66affSColin Finck BOOL nulldrv_FlattenPath( PHYSDEV dev )
409c2c66affSColin Finck {
410c2c66affSColin Finck /*    DC *dc = get_nulldrv_dc( dev );
411c2c66affSColin Finck     struct gdi_path *path; */
412c2c66affSColin Finck     DPRINT("nulldrv_FlattenPath dev %p\n",dev);
413c2c66affSColin Finck /*    if (!dc->path)
414c2c66affSColin Finck     {
415c2c66affSColin Finck         SetLastError( ERROR_CAN_NOT_COMPLETE );
416c2c66affSColin Finck         return FALSE;
417c2c66affSColin Finck     }
418c2c66affSColin Finck     if (!(path = PATH_FlattenPath( dc->path ))) return FALSE;
419c2c66affSColin Finck     free_gdi_path( dc->path );
420c2c66affSColin Finck     dc->path = path;*/
421c2c66affSColin Finck     return TRUE;
422c2c66affSColin Finck }
423c2c66affSColin Finck 
nulldrv_WidenPath(PHYSDEV dev)424c2c66affSColin Finck BOOL nulldrv_WidenPath( PHYSDEV dev )
425c2c66affSColin Finck {
426c2c66affSColin Finck /*    DC *dc = get_nulldrv_dc( dev );
427c2c66affSColin Finck     struct gdi_path *path;*/
428c2c66affSColin Finck     DPRINT("nulldrv_WidenPath dev %p\n",dev);
429c2c66affSColin Finck /*    if (!dc->path)
430c2c66affSColin Finck     {
431c2c66affSColin Finck         SetLastError( ERROR_CAN_NOT_COMPLETE );
432c2c66affSColin Finck         return FALSE;
433c2c66affSColin Finck     }
434c2c66affSColin Finck     if (!(path = PATH_WidenPath( dc ))) return FALSE;
435c2c66affSColin Finck     free_gdi_path( dc->path );
436c2c66affSColin Finck     dc->path = path;*/
437c2c66affSColin Finck     return TRUE;
438c2c66affSColin Finck }
439c2c66affSColin Finck 
440c2c66affSColin Finck const struct gdi_dc_funcs path_driver =
441c2c66affSColin Finck {
442c2c66affSColin Finck     NULL,                               /* pAbortDoc */
443c2c66affSColin Finck     pathdrv_AbortPath,                  /* pAbortPath */
444c2c66affSColin Finck     NULL,                               /* pAlphaBlend */
445c2c66affSColin Finck     pathdrv_AngleArc,                   /* pAngleArc */
446c2c66affSColin Finck     pathdrv_Arc,                        /* pArc */
447c2c66affSColin Finck     pathdrv_ArcTo,                      /* pArcTo */
448c2c66affSColin Finck     pathdrv_BeginPath,                  /* pBeginPath */
449c2c66affSColin Finck     NULL,                               /* pBlendImage */
450c2c66affSColin Finck     pathdrv_Chord,                      /* pChord */
451c2c66affSColin Finck     pathdrv_CloseFigure,                /* pCloseFigure */
452c2c66affSColin Finck     NULL,                               /* pCreateCompatibleDC */
453c2c66affSColin Finck     pathdrv_CreateDC,                   /* pCreateDC */
454c2c66affSColin Finck     pathdrv_DeleteDC,                   /* pDeleteDC */
455c2c66affSColin Finck     NULL,                               /* pDeleteObject */
456c2c66affSColin Finck     NULL,                               /* pDeviceCapabilities */
457c2c66affSColin Finck     pathdrv_Ellipse,                    /* pEllipse */
458c2c66affSColin Finck     NULL,                               /* pEndDoc */
459c2c66affSColin Finck     NULL,                               /* pEndPage */
460c2c66affSColin Finck     pathdrv_EndPath,                    /* pEndPath */
461c2c66affSColin Finck     NULL,                               /* pEnumFonts */
462c2c66affSColin Finck     NULL,                               /* pEnumICMProfiles */
463c2c66affSColin Finck     NULL,                               /* pExcludeClipRect */
464c2c66affSColin Finck     NULL,                               /* pExtDeviceMode */
465c2c66affSColin Finck     NULL,                               /* pExtEscape */
466c2c66affSColin Finck     NULL,                               /* pExtFloodFill */
467c2c66affSColin Finck     NULL,                               /* pExtSelectClipRgn */
468c2c66affSColin Finck     pathdrv_ExtTextOut,                 /* pExtTextOut */
469c2c66affSColin Finck     NULL,                               /* pFillPath */
470c2c66affSColin Finck     NULL,                               /* pFillRgn */
471c2c66affSColin Finck     NULL,                               /* pFlattenPath */
472c2c66affSColin Finck     NULL,                               /* pFontIsLinked */
473c2c66affSColin Finck     NULL,                               /* pFrameRgn */
474c2c66affSColin Finck     NULL,                               /* pGdiComment */
475c2c66affSColin Finck     NULL,                               /* pGetBoundsRect */
476c2c66affSColin Finck     NULL,                               /* pGetCharABCWidths */
477c2c66affSColin Finck     NULL,                               /* pGetCharABCWidthsI */
478c2c66affSColin Finck     NULL,                               /* pGetCharWidth */
479*333b8f19Sjimtabor     NULL,                               /* pGetCharWidthInfo */
480c2c66affSColin Finck     NULL,                               /* pGetDeviceCaps */
481c2c66affSColin Finck     NULL,                               /* pGetDeviceGammaRamp */
482c2c66affSColin Finck     NULL,                               /* pGetFontData */
483c2c66affSColin Finck     NULL,                               /* pGetFontRealizationInfo */
484c2c66affSColin Finck     NULL,                               /* pGetFontUnicodeRanges */
485c2c66affSColin Finck     NULL,                               /* pGetGlyphIndices */
486c2c66affSColin Finck     NULL,                               /* pGetGlyphOutline */
487c2c66affSColin Finck     NULL,                               /* pGetICMProfile */
488c2c66affSColin Finck     NULL,                               /* pGetImage */
489c2c66affSColin Finck     NULL,                               /* pGetKerningPairs */
490c2c66affSColin Finck     NULL,                               /* pGetNearestColor */
491c2c66affSColin Finck     NULL,                               /* pGetOutlineTextMetrics */
492c2c66affSColin Finck     NULL,                               /* pGetPixel */
493c2c66affSColin Finck     NULL,                               /* pGetSystemPaletteEntries */
494c2c66affSColin Finck     NULL,                               /* pGetTextCharsetInfo */
495c2c66affSColin Finck     NULL,                               /* pGetTextExtentExPoint */
496c2c66affSColin Finck     NULL,                               /* pGetTextExtentExPointI */
497c2c66affSColin Finck     NULL,                               /* pGetTextFace */
498c2c66affSColin Finck     NULL,                               /* pGetTextMetrics */
499c2c66affSColin Finck     NULL,                               /* pGradientFill */
500c2c66affSColin Finck     NULL,                               /* pIntersectClipRect */
501c2c66affSColin Finck     NULL,                               /* pInvertRgn */
502c2c66affSColin Finck     pathdrv_LineTo,                     /* pLineTo */
503c2c66affSColin Finck     NULL,                               /* pModifyWorldTransform */
504c2c66affSColin Finck     pathdrv_MoveTo,                     /* pMoveTo */
505c2c66affSColin Finck     NULL,                               /* pOffsetClipRgn */
506c2c66affSColin Finck     NULL,                               /* pOffsetViewportOrg */
507c2c66affSColin Finck     NULL,                               /* pOffsetWindowOrg */
508c2c66affSColin Finck     NULL,                               /* pPaintRgn */
509c2c66affSColin Finck     NULL,                               /* pPatBlt */
510c2c66affSColin Finck     pathdrv_Pie,                        /* pPie */
511c2c66affSColin Finck     pathdrv_PolyBezier,                 /* pPolyBezier */
512c2c66affSColin Finck     pathdrv_PolyBezierTo,               /* pPolyBezierTo */
513c2c66affSColin Finck     pathdrv_PolyDraw,                   /* pPolyDraw */
514c2c66affSColin Finck     pathdrv_PolyPolygon,                /* pPolyPolygon */
515c2c66affSColin Finck     pathdrv_PolyPolyline,               /* pPolyPolyline */
516c2c66affSColin Finck     pathdrv_Polygon,                    /* pPolygon */
517c2c66affSColin Finck     pathdrv_Polyline,                   /* pPolyline */
518c2c66affSColin Finck     pathdrv_PolylineTo,                 /* pPolylineTo */
519c2c66affSColin Finck     NULL,                               /* pPutImage */
520c2c66affSColin Finck     NULL,                               /* pRealizeDefaultPalette */
521c2c66affSColin Finck     NULL,                               /* pRealizePalette */
522c2c66affSColin Finck     pathdrv_Rectangle,                  /* pRectangle */
523c2c66affSColin Finck     NULL,                               /* pResetDC */
524c2c66affSColin Finck     NULL,                               /* pRestoreDC */
525c2c66affSColin Finck     pathdrv_RoundRect,                  /* pRoundRect */
526c2c66affSColin Finck     NULL,                               /* pSaveDC */
527c2c66affSColin Finck     NULL,                               /* pScaleViewportExt */
528c2c66affSColin Finck     NULL,                               /* pScaleWindowExt */
529c2c66affSColin Finck     NULL,                               /* pSelectBitmap */
530c2c66affSColin Finck     NULL,                               /* pSelectBrush */
531c2c66affSColin Finck     NULL,                               /* pSelectClipPath */
532c2c66affSColin Finck     NULL,                               /* pSelectFont */
533c2c66affSColin Finck     NULL,                               /* pSelectPalette */
534c2c66affSColin Finck     NULL,                               /* pSelectPen */
535c2c66affSColin Finck     NULL,                               /* pSetArcDirection */
536c2c66affSColin Finck     NULL,                               /* pSetBkColor */
537c2c66affSColin Finck     NULL,                               /* pSetBkMode */
538c2c66affSColin Finck     NULL,                               /* pSetDCBrushColor */
539c2c66affSColin Finck     NULL,                               /* pSetDCPenColor */
540c2c66affSColin Finck     NULL,                               /* pSetDIBColorTable */
541c2c66affSColin Finck     NULL,                               /* pSetDIBitsToDevice */
542c2c66affSColin Finck     NULL,                               /* pSetDeviceClipping */
543c2c66affSColin Finck     NULL,                               /* pSetDeviceGammaRamp */
544c2c66affSColin Finck     NULL,                               /* pSetLayout */
545c2c66affSColin Finck     NULL,                               /* pSetMapMode */
546c2c66affSColin Finck     NULL,                               /* pSetMapperFlags */
547c2c66affSColin Finck     NULL,                               /* pSetPixel */
548c2c66affSColin Finck     NULL,                               /* pSetPolyFillMode */
549c2c66affSColin Finck     NULL,                               /* pSetROP2 */
550c2c66affSColin Finck     NULL,                               /* pSetRelAbs */
551c2c66affSColin Finck     NULL,                               /* pSetStretchBltMode */
552c2c66affSColin Finck     NULL,                               /* pSetTextAlign */
553c2c66affSColin Finck     NULL,                               /* pSetTextCharacterExtra */
554c2c66affSColin Finck     NULL,                               /* pSetTextColor */
555c2c66affSColin Finck     NULL,                               /* pSetTextJustification */
556c2c66affSColin Finck     NULL,                               /* pSetViewportExt */
557c2c66affSColin Finck     NULL,                               /* pSetViewportOrg */
558c2c66affSColin Finck     NULL,                               /* pSetWindowExt */
559c2c66affSColin Finck     NULL,                               /* pSetWindowOrg */
560c2c66affSColin Finck     NULL,                               /* pSetWorldTransform */
561c2c66affSColin Finck     NULL,                               /* pStartDoc */
562c2c66affSColin Finck     NULL,                               /* pStartPage */
563c2c66affSColin Finck     NULL,                               /* pStretchBlt */
564c2c66affSColin Finck     NULL,                               /* pStretchDIBits */
565c2c66affSColin Finck     NULL,                               /* pStrokeAndFillPath */
566c2c66affSColin Finck     NULL,                               /* pStrokePath */
567c2c66affSColin Finck     NULL,                               /* pUnrealizePalette */
568c2c66affSColin Finck     NULL,                               /* pWidenPath */
569c2c66affSColin Finck     NULL,                               /* wine_get_wgl_driver */
570c2c66affSColin Finck     GDI_PRIORITY_PATH_DRV               /* priority */
571c2c66affSColin Finck };
572