2 * Copyright (C) 1999 Paul Quinn
3 * Copyright (C) 2003 Alexandre Julliard
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
24 import "servprov.idl";
27 interface IOleDocumentView;
28 interface IEnumOleDocumentViews;
31 /*****************************************************************************
32 * IOleDocument interface
36 uuid(b722bcc5-4e68-101b-a2bc-00aa00404770),
37 pointer_default(unique)
39 interface IOleDocument : IUnknown
41 typedef [unique] IOleDocument *LPOLEDOCUMENT;
45 DOCMISC_CANCREATEMULTIPLEVIEWS = 1,
46 DOCMISC_SUPPORTCOMPLEXRECTANGLES = 2,
47 DOCMISC_CANTOPENEDIT = 4,
48 DOCMISC_NOFILESUPPORT = 8
52 [in, unique] IOleInPlaceSite *pIPSite,
53 [in, unique] IStream *pstm,
54 [in] DWORD dwReserved,
55 [out] IOleDocumentView **ppView);
57 HRESULT GetDocMiscStatus(
58 [out] DWORD *pdwStatus);
61 [out] IEnumOleDocumentViews **ppEnum,
62 [out] IOleDocumentView **ppView);
66 /*****************************************************************************
67 * IOleDocumentSite interface
71 uuid(b722bcc7-4e68-101b-a2bc-00aa00404770),
72 pointer_default(unique)
74 interface IOleDocumentSite : IUnknown
76 typedef [unique] IOleDocumentSite *LPOLEDOCUMENTSITE;
78 HRESULT ActivateMe( [in] IOleDocumentView *pViewToActivate );
82 /*****************************************************************************
83 * IOleDocumentView interface
87 uuid(b722bcc6-4e68-101b-a2bc-00aa00404770),
88 pointer_default(unique)
90 interface IOleDocumentView : IUnknown
92 typedef [unique] IOleDocumentView *LPOLEDOCUMENTVIEW;
94 HRESULT SetInPlaceSite( [in, unique] IOleInPlaceSite *pIPSite );
96 HRESULT GetInPlaceSite( [out] IOleInPlaceSite **ppIPSite );
98 HRESULT GetDocument( [out] IUnknown **ppunk );
100 HRESULT SetRect( [in] LPRECT prcView );
102 HRESULT GetRect( [out] LPRECT prcView );
104 HRESULT SetRectComplex(
105 [in, unique] LPRECT prcView,
106 [in, unique] LPRECT prcHScroll,
107 [in, unique] LPRECT prcVScroll,
108 [in, unique] LPRECT prcSizeBox);
110 HRESULT Show( [in] BOOL fShow );
112 HRESULT UIActivate( [in] BOOL fUIActivate );
116 HRESULT CloseView( [in] DWORD dwReserved );
118 HRESULT SaveViewState( [in] LPSTREAM pstm );
120 HRESULT ApplyViewState( [in] LPSTREAM pstm );
123 [in] IOleInPlaceSite *pIPSiteNew,
124 [out] IOleDocumentView **ppViewNew);
128 /*****************************************************************************
129 * IEnumOleDocumentViews interface
133 uuid(b722bcc8-4e68-101b-a2bc-00aa00404770),
134 pointer_default(unique)
136 interface IEnumOleDocumentViews : IUnknown
138 typedef [unique] IEnumOleDocumentViews *LPENUMOLEDOCUMENTVIEWS;
143 [out] IOleDocumentView **rgpView,
144 [out] ULONG *pcFetched);
149 [out, size_is(cViews), length_is(*pcFetched)] IOleDocumentView **rgpView,
150 [out] ULONG *pcFetched);
152 HRESULT Skip( [in] ULONG cViews );
156 HRESULT Clone( [out] IEnumOleDocumentViews **ppEnum );
160 /*****************************************************************************
161 * IOleCommandTarget interface
165 uuid(b722bccb-4e68-101b-a2bc-00aa00404770),
166 pointer_default(unique)
168 interface IOleCommandTarget : IUnknown
170 typedef [unique] IOleCommandTarget *LPOLECOMMANDTARGET;
174 OLECMDF_SUPPORTED = 0x1,
175 OLECMDF_ENABLED = 0x2,
176 OLECMDF_LATCHED = 0x4,
177 OLECMDF_NINCHED = 0x8,
178 OLECMDF_INVISIBLE = 0x10,
179 OLECMDF_DEFHIDEONCTXTMENU = 0x20
182 typedef struct _tagOLECMD
188 typedef struct _tagOLECMDTEXT
193 [size_is(cwBuf)] WCHAR rgwz[];
196 typedef enum OLECMDTEXTF
198 OLECMDTEXTF_NONE = 0,
199 OLECMDTEXTF_NAME = 1,
200 OLECMDTEXTF_STATUS = 2
203 typedef enum OLECMDEXECOPT
205 OLECMDEXECOPT_DODEFAULT = 0,
206 OLECMDEXECOPT_PROMPTUSER = 1,
207 OLECMDEXECOPT_DONTPROMPTUSER = 2,
208 OLECMDEXECOPT_SHOWHELP = 3
211 typedef enum OLECMDID
217 OLECMDID_SAVECOPYAS = 5,
219 OLECMDID_PRINTPREVIEW = 7,
220 OLECMDID_PAGESETUP = 8,
222 OLECMDID_PROPERTIES = 10,
226 OLECMDID_PASTESPECIAL = 14,
229 OLECMDID_SELECTALL = 17,
230 OLECMDID_CLEARSELECTION = 18,
232 OLECMDID_GETZOOMRANGE = 20,
233 OLECMDID_UPDATECOMMANDS = 21,
234 OLECMDID_REFRESH = 22,
236 OLECMDID_HIDETOOLBARS = 24,
237 OLECMDID_SETPROGRESSMAX = 25,
238 OLECMDID_SETPROGRESSPOS = 26,
239 OLECMDID_SETPROGRESSTEXT = 27,
240 OLECMDID_SETTITLE = 28,
241 OLECMDID_SETDOWNLOADSTATE = 29,
242 OLECMDID_STOPDOWNLOAD = 30,
243 OLECMDID_ONTOOLBARACTIVATED = 31,
245 OLECMDID_DELETE = 33,
246 OLECMDID_HTTPEQUIV = 34,
247 OLECMDID_HTTPEQUIV_DONE = 35,
248 OLECMDID_ENABLE_INTERACTION = 36,
249 OLECMDID_ONUNLOAD = 37,
250 OLECMDID_PROPERTYBAG2 = 38,
251 OLECMDID_PREREFRESH = 39,
252 /* iexplorer uses ... 44 */
253 OLECMDID_SHOWSCRIPTERROR = 40,
254 OLECMDID_SHOWMESSAGE = 41,
255 OLECMDID_SHOWFIND = 42,
256 OLECMDID_SHOWPAGESETUP = 43,
257 OLECMDID_SHOWPRINT = 44,
259 OLECMDID_ALLOWUILESSSAVEAS = 46,
260 OLECMDID_DONTDOWNLOADCSS = 47,
261 OLECMDID_UPDATEPAGESTATUS = 48,
262 OLECMDID_PRINT2 = 49,
263 OLECMDID_PRINTPREVIEW2 = 50,
264 OLECMDID_SETPRINTTEMPLATE = 51,
265 OLECMDID_GETPRINTTEMPLATE = 52
269 [in, unique] const GUID *pguidCmdGroup,
271 [in, out, size_is(cCmds)] OLECMD prgCmds[],
272 [in, out, unique] OLECMDTEXT *pCmdText);
275 [in, unique] const GUID *pguidCmdGroup,
277 [in] DWORD nCmdexecopt,
278 [in, unique] VARIANT *pvaIn,
279 [in, out, unique] VARIANT *pvaOut);
283 /*****************************************************************************
284 * IContinueCallback interface
288 uuid(b722bcca-4e68-101b-a2bc-00aa00404770),
289 pointer_default(unique)
291 interface IContinueCallback : IUnknown
293 typedef [unique] IContinueCallback *LPCONTINUECALLBACK;
297 HRESULT FContinuePrinting(
298 [in] LONG nCntPrinted,
300 [in, unique] WCHAR *pwszPrintStatus);
304 /*****************************************************************************
309 uuid(b722bcc9-4e68-101b-a2bc-00aa00404770),
310 pointer_default(unique)
312 interface IPrint : IUnknown
314 typedef [unique] IPrint *LPPRINT;
318 PRINTFLAG_MAYBOTHERUSER = 1,
319 PRINTFLAG_PROMPTUSER = 2,
320 PRINTFLAG_USERMAYCHANGEPRINTER = 4,
321 PRINTFLAG_RECOMPOSETODEVICE = 8,
322 PRINTFLAG_DONTACTUALLYPRINT = 16,
323 PRINTFLAG_FORCEPROPERTIES = 32,
324 PRINTFLAG_PRINTTOFILE = 64
327 typedef struct tagPAGERANGE
333 typedef struct tagPAGESET
339 [size_is(cPageRange)] PAGERANGE rgPages[];
342 HRESULT SetInitialPageNum(
343 [in] LONG nFirstPage);
346 [out] LONG *pnFirstPage,
347 [out] LONG *pcPages);
352 [in, out] DVTARGETDEVICE **pptd,
353 [in, out] PAGESET **ppPageSet,
354 [in, out, unique] STGMEDIUM *pstgmOptions,
355 [in] IContinueCallback *pcallback,
356 [in] LONG nFirstPage,
357 [out] LONG *pcPagesPrinted,
358 [out] LONG *pnLastPage);
363 [in, out] DVTARGETDEVICE **pptd,
364 [in, out] PAGESET **pppageset,
365 [in, out, unique] RemSTGMEDIUM *pstgmOptions,
366 [in] IContinueCallback *pcallback,
367 [in] LONG nFirstPage,
368 [out] LONG *pcPagesPrinted,
369 [out] LONG *pnLastPage);
373 cpp_quote("#define OLECMDERR_E_FIRST (OLE_E_LAST+1)")
374 cpp_quote("#define OLECMDERR_E_NOTSUPPORTED (OLECMDERR_E_FIRST)")
375 cpp_quote("#define OLECMDERR_E_DISABLED (OLECMDERR_E_FIRST+1)")
376 cpp_quote("#define OLECMDERR_E_NOHELP (OLECMDERR_E_FIRST+2)")
377 cpp_quote("#define OLECMDERR_E_CANCELED (OLECMDERR_E_FIRST+3)")
378 cpp_quote("#define OLECMDERR_E_UNKNOWNGROUP (OLECMDERR_E_FIRST+4)")
380 cpp_quote("#define MSOCMDERR_E_FIRST OLECMDERR_E_FIRST")
381 cpp_quote("#define MSOCMDERR_E_NOTSUPPORTED OLECMDERR_E_NOTSUPPORTED")
382 cpp_quote("#define MSOCMDERR_E_DISABLED OLECMDERR_E_DISABLED")
383 cpp_quote("#define MSOCMDERR_E_NOHELP OLECMDERR_E_NOHELP")
384 cpp_quote("#define MSOCMDERR_E_CANCELED OLECMDERR_E_CANCELED")
385 cpp_quote("#define MSOCMDERR_E_UNKNOWNGROUP OLECMDERR_E_UNKNOWNGROUP")
387 cpp_quote("#define LPMSODOCUMENT LPOLEDOCUMENT")
388 cpp_quote("#define LPMSODOCUMENTSITE LPOLEDOCUMENTSITE")
389 cpp_quote("#define LPMSOVIEW LPOLEDOCUMENTVIEW")
390 cpp_quote("#define LPENUMMSOVIEW LPENUMOLEDOCUMENTVIEWS")
391 cpp_quote("#define LPMSOCOMMANDTARGET LPOLECOMMANDTARGET")
392 cpp_quote("#define IID_IMsoDocument IID_IOleDocument")
393 cpp_quote("#define IID_IMsoDocumentSite IID_IOleDocumentSite")
394 cpp_quote("#define IID_IMsoView IID_IOleDocumentView")
395 cpp_quote("#define IID_IEnumMsoView IID_IEnumOleDocumentViews")
396 cpp_quote("#define IID_IMsoCommandTarget IID_IOleCommandTarget")