2 * Metafile driver definitions
4 * Copyright 1996 Alexandre Julliard
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 #ifndef __WINE_METAFILEDRV_H
22 #define __WINE_METAFILEDRV_H
29 #include "gdi_private.h"
31 /* Metafile driver physical DC */
35 struct gdi_physdev dev
;
37 METAHEADER
*mh
; /* Pointer to metafile header */
38 UINT handles_size
, cur_handles
;
40 HANDLE hFile
; /* Handle for disk based MetaFile */
41 } METAFILEDRV_PDEVICE
;
43 #define HANDLE_LIST_INC 20
46 extern BOOL
MFDRV_MetaParam0(PHYSDEV dev
, short func
) DECLSPEC_HIDDEN
;
47 extern BOOL
MFDRV_MetaParam1(PHYSDEV dev
, short func
, short param1
) DECLSPEC_HIDDEN
;
48 extern BOOL
MFDRV_MetaParam2(PHYSDEV dev
, short func
, short param1
, short param2
) DECLSPEC_HIDDEN
;
49 extern BOOL
MFDRV_MetaParam4(PHYSDEV dev
, short func
, short param1
, short param2
,
50 short param3
, short param4
) DECLSPEC_HIDDEN
;
51 extern BOOL
MFDRV_MetaParam6(PHYSDEV dev
, short func
, short param1
, short param2
,
52 short param3
, short param4
, short param5
,
53 short param6
) DECLSPEC_HIDDEN
;
54 extern BOOL
MFDRV_MetaParam8(PHYSDEV dev
, short func
, short param1
, short param2
,
55 short param3
, short param4
, short param5
,
56 short param6
, short param7
, short param8
) DECLSPEC_HIDDEN
;
57 extern BOOL
MFDRV_WriteRecord(PHYSDEV dev
, METARECORD
*mr
, DWORD rlen
) DECLSPEC_HIDDEN
;
58 extern UINT
MFDRV_AddHandle( PHYSDEV dev
, HGDIOBJ obj
) DECLSPEC_HIDDEN
;
59 extern BOOL
MFDRV_RemoveHandle( PHYSDEV dev
, UINT index
) DECLSPEC_HIDDEN
;
60 extern INT16
MFDRV_CreateBrushIndirect( PHYSDEV dev
, HBRUSH hBrush
) DECLSPEC_HIDDEN
;
62 /* Metafile driver functions */
64 extern BOOL CDECL
MFDRV_AbortPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
65 extern BOOL CDECL
MFDRV_Arc( PHYSDEV dev
, INT left
, INT top
, INT right
, INT bottom
,
66 INT xstart
, INT ystart
, INT xend
, INT yend
) DECLSPEC_HIDDEN
;
67 extern BOOL CDECL
MFDRV_BeginPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
68 extern BOOL CDECL
MFDRV_Chord( PHYSDEV dev
, INT left
, INT top
, INT right
,
69 INT bottom
, INT xstart
, INT ystart
, INT xend
,
70 INT yend
) DECLSPEC_HIDDEN
;
71 extern BOOL CDECL
MFDRV_CloseFigure( PHYSDEV dev
) DECLSPEC_HIDDEN
;
72 extern BOOL CDECL
MFDRV_DeleteObject( PHYSDEV dev
, HGDIOBJ obj
) DECLSPEC_HIDDEN
;
73 extern BOOL CDECL
MFDRV_Ellipse( PHYSDEV dev
, INT left
, INT top
,
74 INT right
, INT bottom
) DECLSPEC_HIDDEN
;
75 extern BOOL CDECL
MFDRV_EndPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
76 extern INT CDECL
MFDRV_ExcludeClipRect( PHYSDEV dev
, INT left
, INT top
, INT right
,
77 INT bottom
) DECLSPEC_HIDDEN
;
78 extern INT CDECL
MFDRV_ExtEscape( PHYSDEV dev
, INT nEscape
, INT cbInput
, LPCVOID in_data
,
79 INT cbOutput
, LPVOID out_data
) DECLSPEC_HIDDEN
;
80 extern BOOL CDECL
MFDRV_ExtFloodFill( PHYSDEV dev
, INT x
, INT y
, COLORREF color
, UINT fillType
) DECLSPEC_HIDDEN
;
81 extern INT CDECL
MFDRV_ExtSelectClipRgn( PHYSDEV dev
, HRGN hrgn
, INT mode
) DECLSPEC_HIDDEN
;
82 extern BOOL CDECL
MFDRV_ExtTextOut( PHYSDEV dev
, INT x
, INT y
,
83 UINT flags
, const RECT
*lprect
, LPCWSTR str
,
84 UINT count
, const INT
*lpDx
) DECLSPEC_HIDDEN
;
85 extern BOOL CDECL
MFDRV_FillPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
86 extern BOOL CDECL
MFDRV_FillRgn( PHYSDEV dev
, HRGN hrgn
, HBRUSH hbrush
) DECLSPEC_HIDDEN
;
87 extern BOOL CDECL
MFDRV_FlattenPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
88 extern BOOL CDECL
MFDRV_FrameRgn( PHYSDEV dev
, HRGN hrgn
, HBRUSH hbrush
, INT x
, INT y
) DECLSPEC_HIDDEN
;
89 extern INT CDECL
MFDRV_GetDeviceCaps( PHYSDEV dev
, INT cap
) DECLSPEC_HIDDEN
;
90 extern INT CDECL
MFDRV_IntersectClipRect( PHYSDEV dev
, INT left
, INT top
, INT right
, INT bottom
) DECLSPEC_HIDDEN
;
91 extern BOOL CDECL
MFDRV_InvertRgn( PHYSDEV dev
, HRGN hrgn
) DECLSPEC_HIDDEN
;
92 extern BOOL CDECL
MFDRV_LineTo( PHYSDEV dev
, INT x
, INT y
) DECLSPEC_HIDDEN
;
93 extern BOOL CDECL
MFDRV_MoveTo( PHYSDEV dev
, INT x
, INT y
) DECLSPEC_HIDDEN
;
94 extern INT CDECL
MFDRV_OffsetClipRgn( PHYSDEV dev
, INT x
, INT y
) DECLSPEC_HIDDEN
;
95 extern BOOL CDECL
MFDRV_OffsetViewportOrgEx( PHYSDEV dev
, INT x
, INT y
, POINT
*pt
) DECLSPEC_HIDDEN
;
96 extern BOOL CDECL
MFDRV_OffsetWindowOrgEx( PHYSDEV dev
, INT x
, INT y
, POINT
*pt
) DECLSPEC_HIDDEN
;
97 extern BOOL CDECL
MFDRV_PaintRgn( PHYSDEV dev
, HRGN hrgn
) DECLSPEC_HIDDEN
;
98 extern BOOL CDECL
MFDRV_PatBlt( PHYSDEV dev
, INT left
, INT top
, INT width
, INT height
,
99 DWORD rop
) DECLSPEC_HIDDEN
;
100 extern BOOL CDECL
MFDRV_Pie( PHYSDEV dev
, INT left
, INT top
, INT right
,
101 INT bottom
, INT xstart
, INT ystart
, INT xend
,
102 INT yend
) DECLSPEC_HIDDEN
;
103 extern BOOL CDECL
MFDRV_PolyBezier( PHYSDEV dev
, const POINT
* pt
, DWORD count
) DECLSPEC_HIDDEN
;
104 extern BOOL CDECL
MFDRV_PolyBezierTo( PHYSDEV dev
, const POINT
* pt
, DWORD count
) DECLSPEC_HIDDEN
;
105 extern BOOL CDECL
MFDRV_PolyPolygon( PHYSDEV dev
, const POINT
* pt
, const INT
* counts
,
106 UINT polygons
) DECLSPEC_HIDDEN
;
107 extern BOOL CDECL
MFDRV_Polygon( PHYSDEV dev
, const POINT
* pt
, INT count
) DECLSPEC_HIDDEN
;
108 extern BOOL CDECL
MFDRV_Polyline( PHYSDEV dev
, const POINT
* pt
,INT count
) DECLSPEC_HIDDEN
;
109 extern BOOL CDECL
MFDRV_Rectangle( PHYSDEV dev
, INT left
, INT top
,
110 INT right
, INT bottom
) DECLSPEC_HIDDEN
;
111 extern BOOL CDECL
MFDRV_RestoreDC( PHYSDEV dev
, INT level
) DECLSPEC_HIDDEN
;
112 extern BOOL CDECL
MFDRV_RoundRect( PHYSDEV dev
, INT left
, INT top
,
113 INT right
, INT bottom
, INT ell_width
,
114 INT ell_height
) DECLSPEC_HIDDEN
;
115 extern INT CDECL
MFDRV_SaveDC( PHYSDEV dev
) DECLSPEC_HIDDEN
;
116 extern BOOL CDECL
MFDRV_ScaleViewportExtEx( PHYSDEV dev
, INT xNum
, INT xDenom
, INT yNum
,
117 INT yDenom
, SIZE
*size
) DECLSPEC_HIDDEN
;
118 extern BOOL CDECL
MFDRV_ScaleWindowExtEx( PHYSDEV dev
, INT xNum
, INT xDenom
, INT yNum
,
119 INT yDenom
, SIZE
*size
) DECLSPEC_HIDDEN
;
120 extern HBITMAP CDECL
MFDRV_SelectBitmap( PHYSDEV dev
, HBITMAP handle
) DECLSPEC_HIDDEN
;
121 extern HBRUSH CDECL
MFDRV_SelectBrush( PHYSDEV dev
, HBRUSH handle
) DECLSPEC_HIDDEN
;
122 extern BOOL CDECL
MFDRV_SelectClipPath( PHYSDEV dev
, INT iMode
) DECLSPEC_HIDDEN
;
123 extern HFONT CDECL
MFDRV_SelectFont( PHYSDEV dev
, HFONT handle
, HANDLE gdiFont
) DECLSPEC_HIDDEN
;
124 extern HPEN CDECL
MFDRV_SelectPen( PHYSDEV dev
, HPEN handle
) DECLSPEC_HIDDEN
;
125 extern HPALETTE CDECL
MFDRV_SelectPalette( PHYSDEV dev
, HPALETTE hPalette
, BOOL bForceBackground
) DECLSPEC_HIDDEN
;
126 extern UINT CDECL
MFDRV_RealizePalette(PHYSDEV dev
, HPALETTE hPalette
, BOOL primary
) DECLSPEC_HIDDEN
;
127 extern COLORREF CDECL
MFDRV_SetBkColor( PHYSDEV dev
, COLORREF color
) DECLSPEC_HIDDEN
;
128 extern INT CDECL
MFDRV_SetBkMode( PHYSDEV dev
, INT mode
) DECLSPEC_HIDDEN
;
129 extern COLORREF CDECL
MFDRV_SetDCBrushColor( PHYSDEV dev
, COLORREF color
) DECLSPEC_HIDDEN
;
130 extern COLORREF CDECL
MFDRV_SetDCPenColor( PHYSDEV dev
, COLORREF color
) DECLSPEC_HIDDEN
;
131 extern INT CDECL
MFDRV_SetMapMode( PHYSDEV dev
, INT mode
) DECLSPEC_HIDDEN
;
132 extern DWORD CDECL
MFDRV_SetMapperFlags( PHYSDEV dev
, DWORD flags
) DECLSPEC_HIDDEN
;
133 extern COLORREF CDECL
MFDRV_SetPixel( PHYSDEV dev
, INT x
, INT y
, COLORREF color
) DECLSPEC_HIDDEN
;
134 extern INT CDECL
MFDRV_SetPolyFillMode( PHYSDEV dev
, INT mode
) DECLSPEC_HIDDEN
;
135 extern INT CDECL
MFDRV_SetROP2( PHYSDEV dev
, INT rop
) DECLSPEC_HIDDEN
;
136 extern INT CDECL
MFDRV_SetRelAbs( PHYSDEV dev
, INT mode
) DECLSPEC_HIDDEN
;
137 extern INT CDECL
MFDRV_SetStretchBltMode( PHYSDEV dev
, INT mode
) DECLSPEC_HIDDEN
;
138 extern UINT CDECL
MFDRV_SetTextAlign( PHYSDEV dev
, UINT align
) DECLSPEC_HIDDEN
;
139 extern INT CDECL
MFDRV_SetTextCharacterExtra( PHYSDEV dev
, INT extra
) DECLSPEC_HIDDEN
;
140 extern COLORREF CDECL
MFDRV_SetTextColor( PHYSDEV dev
, COLORREF color
) DECLSPEC_HIDDEN
;
141 extern BOOL CDECL
MFDRV_SetTextJustification( PHYSDEV dev
, INT extra
, INT breaks
) DECLSPEC_HIDDEN
;
142 extern BOOL CDECL
MFDRV_SetViewportExtEx( PHYSDEV dev
, INT x
, INT y
, SIZE
*size
) DECLSPEC_HIDDEN
;
143 extern BOOL CDECL
MFDRV_SetViewportOrgEx( PHYSDEV dev
, INT x
, INT y
, POINT
*pt
) DECLSPEC_HIDDEN
;
144 extern BOOL CDECL
MFDRV_SetWindowExtEx( PHYSDEV dev
, INT x
, INT y
, SIZE
*size
) DECLSPEC_HIDDEN
;
145 extern BOOL CDECL
MFDRV_SetWindowOrgEx( PHYSDEV dev
, INT x
, INT y
, POINT
*pt
) DECLSPEC_HIDDEN
;
146 extern BOOL CDECL
MFDRV_StretchBlt( PHYSDEV devDst
, INT xDst
, INT yDst
, INT widthDst
,
147 INT heightDst
, PHYSDEV devSrc
, INT xSrc
, INT ySrc
,
148 INT widthSrc
, INT heightSrc
, DWORD rop
) DECLSPEC_HIDDEN
;
149 extern BOOL CDECL
MFDRV_PaintRgn( PHYSDEV dev
, HRGN hrgn
) DECLSPEC_HIDDEN
;
150 extern INT CDECL
MFDRV_SetDIBitsToDevice( PHYSDEV dev
, INT xDest
, INT yDest
, DWORD cx
,
151 DWORD cy
, INT xSrc
, INT ySrc
,
152 UINT startscan
, UINT lines
, LPCVOID bits
,
153 const BITMAPINFO
*info
, UINT coloruse
) DECLSPEC_HIDDEN
;
154 extern INT CDECL
MFDRV_StretchDIBits( PHYSDEV dev
, INT xDst
, INT yDst
, INT widthDst
,
155 INT heightDst
, INT xSrc
, INT ySrc
,
156 INT widthSrc
, INT heightSrc
, const void *bits
,
157 const BITMAPINFO
*info
, UINT wUsage
,
158 DWORD dwRop
) DECLSPEC_HIDDEN
;
159 extern BOOL CDECL
MFDRV_StrokeAndFillPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
160 extern BOOL CDECL
MFDRV_StrokePath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
161 extern BOOL CDECL
MFDRV_WidenPath( PHYSDEV dev
) DECLSPEC_HIDDEN
;
163 #endif /* __WINE_METAFILEDRV_H */