]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/msw/missing.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/msw/missing.h
3 // Purpose: Declarations for parts of the Win32 SDK that are missing in
4 // the versions that come with some compilers
7 // Copyright: (c) 2002 Mattia Barbon
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
11 #ifndef _WX_MISSING_H_
12 #define _WX_MISSING_H_
14 // ----------------------------------------------------------------------------
15 // ListView common control
16 // ----------------------------------------------------------------------------
20 (LVHT_ONITEMICON | LVHT_ONITEMLABEL | LVHT_ONITEMSTATEICON)
23 #ifndef LVM_SETEXTENDEDLISTVIEWSTYLE
24 #define LVM_SETEXTENDEDLISTVIEWSTYLE (0x1000 + 54)
27 #ifndef LVS_EX_FULLROWSELECT
28 #define LVS_EX_FULLROWSELECT 0x00000020
32 #define LVS_OWNERDATA 0x1000
36 #define LVM_FIRST 0x1000
40 #define HDM_FIRST 0x1200
43 #ifndef LVCFMT_JUSTIFYMASK
44 #define LVCFMT_JUSTIFYMASK 0x0003
47 #ifndef LVSICF_NOSCROLL
48 #define LVSICF_NOSCROLL 0x0002
51 // mingw32/cygwin don't have declarations for comctl32.dll 4.70+ stuff
53 typedef struct tagNMLVCACHEHINT
60 #define NM_CACHEHINT NMLVCACHEHINT
63 #ifndef LVN_ODCACHEHINT
64 #define LVN_ODCACHEHINT (-113)
67 #ifndef ListView_GetHeader
68 #define ListView_GetHeader(w) (HWND)SendMessage((w),LVM_GETHEADER,0,0)
72 #define LVM_GETHEADER (LVM_FIRST+31)
75 #ifndef Header_GetItemRect
76 #define Header_GetItemRect(w,i,r) \
77 (BOOL)SendMessage((w),HDM_GETITEMRECT,(WPARAM)(i),(LPARAM)(r))
80 #ifndef HDM_GETITEMRECT
81 #define HDM_GETITEMRECT (HDM_FIRST+7)
85 #define LVCF_IMAGE 0x0010
88 #ifndef LVCFMT_BITMAP_ON_RIGHT
89 #define LVCFMT_BITMAP_ON_RIGHT 0x1000
92 #if defined(__GNUWIN32__) && !defined(LV_ITEM) \
93 && !wxCHECK_W32API_VERSION( 0, 5 )
94 typedef struct _LVITEMW
{
104 #if (_WIN32_IE >= 0x0300)
109 typedef struct tagLVITEMA
120 #if (_WIN32_IE >= 0x0300)
125 #define LV_ITEM LV_ITEMA;
128 #ifndef ListView_GetColumnWidth
129 #define ListView_GetColumnWidth(hwnd, iCol) \
130 (int)SNDMSG((hwnd), LVM_GETCOLUMNWIDTH, (WPARAM)(int)(iCol), 0)
133 #ifndef ListView_SetColumnWidth
134 #define ListView_SetColumnWidth(hwnd, iCol, cx) \
135 (BOOL)SNDMSG((hwnd), LVM_SETCOLUMNWIDTH, (WPARAM)(int)(iCol), MAKELPARAM((cx), 0))
138 #ifndef ListView_GetTextColor
139 #define ListView_GetTextColor(hwnd) \
140 (COLORREF)SNDMSG((hwnd), LVM_GETTEXTCOLOR, 0, 0L)
143 #ifndef ListView_FindItem
144 #define ListView_FindItem(hwnd, iStart, plvfi) \
145 (int)SNDMSG((hwnd), LVM_FINDITEM, (WPARAM)(int)(iStart), (LPARAM)(const LV_FINDINFO FAR*)(plvfi))
148 #if defined(__GNUWIN32__) && !wxCHECK_W32API_VERSION( 0, 5 )
150 typedef struct tagNMLVDISPINFOA
{
153 } NMLVDISPINFOA
, FAR
*LPNMLVDISPINFOA
;
154 #define _LV_DISPINFOA tagNMLVDISPINFOA
155 #define LV_DISPINFOA NMLVDISPINFOA
158 typedef struct tagNMLVDISPINFOW
{
161 } NMLVDISPINFOW
, FAR
*LPNMLVDISPINFOW
;
162 #define _LV_DISPINFOW tagNMLVDISPINFOW
163 #define LV_DISPINFOW NMLVDISPINFOW
167 #if ((defined(__WATCOMC__) && __WATCOMC__ >= 1200) || defined(__GNUWIN32__) || defined (__MINGW32__) || defined(__DIGITALMARS__) || defined (__BORLANDC__)) && !defined(HDN_GETDISPINFOW)
168 #define HDN_GETDISPINFOW (HDN_FIRST-29)
169 #if !wxCHECK_W32API_VERSION(2, 2)
178 } NMHDDISPINFOW
, *LPNMHDDISPINFOW
;
182 // ----------------------------------------------------------------------------
183 // Toolbar define value missing
184 // ----------------------------------------------------------------------------
185 #if !defined(CCS_VERT)
186 #define CCS_VERT 0x00000080L
189 // ----------------------------------------------------------------------------
191 // ----------------------------------------------------------------------------
193 // instead of including htmlhelp.h, duplicate the things from it we need here:
211 HH_DISPLAY_TEXT_POPUP
,
213 HH_TP_HELP_CONTEXTMENU
,
221 HH_SET_INCLUSIVE_FILTER
,
222 HH_SET_EXCLUSIVE_FILTER
232 COLORREF clrForeground
;
233 COLORREF clrBackground
;
250 // ----------------------------------------------------------------------------
251 // SHGetFileInfo-related things
252 // ----------------------------------------------------------------------------
254 #ifndef SHGetFileInfo
256 #define SHGetFileInfo SHGetFileInfoW
258 #define SHGetFileInfo SHGetFileInfoA
262 #ifndef SHGFI_ATTRIBUTES
263 #define SHGFI_ATTRIBUTES 2048
266 #ifndef SFGAO_READONLY
267 #define SFGAO_READONLY 0x00040000L
270 #ifndef SFGAO_REMOVABLE
271 #define SFGAO_REMOVABLE 0x02000000L
274 #ifndef SHGFI_DISPLAYNAME
275 #define SHGFI_DISPLAYNAME 512
279 #define SHGFI_ICON 256
282 #ifndef SHGFI_SMALLICON
283 #define SHGFI_SMALLICON 1
286 #ifndef SHGFI_SHELLICONSIZE
287 #define SHGFI_SHELLICONSIZE 4
290 #ifndef SHGFI_OPENICON
291 #define SHGFI_OPENICON 2
294 // ----------------------------------------------------------------------------
296 // ----------------------------------------------------------------------------
298 #if wxUSE_RICHEDIT && defined(MAX_TAB_STOPS)
300 // old mingw32 doesn't define this
302 #define CFM_CHARSET 0x08000000
303 #endif // CFM_CHARSET
305 #ifndef CFM_BACKCOLOR
306 #define CFM_BACKCOLOR 0x04000000
309 // cygwin does not have these defined for richedit
311 #define ENM_LINK 0x04000000
314 #ifndef EM_AUTOURLDETECT
315 #define EM_AUTOURLDETECT (WM_USER + 91)
319 #define EN_LINK 0x070b
321 typedef struct _enlink
332 #define SF_UNICODE 0x0010
335 // Watcom C++ doesn't define this
337 #define SCF_ALL 0x0004
341 #define PFA_JUSTIFY 4
343 typedef struct _paraformat2
{
353 LONG rgxTabs
[MAX_TAB_STOPS
];
358 BYTE bLineSpacingRule
;
362 WORD wNumberingStart
;
363 WORD wNumberingStyle
;
369 #define wxEffects wReserved
373 #endif // wxUSE_RICHEDIT
375 // ----------------------------------------------------------------------------
377 // ----------------------------------------------------------------------------
381 #if !defined(TBIF_SIZE)
384 #define TB_SETBUTTONINFO (WM_USER+66)
397 } TBBUTTONINFO
, *LPTBBUTTONINFO
;
399 #endif // !defined(TBIF_SIZE)
401 #endif // wxUSE_TOOLBAR
403 // ----------------------------------------------------------------------------
405 // ----------------------------------------------------------------------------
408 #define TVIS_FOCUSED 0x0001
412 #define TV_FIRST 0x1100
415 #ifndef TVS_CHECKBOXES
416 #define TVS_CHECKBOXES 0x0100
419 #ifndef TVS_FULLROWSELECT
420 #define TVS_FULLROWSELECT 0x1000
423 #ifndef TVM_SETBKCOLOR
424 #define TVM_SETBKCOLOR (TV_FIRST + 29)
425 #define TVM_SETTEXTCOLOR (TV_FIRST + 30)
428 // ----------------------------------------------------------------------------
430 // ----------------------------------------------------------------------------
432 #ifndef QS_ALLPOSTMESSAGE
433 #define QS_ALLPOSTMESSAGE 0x0100
436 #ifndef WS_EX_CLIENTEDGE
437 #define WS_EX_CLIENTEDGE 0x00000200L
440 #ifndef ENDSESSION_LOGOFF
441 #define ENDSESSION_LOGOFF 0x80000000
444 #ifndef HANGUL_CHARSET
445 #define HANGUL_CHARSET 129