]> git.saurik.com Git - wxWidgets.git/blame - utils/dialoged/src/winstyle.h
Cured some small doc typos; some WIN16 fixes; transferred DLL WinMain to
[wxWidgets.git] / utils / dialoged / src / winstyle.h
CommitLineData
7c23a0b0
JS
1/////////////////////////////////////////////////////////////////////////////
2// Name: winstyle.h
3// Purpose: Window styles
4// Author: Julian Smart
5// Modified by:
6// Created: 04/01/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _DE_WINSTYLE_H_
13#define _DE_WINSTYLE_H_
14
15#ifdef __GNUG__
16#pragma interface "winstyle.h"
17#endif
18
19#include "wx/wx.h"
20
21/*
22 * A class for storing/generating window styles.
23 */
24
25class wxWindowStyleClass;
26
27class wxWindowStylePair
28{
29 friend class wxWindowStyleClass;
30public:
31 char* m_styleName;
32 long m_styleId;
33};
34
35class wxWindowStyleTable: public wxObject
36{
37public:
38 wxWindowStyleTable();
39 ~wxWindowStyleTable();
40
41// Operations
42 void ClearTable();
43 void AddStyles(const wxString& className, int n, wxWindowStylePair *styles);
44 wxWindowStyleClass* FindClass(const wxString& className) ;
45 bool GenerateStyleStrings(const wxString& className, long windowStyle, char *buf);
46
47 // Initialise with all possible styles
48 void Init();
49
50// Members
51protected:
52 wxList m_classes; // A list of wxWindowStyleClass objects, indexed by class name
53
54};
55
56/*
57 * Classes for storing all the window style identifiers associated with a particular class
58 */
59
60class wxWindowStyleClass: public wxObject
61{
62public:
63 wxWindowStyleClass(int n, wxWindowStylePair *styles);
64 ~wxWindowStyleClass();
65
66// Operations
67 void GenerateStyleStrings(long windowStyle, char *buf);
68 bool GenerateStyle(char *buf, long windowStyle, long flag, const wxString& strStyle);
69
70// Members
71protected:
72 wxWindowStylePair* m_styles; // An array of wxWindowStylePair objects
73 int m_styleCount;
74};
75
76#endif
77 // _DE_WINSTYLE_H_