]> git.saurik.com Git - wxWidgets.git/blob - contrib/utils/convertrc/rc2xml.h
Version number updates
[wxWidgets.git] / contrib / utils / convertrc / rc2xml.h
1 // rc2xml.h
2 //
3 //////////////////////////////////////////////////////////////////////
4
5 #if !defined(RC2XML_H)
6 #define RC2XML_H
7
8 #ifdef __GNUG__
9 #pragma interface "rc2xml.h"
10 #endif
11
12 #include "wx/file.h"
13 #include <wx/ffile.h>
14 #include <wx/list.h>
15
16
17 class rc2xml : public wxObject
18 {
19 public:
20 wxString m_workingpath;
21 wxString m_targetpath;
22 void WriteIcon(wxString iconname);
23 void ParseNormalMSControl();
24 bool Convert(wxString rcfile, wxString xmlfile);
25 rc2xml();
26 ~rc2xml();
27
28 protected:
29 wxString LookUpId(wxString id);
30
31 void ParseResourceHeader();
32 void WriteBitmap(wxString bitmapname);
33 void ParseListCtrl(wxString label,wxString varname);
34 void ParseCalendar(wxString label,wxString varname);
35 void ParseTreeCtrl(wxString label,wxString varname);
36 void ParseScrollBar();
37 void ParseWeirdMSControl();
38 void ParseStaticBitmap(wxString label,wxString varname);
39 wxString CleanName(wxString name);
40 void ParseIcon(wxString varname);
41 wxList * m_iconlist;
42 void ParseIconStatic();
43 void ParseMenuItem();
44
45 //Functions
46 bool SplitHelp(wxString msg, wxString &shorthelp, wxString &longhelp);
47 bool LookUpString(wxString strid,wxString & st);
48 void ParseStringTable(wxString varname);
49 void WriteToolButton(wxString name,int index,int width,int height,wxBitmap bitmap);
50 wxString LookupString(wxString varname,wxStringList id,wxStringList msg);
51 void ParseToolBar(wxString varname);
52 void SecondPass();
53 void FirstPass();
54 void ParseBitmap(wxString varname);
55 void ParseSpinCtrl(wxString label,wxString varname);
56 void ParseRichEdit(wxString label, wxString varname);
57 void ParseDialog(wxString dlgname);
58 void ParseControls();
59 void ParseListBox(wxString varname);
60 void ParseStaticText(wxString phrase,wxString varname);
61 void ParseTextCtrl(wxString varname);
62 void ParseRadioButton(wxString phrase,wxString varname);
63 void ParseCheckBox(wxString phrase,wxString varname);
64 void ParsePushButton(wxString phrase, wxString varname);
65 bool Seperator(int ch);
66 void ParseGroupBox(wxString phrase, wxString varname);
67 bool ReadRect(int & x, int & y, int & width, int & height);
68 wxString GetToken(bool *listseperator = 0);
69 wxString GetQuoteField();
70 wxString GetStringQuote();
71 void ReadChar(int &ch);
72 void ParseComboBox(wxString varname);
73 void ParseMenu(wxString varname);
74 void ParsePopupMenu();
75 wxString PeekToken();
76 void ParseControlMS();
77 void ParseSlider(wxString label, wxString varname);
78 void ParseProgressBar(wxString label, wxString varname);
79 bool ReadOrs(wxString & w);
80 void ParseCtrlButton(wxString label, wxString varname);
81 void WriteStyle(wxString style);
82 void WriteBasicInfo(int x,int y,int width,int height,wxString name);
83 void WriteName(wxString name);
84 void WriteTitle(wxString title);
85 void WritePosition(int x,int y);
86 void WriteSize(int width,int height);
87 void WriteLabel(wxString label);
88 //variables
89 wxList * m_stringtable;
90 wxList *m_bitmaplist;
91 wxList * m_resourcelist;
92 wxFile m_rc;
93 wxFFile m_xmlfile;
94 wxFileOffset m_filesize;
95 bool m_done;
96
97 };
98
99
100 #endif