2 * Copyright (C) 2003 Robert Shearman
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 #pragma makedep typelib
24 uuid(00020430-0000-0000-C000
-000000000046),
26 helpstring("OLE Automation")
30 /* typedefs aren't stored in the type library.
31 These type names are known by the type compiler so it
32 doesn't really matter what we define them as. */
34 typedef short VARIANT_BOOL;
36 typedef double CURRENCY
;
37 typedef unsigned long HRESULT;
38 typedef void *VARIANT;
39 typedef unsigned long SCODE
;
45 unsigned char Data4
[ 8 ];
48 typedef struct DISPPARAMS
{
50 long *rgdispidNamedArgs
;
52 unsigned int cNamedArgs
;
55 typedef struct EXCEPINFO
{
57 unsigned short wReserved
;
61 unsigned long dwHelpContext
;
63 void *pfnDeferredFillIn
;
69 uuid(00000000-0000-0000-C000
-000000000046),
75 HRESULT QueryInterface
(
80 unsigned long AddRef
();
83 unsigned long Release
();
88 uuid(00020400-0000-0000-C000
-000000000046),
91 interface IDispatch
: IUnknown
94 HRESULT GetTypeInfoCount
(
95 [out] unsigned int *pctinfo
);
99 [in] unsigned int itinfo
,
100 [in] unsigned long lcid,
101 [out] void **pptinfo
);
104 HRESULT GetIDsOfNames
(
106 [in] char **rgszNames
,
107 [in] unsigned int cNames
,
108 [in] unsigned long lcid,
109 [out] long *rgdispid
);
113 [in] long dispidMember
,
115 [in] unsigned long lcid,
116 [in] unsigned short wFlags
,
117 [in] DISPPARAMS
*pdispparams
,
118 [out] VARIANT *pvarResult
,
119 [out] EXCEPINFO
*pexcepinfo
,
120 [out] unsigned int *puArgErr
);
126 uuid(00020404-0000-0000-C000
-000000000046),
129 interface IEnumVARIANT
: IUnknown
132 [in] unsigned long celt
,
134 [out] unsigned long *pceltFetched
);
137 [in] unsigned long celt
);
142 [out] IEnumVARIANT
**ppenum
);
145 typedef [uuid(66504301-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
146 unsigned long OLE_COLOR
;
148 typedef [uuid(66504302-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
149 long OLE_XPOS_PIXELS
;
151 typedef [uuid(66504303-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
152 long OLE_YPOS_PIXELS
;
154 typedef [uuid(66504304-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
155 long OLE_XSIZE_PIXELS
;
157 typedef [uuid(66504305-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
158 long OLE_YSIZE_PIXELS
;
160 typedef [uuid(66504306-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
161 long OLE_XPOS_HIMETRIC
;
163 typedef [uuid(66504307-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
164 long OLE_YPOS_HIMETRIC
;
166 typedef [uuid(66504308-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
167 long OLE_XSIZE_HIMETRIC
;
169 typedef [uuid(66504309-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
170 long OLE_YSIZE_HIMETRIC
;
172 typedef [uuid(BF030640
-9069-101B
-AE2D
-08002B2EC713
), public]
173 float OLE_XPOS_CONTAINER
;
175 typedef [uuid(BF030641
-9069-101B
-AE2D
-08002B2EC713
), public]
176 float OLE_YPOS_CONTAINER
;
178 typedef [uuid(BF030642
-9069-101B
-AE2D
-08002B2EC713
), public]
179 float OLE_XSIZE_CONTAINER
;
181 typedef [uuid(BF030643
-9069-101B
-AE2D
-08002B2EC713
), public]
182 float OLE_YSIZE_CONTAINER
;
184 typedef [uuid(66504313-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
187 typedef [uuid(6650430B
-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
188 VARIANT_BOOL OLE_OPTEXCLUSIVE
;
190 typedef [uuid(BF030644
-9069-101B
-AE2D
-08002B2EC713
), public]
191 VARIANT_BOOL OLE_CANCELBOOL
;
193 typedef [uuid(BF030645
-9069-101B
-AE2D
-08002B2EC713
), public]
194 VARIANT_BOOL OLE_ENABLEDEFAULTBOOL
;
197 uuid(6650430A
-BE0F
-101A
-8BBB
-00AA00300CAB
)
205 typedef [uuid(6650430D
-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
208 typedef [uuid(6650430E
-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
211 typedef [uuid(6650430F
-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
212 VARIANT_BOOL FONTBOLD
;
214 typedef [uuid(66504310-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
215 VARIANT_BOOL FONTITALIC
;
217 typedef [uuid(66504311-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
218 VARIANT_BOOL FONTUNDERSCORE
;
220 typedef [uuid(66504312-BE0F
-101A
-8BBB
-00AA00300CAB
), public]
221 VARIANT_BOOL FONTSTRIKETHROUGH
;
226 uuid(BEF6E002
-A874
-101A
-8BBA
-00AA00300CAB
),
227 helpstring("Font Object"),
230 interface IFont
: IUnknown
{
231 [propget] HRESULT Name
([out, retval] BSTR *pname
);
232 [propput] HRESULT Name
([in] BSTR pname
);
234 [propget] HRESULT Size
([out, retval] CURRENCY
*psize
);
235 [propput] HRESULT Size
([in] CURRENCY psize
);
237 [propget] HRESULT Bold
([out, retval] VARIANT_BOOL *pbold
);
238 [propput] HRESULT Bold
([in] VARIANT_BOOL pbold
);
240 [propget] HRESULT Italic
([out, retval] VARIANT_BOOL *pitalic
);
241 [propput] HRESULT Italic
([in] VARIANT_BOOL pitalic
);
243 [propget] HRESULT Underline
([out, retval] VARIANT_BOOL *punderline
);
244 [propput] HRESULT Underline
([in] VARIANT_BOOL punderline
);
246 [propget] HRESULT Strikethrough
([out, retval] VARIANT_BOOL *pstrikethrough
);
247 [propput] HRESULT Strikethrough
([in] VARIANT_BOOL pstrikethrough
);
249 [propget] HRESULT Weight
([out, retval] short *pweight
);
250 [propput] HRESULT Weight
([in] short pweight
);
252 [propget] HRESULT Charset
([out, retval] short *pcharset
);
253 [propput] HRESULT Charset
([in] short pcharset
);
255 [propget] HRESULT hFont
([out, retval] OLE_HANDLE
*phfont
);
257 HRESULT Clone
([out] IFont
**ppfont
);
259 HRESULT IsEqual
([in] IFont
*pfontOther
);
261 HRESULT SetRatio
([in] long cyLogical
, [in] long cyHimetric
);
263 HRESULT AddRefHfont
([in] OLE_HANDLE hFont
);
265 HRESULT ReleaseHfont
([in] OLE_HANDLE hFont
);
271 uuid(BEF6E003
-A874
-101A
-8BBA
-00AA00300CAB
)
276 [id(0x2)] CURRENCY Size
;
277 [id(0x3)] VARIANT_BOOL Bold
;
278 [id(0x4)] VARIANT_BOOL Italic
;
279 [id(0x5)] VARIANT_BOOL Underline
;
280 [id(0x6)] VARIANT_BOOL Strikethrough
;
281 [id(0x7)] short Weight
;
282 [id(0x8)] short Charset
;
286 typedef [public] Font IFontDisp
;
289 uuid(0BE35203
-8F91
-11CE
-9DE3
-00AA004BB851
)
292 [default] dispinterface Font
;
293 /* FIXME: We can't reference dispinterface FontEvents here because we need it to
294 appear at the end of the typelib. */
295 /* [default, source] dispinterface FontEvents;*/
301 uuid(7BF80980
-BF32
-101A
-8BBB
-00AA00300CAB
),
302 helpstring("Picture Object"),
305 interface IPicture
: IUnknown
{
306 [propget] HRESULT Handle([out, retval] OLE_HANDLE
*phandle
);
308 [propget] HRESULT hPal
([out, retval] OLE_HANDLE
*phpal
);
310 [propget] HRESULT Type
([out, retval] short *ptype
);
312 [propget] HRESULT Width
([out, retval] OLE_XSIZE_HIMETRIC
*pwidth
);
314 [propget] HRESULT Height
([out, retval] OLE_YSIZE_HIMETRIC
*pheight
);
316 HRESULT Render
([in] int hdc
,
321 [in] OLE_XPOS_HIMETRIC xSrc
,
322 [in] OLE_YPOS_HIMETRIC ySrc
,
323 [in] OLE_XSIZE_HIMETRIC cxSrc
,
324 [in] OLE_YSIZE_HIMETRIC cySrc
,
325 [in] void *prcWBounds
);
327 [propput] HRESULT hPal
([in] OLE_HANDLE phpal
);
329 [propget] HRESULT CurDC
([out, retval] int *phdcOut
);
331 HRESULT SelectPicture
([in] int hdcIn
,
333 [out] OLE_HANDLE
*phbmpOut
);
335 [propget] HRESULT KeepOriginalFormat
([out, retval] VARIANT_BOOL *pfkeep
);
336 [propput] HRESULT KeepOriginalFormat
([in] VARIANT_BOOL pfkeep
);
338 HRESULT PictureChanged
();
340 HRESULT SaveAsFile
([in] void *pstm
,
341 [in] VARIANT_BOOL fSaveMemCopy
,
342 [out] long *pcbSize
);
344 [propget] HRESULT Attributes
([out, retval] long *pdwAttr
);
346 HRESULT SetHdc
([in] OLE_HANDLE hdc
);
350 uuid(7BF80981
-BF32
-101A
-8BBB
-00AA00300CAB
)
352 dispinterface Picture
{
354 [id(0x0), readonly] OLE_HANDLE
Handle;
355 [id(0x2)] OLE_HANDLE hPal
;
356 [id(0x3), readonly] short Type
;
357 [id(0x4), readonly] OLE_XSIZE_HIMETRIC Width
;
358 [id(0x5), readonly] OLE_YSIZE_HIMETRIC Height
;
360 [id(0x6)] void Render
(int hdc
,
365 OLE_XPOS_HIMETRIC xSrc
,
366 OLE_YPOS_HIMETRIC ySrc
,
367 OLE_XSIZE_HIMETRIC cxSrc
,
368 OLE_YSIZE_HIMETRIC cySrc
,
372 typedef [public] Picture IPictureDisp
;
375 uuid(0BE35204
-8F91
-11CE
-9DE3
-00AA004BB851
)
378 [default] dispinterface Picture
;
383 uuid(E6C8FA08
-BD9F
-11D0
-985E-00C04FC29993
)
385 enum LoadPictureConstants
{
393 dllname("oleaut32.dll"),
394 uuid(91209AC0
-60F6
-11CF
-9C5D
-00AA00C1489E
),
395 helpstring("Functions for Standard OLE Objects"),
400 entry("OleLoadPictureFileEx"),
401 helpstring("Loads a picture from a file"),
404 HRESULT LoadPicture
([in, optional] VARIANT filename
,
405 [in, optional, defaultvalue(0)] int widthDesired
,
406 [in, optional, defaultvalue(0)] int heightDesired
,
407 [in, optional, defaultvalue(Default)] enum LoadPictureConstants flags
,
408 [out, retval] IPictureDisp
**retval);
410 entry("OleSavePictureFile"),
411 helpstring("Saves a picture to a file"),
414 HRESULT SavePicture
([in] IPictureDisp
*Picture
,
420 uuid(4EF6100A
-AF88
-11D0
-9846-00C04FC29993
),
421 helpstring("Event Interface for the Font Object"),
424 dispinterface FontEvents
{
427 [id(0x9)] void FontChanged
([in] BSTR PropertyName
);
430 typedef [public] FontEvents IFontEventsDisp
;