mCtrl  0.9.0
mditab.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2008-2013 Martin Mitas
3  *
4  * This library is free software; you can redistribute it and/or modify it
5  * under the terms of the GNU Lesser General Public License as published by
6  * the Free Software Foundation; either version 2.1 of the License, or
7  * (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
12  * GNU Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public License
15  * along with this library; if not, write to the Free Software Foundation,
16  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17  */
18 
19 #ifndef MCTRL_MDITAB_H
20 #define MCTRL_MDITAB_H
21 
22 #include <mCtrl/defs.h>
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
28 
94 
100 
104 void MCTRL_API mcMditab_Terminate(void);
105 
113 
115 #define MC_WC_MDITABW L"mCtrl.mditab"
116 
117 #define MC_WC_MDITABA "mCtrl.mditab"
118 
126 
128 #define MC_MTS_CBONTOOLBAR 0x0000
129 
130 #define MC_MTS_CBONEACHTAB 0x0001
131 
132 #define MC_MTS_CBONACTIVETAB 0x0002
133 
134 #define MC_MTS_CBNONE 0x0003
135 
136 #define MC_MTS_CBMASK 0x0003
137 
139 #define MC_MTS_TLBALWAYS 0x0000
140 
141 #define MC_MTS_TLBONSCROLL 0x0004
142 
143 #define MC_MTS_TLBNEVER 0x0008
144 
145 #define MC_MTS_TLBMASK 0x000C
146 
148 #define MC_MTS_SCROLLALWAYS 0x0010
149 
151 #define MC_MTS_CLOSEONMCLICK 0x0020
152 
154 #define MC_MTS_FOCUSONBUTTONDOWN 0x0040
155 
156 #define MC_MTS_FOCUSNEVER 0x0080
157 
158 #define MC_MTS_FOCUSMASK 0x00C0
159 
163 #define MC_MTS_DOUBLEBUFFER 0x0100
164 
173 
175 #define MC_MTIF_TEXT (1 << 0)
176 
177 #define MC_MTIF_IMAGE (1 << 1)
178 
179 #define MC_MTIF_PARAM (1 << 2)
180 
190 #define MC_MTHT_NOWHERE (1 << 0)
191 
192 #define MC_MTHT_ONITEMICON (1 << 1)
193 
194 #define MC_MTHT_ONITEMLABEL (1 << 2)
195 
196 #define MC_MTHT_ONITEMCLOSEBUTTON (1 << 3)
197 
198 #define MC_MTHT_ONITEM \
199  (MC_MTHT_ONITEMICON | MC_MTHT_ONITEMLABEL | MC_MTHT_ONITEMCLOSEBUTTON)
200 
207 
212 typedef struct MC_MTITEMW_tag {
215  DWORD dwMask;
217  LPWSTR pszText;
222  int iImage;
224  LPARAM lParam;
225 } MC_MTITEMW;
226 
231 typedef struct MC_MTITEMA_tag {
234  DWORD dwMask;
236  LPSTR pszText;
241  int iImage;
243  LPARAM lParam;
244 } MC_MTITEMA;
245 
255 typedef struct MC_MTITEMWIDTH_tag {
257  DWORD dwDefWidth;
259  DWORD dwMinWidth;
261 
265 typedef struct MC_MTHITTESTINFO_tag {
267  POINT pt;
269  UINT flags;
271 
275 typedef struct MC_NMMTSELCHANGE_tag {
277  NMHDR hdr;
279  int iItemOld;
281  LPARAM lParamOld;
283  int iItemNew;
285  LPARAM lParamNew;
287 
291 typedef struct MC_NMMTDELETEITEM_tag {
293  NMHDR hdr;
295  int iItem;
297  LPARAM lParam;
299 
300 
304 typedef struct MC_NMMTCLOSEITEM_tag {
306  NMHDR hdr;
308  int iItem;
310  LPARAM lParam;
312 
320 
327 #define MC_MTM_GETITEMCOUNT (MC_MTM_FIRST + 0)
328 
337 #define MC_MTM_GETIMAGELIST (MC_MTM_FIRST + 1)
338 
349 #define MC_MTM_SETIMAGELIST (MC_MTM_FIRST + 2)
350 
363 #define MC_MTM_DELETEALLITEMS (MC_MTM_FIRST + 3)
364 
373 #define MC_MTM_INSERTITEMW (MC_MTM_FIRST + 4)
374 
382 #define MC_MTM_INSERTITEMA (MC_MTM_FIRST + 5)
383 
390 #define MC_MTM_SETITEMW (MC_MTM_FIRST + 6)
391 
398 #define MC_MTM_SETITEMA (MC_MTM_FIRST + 7)
399 
414 #define MC_MTM_GETITEMW (MC_MTM_FIRST + 8)
415 
430 #define MC_MTM_GETITEMA (MC_MTM_FIRST + 9)
431 
440 #define MC_MTM_DELETEITEM (MC_MTM_FIRST + 10)
441 
449 #define MC_MTM_HITTEST (MC_MTM_FIRST + 11)
450 
457 #define MC_MTM_SETCURSEL (MC_MTM_FIRST + 12)
458 
465 #define MC_MTM_GETCURSEL (MC_MTM_FIRST + 13)
466 
476 #define MC_MTM_CLOSEITEM (MC_MTM_FIRST + 14)
477 
491 #define MC_MTM_SETITEMWIDTH (MC_MTM_FIRST + 15)
492 
501 #define MC_MTM_GETITEMWIDTH (MC_MTM_FIRST + 16)
502 
512 #define MC_MTM_INITSTORAGE (MC_MTM_FIRST + 17)
513 
521 
529 #define MC_MTN_SELCHANGE (MC_MTN_FIRST + 0)
530 
538 #define MC_MTN_DELETEITEM (MC_MTN_FIRST + 1)
539 
551 #define MC_MTN_DELETEALLITEMS (MC_MTN_FIRST + 2)
552 
562 #define MC_MTN_CLOSEITEM (MC_MTN_FIRST + 3)
563 
571 
573 #define MC_WC_MDITAB MCTRL_NAME_AW(MC_WC_MDITAB)
574 
575 #define MC_MTITEM MCTRL_NAME_AW(MC_MTITEM)
576 
577 #define MC_MTM_INSERTITEM MCTRL_NAME_AW(MC_MTM_INSERTITEM)
578 
579 #define MC_MTM_SETITEM MCTRL_NAME_AW(MC_MTM_SETITEM)
580 
581 #define MC_MTM_GETITEM MCTRL_NAME_AW(MC_MTM_GETITEM)
582 
586 #ifdef __cplusplus
587 } /* extern "C" */
588 #endif
589 
590 #endif /* MCTRL_MDITAB_H */