Implemented localeconv() with libc function.
[wine.git] / dlls / commdlg / cdlg.h
blobb1d61cb9e220c5d17971e8f7bfd4ad0262c776b6
1 /*
2 * Common Dialog Boxes interface (32 bit)
4 * Copyright 1998 Bertho A. Stultiens
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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 #ifndef _WINE_DLL_CDLG_H
22 #define _WINE_DLL_CDLG_H
24 #define COM_NO_WINDOWS_H
25 #include "dlgs.h"
26 #include "wine/windef16.h"
27 #include "wownt32.h"
29 /* Common dialogs implementation globals */
30 #define COMDLG32_Atom ((ATOM)0xa000) /* MS uses this one to identify props */
32 extern HINSTANCE COMDLG32_hInstance;
34 void COMDLG32_SetCommDlgExtendedError(DWORD err);
35 LPVOID COMDLG32_AllocMem(int size);
37 /* handle<-handle16 conversion */
38 #define HINSTANCE_32(h16) ((HINSTANCE)(ULONG_PTR)(h16))
40 /* Find/Replace local definitions */
42 #define FR_WINE_UNICODE 0x80000000
43 #define FR_WINE_REPLACE 0x40000000
45 typedef struct {
46 FINDREPLACEA fr; /* Internally used structure */
47 union {
48 FINDREPLACEA *fra; /* Reference to the user supplied structure */
49 FINDREPLACEW *frw;
50 } user_fr;
51 } COMDLG32_FR_Data;
53 #define PD32_PRINT_TITLE 7000
55 #define PD32_VALUE_UREADABLE 1104
56 #define PD32_INVALID_PAGE_RANGE 1105
57 #define PD32_FROM_NOT_ABOVE_TO 1106
58 #define PD32_MARGINS_OVERLAP 1107
59 #define PD32_NR_OF_COPIES_EMPTY 1108
60 #define PD32_TOO_LARGE_COPIES 1109
61 #define PD32_PRINT_ERROR 1110
62 #define PD32_NO_DEFAULT_PRINTER 1111
63 #define PD32_CANT_FIND_PRINTER 1112
64 #define PD32_OUT_OF_MEMORY 1113
65 #define PD32_GENERIC_ERROR 1114
66 #define PD32_DRIVER_UNKNOWN 1115
68 #define PD32_PRINTER_STATUS_READY 1536
69 #define PD32_PRINTER_STATUS_PAUSED 1537
70 #define PD32_PRINTER_STATUS_ERROR 1538
71 #define PD32_PRINTER_STATUS_PENDING_DELETION 1539
72 #define PD32_PRINTER_STATUS_PAPER_JAM 1540
73 #define PD32_PRINTER_STATUS_PAPER_OUT 1541
74 #define PD32_PRINTER_STATUS_MANUAL_FEED 1542
75 #define PD32_PRINTER_STATUS_PAPER_PROBLEM 1543
76 #define PD32_PRINTER_STATUS_OFFLINE 1544
77 #define PD32_PRINTER_STATUS_IO_ACTIVE 1545
78 #define PD32_PRINTER_STATUS_BUSY 1546
79 #define PD32_PRINTER_STATUS_PRINTING 1547
80 #define PD32_PRINTER_STATUS_OUTPUT_BIN_FULL 1548
81 #define PD32_PRINTER_STATUS_NOT_AVAILABLE 1549
82 #define PD32_PRINTER_STATUS_WAITING 1550
83 #define PD32_PRINTER_STATUS_PROCESSING 1551
84 #define PD32_PRINTER_STATUS_INITIALIZING 1552
85 #define PD32_PRINTER_STATUS_WARMING_UP 1553
86 #define PD32_PRINTER_STATUS_TONER_LOW 1554
87 #define PD32_PRINTER_STATUS_NO_TONER 1555
88 #define PD32_PRINTER_STATUS_PAGE_PUNT 1556
89 #define PD32_PRINTER_STATUS_USER_INTERVENTION 1557
90 #define PD32_PRINTER_STATUS_OUT_OF_MEMORY 1558
91 #define PD32_PRINTER_STATUS_DOOR_OPEN 1559
92 #define PD32_PRINTER_STATUS_SERVER_UNKNOWN 1560
93 #define PD32_PRINTER_STATUS_POWER_SAVE 1561
95 #define PD32_DEFAULT_PRINTER 1582
96 #define PD32_NR_OF_DOCUMENTS_IN_QUEUE 1583
97 #define PD32_PRINT_ALL_X_PAGES 1584
98 #define PD32_MARGINS_IN_INCHES 1585
99 #define PD32_MARGINS_IN_MILIMETERS 1586
100 #define PD32_MILIMETERS 1587
102 /* Charset names string IDs */
104 #define IDS_CHARSET_ANSI 200
105 #define IDS_CHARSET_SYMBOL 201
106 #define IDS_CHARSET_JIS 202
107 #define IDS_CHARSET_HANGUL 203
108 #define IDS_CHARSET_GB2312 204
109 #define IDS_CHARSET_BIG5 205
110 #define IDS_CHARSET_GREEK 206
111 #define IDS_CHARSET_TURKISH 207
112 #define IDS_CHARSET_HEBREW 208
113 #define IDS_CHARSET_ARABIC 209
114 #define IDS_CHARSET_BALTIC 210
115 #define IDS_CHARSET_VIETNAMESE 211
116 #define IDS_CHARSET_RUSSIAN 212
117 #define IDS_CHARSET_EE 213
118 #define IDS_CHARSET_THAI 214
119 #define IDS_CHARSET_JOHAB 215
120 #define IDS_CHARSET_MAC 216
121 #define IDS_CHARSET_OEM 217
122 #define IDS_CHARSET_VISCII 218
123 #define IDS_CHARSET_TCVN 219
124 #define IDS_CHARSET_KOI8 220
125 #define IDS_CHARSET_ISO3 221
126 #define IDS_CHARSET_ISO4 222
127 #define IDS_CHARSET_ISO10 223
128 #define IDS_CHARSET_CELTIC 224
130 /* Color names string IDs */
132 #define IDS_COLOR_BLACK 1040
133 #define IDS_COLOR_MAROON 1041
134 #define IDS_COLOR_GREEN 1042
135 #define IDS_COLOR_OLIVE 1043
136 #define IDS_COLOR_NAVY 1044
137 #define IDS_COLOR_PURPLE 1045
138 #define IDS_COLOR_TEAL 1046
139 #define IDS_COLOR_GRAY 1047
140 #define IDS_COLOR_SILVER 1048
141 #define IDS_COLOR_RED 1049
142 #define IDS_COLOR_LIME 1050
143 #define IDS_COLOR_YELLOW 1051
144 #define IDS_COLOR_BLUE 1052
145 #define IDS_COLOR_FUCHSIA 1053
146 #define IDS_COLOR_AQUA 1054
147 #define IDS_COLOR_WHITE 1055
149 #include "commctrl.h"
150 #include "shlobj.h"
151 #include "shellapi.h"
153 /* ITEMIDLIST */
155 extern LPITEMIDLIST (WINAPI *COMDLG32_PIDL_ILClone) (LPCITEMIDLIST);
156 extern LPITEMIDLIST (WINAPI *COMDLG32_PIDL_ILCombine)(LPCITEMIDLIST,LPCITEMIDLIST);
157 extern LPITEMIDLIST (WINAPI *COMDLG32_PIDL_ILGetNext)(LPITEMIDLIST);
158 extern BOOL (WINAPI *COMDLG32_PIDL_ILRemoveLastID)(LPCITEMIDLIST);
159 extern BOOL (WINAPI *COMDLG32_PIDL_ILIsEqual)(LPCITEMIDLIST, LPCITEMIDLIST);
161 /* SHELL */
162 extern LPVOID (WINAPI *COMDLG32_SHAlloc)(DWORD);
163 extern DWORD (WINAPI *COMDLG32_SHFree)(LPVOID);
164 extern BOOL (WINAPI *COMDLG32_SHGetFolderPathA)(HWND,int,HANDLE,DWORD,LPSTR);
165 extern BOOL (WINAPI *COMDLG32_SHGetFolderPathW)(HWND,int,HANDLE,DWORD,LPWSTR);
167 extern BOOL WINAPI GetFileDialog95A(LPOPENFILENAMEA ofn,UINT iDlgType);
168 extern BOOL WINAPI GetFileDialog95W(LPOPENFILENAMEW ofn,UINT iDlgType);
170 /* 16 bit api */
172 #include "pshpack1.h"
174 typedef UINT16 (CALLBACK *LPOFNHOOKPROC16)(HWND16,UINT16,WPARAM16,LPARAM);
176 typedef struct {
177 DWORD lStructSize;
178 HWND16 hwndOwner;
179 HINSTANCE16 hInstance;
180 SEGPTR lpstrFilter;
181 SEGPTR lpstrCustomFilter;
182 DWORD nMaxCustFilter;
183 DWORD nFilterIndex;
184 SEGPTR lpstrFile;
185 DWORD nMaxFile;
186 SEGPTR lpstrFileTitle;
187 DWORD nMaxFileTitle;
188 SEGPTR lpstrInitialDir;
189 SEGPTR lpstrTitle;
190 DWORD Flags;
191 UINT16 nFileOffset;
192 UINT16 nFileExtension;
193 SEGPTR lpstrDefExt;
194 LPARAM lCustData;
195 LPOFNHOOKPROC16 lpfnHook;
196 SEGPTR lpTemplateName;
197 } OPENFILENAME16,*LPOPENFILENAME16;
199 typedef UINT16 (CALLBACK *LPCCHOOKPROC16) (HWND16, UINT16, WPARAM16, LPARAM);
201 typedef struct {
202 DWORD lStructSize;
203 HWND16 hwndOwner;
204 HWND16 hInstance;
205 COLORREF rgbResult;
206 SEGPTR lpCustColors;
207 DWORD Flags;
208 LPARAM lCustData;
209 LPCCHOOKPROC16 lpfnHook;
210 SEGPTR lpTemplateName;
211 } CHOOSECOLOR16;
212 typedef CHOOSECOLOR16 *LPCHOOSECOLOR16;
214 typedef UINT16 (CALLBACK *LPFRHOOKPROC16)(HWND16,UINT16,WPARAM16,LPARAM);
215 typedef struct {
216 DWORD lStructSize; /* size of this struct 0x20 */
217 HWND16 hwndOwner; /* handle to owner's window */
218 HINSTANCE16 hInstance; /* instance handle of.EXE that */
219 /* contains cust. dlg. template */
220 DWORD Flags; /* one or more of the FR_?? */
221 SEGPTR lpstrFindWhat; /* ptr. to search string */
222 SEGPTR lpstrReplaceWith; /* ptr. to replace string */
223 UINT16 wFindWhatLen; /* size of find buffer */
224 UINT16 wReplaceWithLen; /* size of replace buffer */
225 LPARAM lCustData; /* data passed to hook fn. */
226 LPFRHOOKPROC16 lpfnHook;
227 SEGPTR lpTemplateName; /* custom template name */
228 } FINDREPLACE16, *LPFINDREPLACE16;
230 typedef UINT16 (CALLBACK *LPCFHOOKPROC16)(HWND16,UINT16,WPARAM16,LPARAM);
231 typedef struct
233 DWORD lStructSize;
234 HWND16 hwndOwner; /* caller's window handle */
235 HDC16 hDC; /* printer DC/IC or NULL */
236 SEGPTR lpLogFont; /* ptr. to a LOGFONT struct */
237 short iPointSize; /* 10 * size in points of selected font */
238 DWORD Flags; /* enum. type flags */
239 COLORREF rgbColors; /* returned text color */
240 LPARAM lCustData; /* data passed to hook fn. */
241 LPCFHOOKPROC16 lpfnHook;
242 SEGPTR lpTemplateName; /* custom template name */
243 HINSTANCE16 hInstance; /* instance handle of.EXE that */
244 /* contains cust. dlg. template */
245 SEGPTR lpszStyle; /* return the style field here */
246 /* must be LF_FACESIZE or bigger */
247 UINT16 nFontType; /* same value reported to the */
248 /* EnumFonts callback with the */
249 /* extra FONTTYPE_ bits added */
250 short nSizeMin; /* minimum pt size allowed & */
251 short nSizeMax; /* max pt size allowed if */
252 /* CF_LIMITSIZE is used */
253 } CHOOSEFONT16, *LPCHOOSEFONT16;
256 typedef UINT16 (CALLBACK *LPPRINTHOOKPROC16) (HWND16, UINT16, WPARAM16, LPARAM);
257 typedef UINT16 (CALLBACK *LPSETUPHOOKPROC16) (HWND16, UINT16, WPARAM16, LPARAM);
258 typedef struct
260 DWORD lStructSize;
261 HWND16 hwndOwner;
262 HGLOBAL16 hDevMode;
263 HGLOBAL16 hDevNames;
264 HDC16 hDC;
265 DWORD Flags;
266 WORD nFromPage;
267 WORD nToPage;
268 WORD nMinPage;
269 WORD nMaxPage;
270 WORD nCopies;
271 HINSTANCE16 hInstance;
272 LPARAM lCustData;
273 LPPRINTHOOKPROC16 lpfnPrintHook;
274 LPSETUPHOOKPROC16 lpfnSetupHook;
275 SEGPTR lpPrintTemplateName;
276 SEGPTR lpSetupTemplateName;
277 HGLOBAL16 hPrintTemplate;
278 HGLOBAL16 hSetupTemplate;
279 } PRINTDLG16, *LPPRINTDLG16;
281 BOOL16 WINAPI ChooseColor16(LPCHOOSECOLOR16 lpChCol);
282 HWND16 WINAPI FindText16( SEGPTR find);
283 INT16 WINAPI GetFileTitle16(LPCSTR lpFile, LPSTR lpTitle, UINT16 cbBuf);
284 BOOL16 WINAPI GetOpenFileName16(SEGPTR ofn);
285 BOOL16 WINAPI GetSaveFileName16(SEGPTR ofn);
286 BOOL16 WINAPI PrintDlg16( LPPRINTDLG16 print);
287 HWND16 WINAPI ReplaceText16( SEGPTR find);
288 BOOL16 WINAPI ChooseFont16(LPCHOOSEFONT16);
290 #include "poppack.h"
292 #endif /* _WINE_DLL_CDLG_H */