György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 1 | /* |
Mike McCormack | e09aecf | 2006-06-13 18:34:27 +0900 | [diff] [blame] | 2 | * Copyright (C) 2002 Gyorgy 'Nog' Jeney |
György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 3 | * |
| 4 | * This library is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of the GNU Lesser General Public |
| 6 | * License as published by the Free Software Foundation; either |
| 7 | * version 2.1 of the License, or (at your option) any later version. |
| 8 | * |
| 9 | * This library is distributed in the hope that it will be useful, |
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 | * Lesser General Public License for more details. |
| 13 | * |
| 14 | * You should have received a copy of the GNU Lesser General Public |
| 15 | * License along with this library; if not, write to the Free Software |
Jonathan Ernst | 360a3f9 | 2006-05-18 14:49:52 +0200 | [diff] [blame] | 16 | * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA |
György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 17 | */ |
| 18 | |
| 19 | #ifndef _INC_CUSTCNTL |
| 20 | #define _INC_CUSTCNTL |
| 21 | |
| 22 | #ifdef __cplusplus |
| 23 | extern "C" { |
| 24 | #endif |
| 25 | |
| 26 | /* Size defs */ |
| 27 | #define CCHCCCLASS 32 |
| 28 | #define CCHCCDESC 32 |
| 29 | #define CCHCCTEXT 256 |
| 30 | |
Austin English | 6e59cd2 | 2008-04-22 01:18:14 -0500 | [diff] [blame] | 31 | /* Custom Control Style Structure */ |
György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 32 | typedef struct tagCCSYLEA { |
| 33 | DWORD flStyle; |
| 34 | DWORD flExtStyle; |
| 35 | char szText[CCHCCTEXT]; |
| 36 | LANGID lgid; |
| 37 | WORD wReserved1; |
| 38 | } CCSTYLEA, *LPCCSTYLEA; |
| 39 | |
| 40 | typedef struct tagCCSYLEW { |
| 41 | DWORD flStyle; |
| 42 | DWORD flExtStyle; |
| 43 | WCHAR szText[CCHCCTEXT]; |
| 44 | LANGID lgid; |
| 45 | WORD wReserved1; |
| 46 | } CCSTYLEW, *LPCCSTYLEW; |
| 47 | |
| 48 | #define CCSTYLE WINELIB_NAME_AW(CCSTYLE) |
| 49 | #define LPCCSTYLE WINELIB_NAME_AW(LPCCSTYLE) |
| 50 | |
| 51 | typedef BOOL (CALLBACK *LPFNCCSTYLEA)(HWND, LPCCSTYLEA); |
| 52 | typedef BOOL (CALLBACK *LPFNCCSTYLEW)(HWND, LPCCSTYLEW); |
| 53 | |
| 54 | #define LPFNCCSTYLE WINELIB_NAME_AW(LPFNCCSTYLE) |
| 55 | |
| 56 | typedef int (CALLBACK *LPFNCCSIZETOTEXTA)(DWORD, DWORD, HFONT, LPSTR); |
| 57 | typedef int (CALLBACK *LPFNCCSIZETOTEXTW)(DWORD, DWORD, HFONT, LPWSTR); |
| 58 | |
| 59 | #define LPFNCCSIZETOTEXT WINELIB_NAME_AW(LPFNCCSIZETOTEXT) |
| 60 | |
Francois Gouget | 4527aae | 2005-04-19 09:49:38 +0000 | [diff] [blame] | 61 | /* Custom Control style flags structure */ |
György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 62 | typedef struct tagCCSTYLEFLAGA { |
| 63 | DWORD flStyle; |
| 64 | DWORD flStyleMask; |
| 65 | LPSTR pszStyle; |
| 66 | } CCSTYLEFLAGA, *LPCCSTYLEFLAGA; |
| 67 | |
| 68 | typedef struct tagCCSTYLEFLAGW { |
| 69 | DWORD flStyle; |
| 70 | DWORD flStyleMask; |
| 71 | LPWSTR pszStyle; |
| 72 | } CCSTYLEFLAGW, *LPCCSTYLEFLAGW; |
| 73 | |
| 74 | #define CCSTYLEFLAG WINELIB_NAME_AW(CCSTYLEFLAG) |
| 75 | |
| 76 | /* Custom Control Flags */ |
| 77 | #define CCF_NOTEXT 0x00000001 |
| 78 | |
| 79 | /* CustomControl info structure */ |
| 80 | typedef struct tagCCINFOA { |
| 81 | char szClass[CCHCCCLASS]; |
| 82 | DWORD flOptions; |
| 83 | char szDesc[CCHCCDESC]; |
| 84 | UINT cxDefault; |
| 85 | UINT cyDefault; |
| 86 | DWORD flStyleDefault; |
| 87 | DWORD flExtStyleDefault; |
| 88 | DWORD flCtrlTypeMask; |
| 89 | char szTextDefault[CCHCCTEXT]; |
| 90 | int cStyleFlags; |
| 91 | LPCCSTYLEFLAGA aStyleFlags; |
| 92 | LPFNCCSTYLEA lpfnStyle; |
| 93 | LPFNCCSIZETOTEXTA lpfnSizeToText; |
| 94 | DWORD dwReserved1; |
| 95 | DWORD dwReserved2; |
| 96 | } CCINFOA, *LPCCINFOA; |
| 97 | |
| 98 | typedef struct tagCCINFOW { |
| 99 | WCHAR szClass[CCHCCCLASS]; |
| 100 | DWORD flOptions; |
| 101 | WCHAR szDesc[CCHCCDESC]; |
| 102 | UINT cxDefault; |
| 103 | UINT cyDefault; |
| 104 | DWORD flStyleDefault; |
| 105 | DWORD flExtStyleDefault; |
| 106 | DWORD flCtrlTypeMask; |
| 107 | int cStyleFlags; |
| 108 | LPCCSTYLEFLAGW aStyleFlags; |
| 109 | WCHAR szTextDefault[CCHCCTEXT]; |
| 110 | LPFNCCSTYLEW lpfnStyle; |
| 111 | LPFNCCSIZETOTEXTW lpfnSizeToText; |
| 112 | DWORD dwReserved1; |
| 113 | DWORD dwReserved2; |
| 114 | } CCINFOW, *LPCCINFOW; |
| 115 | |
Juraj Hercek | 3588ede | 2002-11-08 18:54:26 +0000 | [diff] [blame] | 116 | DECL_WINELIB_TYPE_AW(CCINFO) |
| 117 | DECL_WINELIB_TYPE_AW(LPCCINFO) |
György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 118 | |
| 119 | typedef UINT (CALLBACK *LPFNCCINFOA)(LPCCINFOA); |
| 120 | typedef UINT (CALLBACK *LPFNCCINFOW)(LPCCINFOW); |
| 121 | |
Juraj Hercek | 3588ede | 2002-11-08 18:54:26 +0000 | [diff] [blame] | 122 | DECL_WINELIB_TYPE_AW(LPFNCCINFO) |
György 'Nog' Jeney | dfacb6e | 2002-09-29 18:04:15 +0000 | [diff] [blame] | 123 | |
| 124 | #ifdef __cplusplus |
| 125 | } |
| 126 | #endif |
| 127 | |
| 128 | #endif /* _INC_CUSTCNTL */ |