File: clAboutDialogBase.cpp

package info (click to toggle)
codelite 17.0.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 136,204 kB
  • sloc: cpp: 491,547; ansic: 280,393; php: 10,259; sh: 8,930; lisp: 7,664; vhdl: 6,518; python: 6,020; lex: 4,920; yacc: 3,123; perl: 2,385; javascript: 1,715; cs: 1,193; xml: 1,110; makefile: 804; cobol: 741; sql: 709; ruby: 620; f90: 566; ada: 534; asm: 464; fortran: 350; objc: 289; tcl: 258; java: 157; erlang: 61; pascal: 51; ml: 49; awk: 44; haskell: 36
file content (248 lines) | stat: -rw-r--r-- 10,453 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
//////////////////////////////////////////////////////////////////////
// This file was auto-generated by codelite's wxCrafter Plugin
// wxCrafter project file: clAboutDialogBase.wxcp
// Do not modify this file by hand!
//////////////////////////////////////////////////////////////////////

#include "clAboutDialogBase.h"

// Declare the bitmap loading function
extern void wxCA637InitBitmapResources();

namespace
{
// return the wxBORDER_SIMPLE that matches the current application theme
wxBorder get_border_simple_theme_aware_bit()
{
#if wxVERSION_NUMBER >= 3300 && defined(__WXMSW__)
    return wxSystemSettings::GetAppearance().IsDark() ? wxBORDER_SIMPLE : wxBORDER_STATIC;
#else
    return wxBORDER_DEFAULT;
#endif
} // DoGetBorderSimpleBit
bool bBitmapLoaded = false;
} // namespace

clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos,
                                     const wxSize& size, long style)
    : wxDialog(parent, id, title, pos, size, style)
{
    if(!bBitmapLoaded) {
        // We need to initialise the default bitmap handler
        wxXmlResource::Get()->AddHandler(new wxBitmapXmlHandler);
        wxCA637InitBitmapResources();
        bBitmapLoaded = true;
    }

    wxBoxSizer* boxSizer2 = new wxBoxSizer(wxVERTICAL);
    this->SetSizer(boxSizer2);

    m_notebook8 = new wxNotebook(this, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(this, wxSize(-1, -1)), wxBK_DEFAULT);
    m_notebook8->SetName(wxT("m_notebook8"));

    boxSizer2->Add(m_notebook8, 1, wxALL | wxEXPAND, WXC_FROM_DIP(5));

    m_panelAbout =
        new wxPanel(m_notebook8, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_notebook8, wxSize(-1, -1)), wxTAB_TRAVERSAL);
    m_notebook8->AddPage(m_panelAbout, _("About"), true);

    wxBoxSizer* boxSizer16 = new wxBoxSizer(wxVERTICAL);
    m_panelAbout->SetSizer(boxSizer16);

    m_staticTextTitle = new wxStaticText(m_panelAbout, wxID_ANY,
                                         _("CodeLite, a free, open source, C/C++/Rust/Python/PHP and JavaScript IDE"),
                                         wxDefaultPosition, wxDLG_UNIT(m_panelAbout, wxSize(-1, -1)), 0);
    wxFont m_staticTextTitleFont = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
    m_staticTextTitleFont.SetStyle(wxFONTSTYLE_ITALIC);
    m_staticTextTitle->SetFont(m_staticTextTitleFont);

    boxSizer16->Add(m_staticTextTitle, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, WXC_FROM_DIP(10));

    m_panel22 = new wxPanel(m_panelAbout, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_panelAbout, wxSize(-1, -1)),
                            wxTAB_TRAVERSAL);

    boxSizer16->Add(m_panel22, 1, wxEXPAND, WXC_FROM_DIP(5));

    wxBoxSizer* boxSizer26 = new wxBoxSizer(wxVERTICAL);
    m_panel22->SetSizer(boxSizer26);

    wxFlexGridSizer* flexGridSizer32 = new wxFlexGridSizer(0, 2, 0, 0);
    flexGridSizer32->SetFlexibleDirection(wxBOTH);
    flexGridSizer32->SetNonFlexibleGrowMode(wxFLEX_GROWMODE_SPECIFIED);

    boxSizer26->Add(flexGridSizer32, 1, wxALL | wxEXPAND, WXC_FROM_DIP(5));

    m_staticText34 = new wxStaticText(m_panel22, wxID_ANY, _("Author:"), wxDefaultPosition,
                                      wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
    wxFont m_staticText34Font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
    m_staticText34Font.SetStyle(wxFONTSTYLE_ITALIC);
    m_staticText34Font.SetWeight(wxFONTWEIGHT_BOLD);
    m_staticText34->SetFont(m_staticText34Font);

    flexGridSizer32->Add(m_staticText34, 0, wxRIGHT | wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL, WXC_FROM_DIP(5));

    m_staticTextSubtitle = new wxStaticText(m_panel22, wxID_ANY, _("2007 - 2023, by Eran Ifrah"), wxDefaultPosition,
                                            wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);

    flexGridSizer32->Add(m_staticTextSubtitle, 0, wxLEFT | wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL, WXC_FROM_DIP(5));

    m_staticText36 = new wxStaticText(m_panel22, wxID_ANY, _("Version:"), wxDefaultPosition,
                                      wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
    wxFont m_staticText36Font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
    m_staticText36Font.SetStyle(wxFONTSTYLE_ITALIC);
    m_staticText36Font.SetWeight(wxFONTWEIGHT_BOLD);
    m_staticText36->SetFont(m_staticText36Font);

    flexGridSizer32->Add(m_staticText36, 0, wxRIGHT | wxALIGN_RIGHT, WXC_FROM_DIP(5));

    m_staticTextVersion =
        new wxStaticText(m_panel22, wxID_ANY, wxT(""), wxDefaultPosition, wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);

    flexGridSizer32->Add(m_staticTextVersion, 0, wxLEFT | wxEXPAND, WXC_FROM_DIP(5));

    m_staticText40 = new wxStaticText(m_panel22, wxID_ANY, _("Home Page:"), wxDefaultPosition,
                                      wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
    wxFont m_staticText40Font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
    m_staticText40Font.SetStyle(wxFONTSTYLE_ITALIC);
    m_staticText40Font.SetWeight(wxFONTWEIGHT_BOLD);
    m_staticText40->SetFont(m_staticText40Font);

    flexGridSizer32->Add(m_staticText40, 0, wxRIGHT | wxALIGN_RIGHT, WXC_FROM_DIP(5));

    m_hyperLink44 = new wxHyperlinkCtrl(m_panel22, wxID_ANY, _("CodeLite IDE"), wxT("https://codelite.org"),
                                        wxDefaultPosition, wxDLG_UNIT(m_panel22, wxSize(-1, -1)), wxHL_DEFAULT_STYLE);
    m_hyperLink44->SetNormalColour(wxColour(wxT("#0000FF")));
    m_hyperLink44->SetHoverColour(wxColour(wxT("#0000FF")));
    m_hyperLink44->SetVisitedColour(wxColour(wxT("#FF0000")));

    flexGridSizer32->Add(m_hyperLink44, 0, wxLEFT, WXC_FROM_DIP(5));

    m_paneLicense =
        new wxPanel(m_notebook8, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_notebook8, wxSize(-1, -1)), wxTAB_TRAVERSAL);
    m_notebook8->AddPage(m_paneLicense, _("License"), false);

    wxBoxSizer* boxSizer18 = new wxBoxSizer(wxVERTICAL);
    m_paneLicense->SetSizer(boxSizer18);

    m_stcLicense =
        new clThemedSTC(m_paneLicense, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_paneLicense, wxSize(300, 200)),
                        wxTRANSPARENT_WINDOW | get_border_simple_theme_aware_bit());
    // Configure the fold margin
    m_stcLicense->SetMarginType(4, wxSTC_MARGIN_SYMBOL);
    m_stcLicense->SetMarginMask(4, wxSTC_MASK_FOLDERS);
    m_stcLicense->SetMarginSensitive(4, true);
    m_stcLicense->SetMarginWidth(4, 0);

    // Configure the tracker margin
    m_stcLicense->SetMarginWidth(1, 0);

    // Configure the symbol margin
    m_stcLicense->SetMarginType(2, wxSTC_MARGIN_SYMBOL);
    m_stcLicense->SetMarginMask(2, ~(wxSTC_MASK_FOLDERS));
    m_stcLicense->SetMarginWidth(2, 0);
    m_stcLicense->SetMarginSensitive(2, true);

    // Configure the line numbers margin
    m_stcLicense->SetMarginType(0, wxSTC_MARGIN_NUMBER);
    m_stcLicense->SetMarginWidth(0, 0);

    // Configure the line symbol margin
    m_stcLicense->SetMarginType(3, wxSTC_MARGIN_FORE);
    m_stcLicense->SetMarginMask(3, 0);
    m_stcLicense->SetMarginWidth(3, 0);
    // Select the lexer
    m_stcLicense->SetLexer(wxSTC_LEX_NULL);
    // Set default font / styles
    m_stcLicense->StyleClearAll();
    m_stcLicense->SetWrapMode(2);
    m_stcLicense->SetIndentationGuides(0);
    m_stcLicense->SetKeyWords(0, wxT(""));
    m_stcLicense->SetKeyWords(1, wxT(""));
    m_stcLicense->SetKeyWords(2, wxT(""));
    m_stcLicense->SetKeyWords(3, wxT(""));
    m_stcLicense->SetKeyWords(4, wxT(""));

    boxSizer18->Add(m_stcLicense, 1, wxEXPAND, WXC_FROM_DIP(5));

    m_panelCredits =
        new wxPanel(m_notebook8, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_notebook8, wxSize(-1, -1)), wxTAB_TRAVERSAL);
    m_notebook8->AddPage(m_panelCredits, _("Credits"), false);

    wxBoxSizer* boxSizer20 = new wxBoxSizer(wxVERTICAL);
    m_panelCredits->SetSizer(boxSizer20);

    m_stcCredits =
        new clThemedSTC(m_panelCredits, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_panelCredits, wxSize(-1, -1)),
                        wxTRANSPARENT_WINDOW | get_border_simple_theme_aware_bit());
    // Configure the fold margin
    m_stcCredits->SetMarginType(4, wxSTC_MARGIN_SYMBOL);
    m_stcCredits->SetMarginMask(4, wxSTC_MASK_FOLDERS);
    m_stcCredits->SetMarginSensitive(4, true);
    m_stcCredits->SetMarginWidth(4, 0);

    // Configure the tracker margin
    m_stcCredits->SetMarginWidth(1, 0);

    // Configure the symbol margin
    m_stcCredits->SetMarginType(2, wxSTC_MARGIN_SYMBOL);
    m_stcCredits->SetMarginMask(2, ~(wxSTC_MASK_FOLDERS));
    m_stcCredits->SetMarginWidth(2, 0);
    m_stcCredits->SetMarginSensitive(2, true);

    // Configure the line numbers margin
    m_stcCredits->SetMarginType(0, wxSTC_MARGIN_NUMBER);
    m_stcCredits->SetMarginWidth(0, 0);

    // Configure the line symbol margin
    m_stcCredits->SetMarginType(3, wxSTC_MARGIN_FORE);
    m_stcCredits->SetMarginMask(3, 0);
    m_stcCredits->SetMarginWidth(3, 0);
    // Select the lexer
    m_stcCredits->SetLexer(wxSTC_LEX_NULL);
    // Set default font / styles
    m_stcCredits->StyleClearAll();
    m_stcCredits->SetWrapMode(2);
    m_stcCredits->SetIndentationGuides(0);
    m_stcCredits->SetKeyWords(0, wxT(""));
    m_stcCredits->SetKeyWords(1, wxT(""));
    m_stcCredits->SetKeyWords(2, wxT(""));
    m_stcCredits->SetKeyWords(3, wxT(""));
    m_stcCredits->SetKeyWords(4, wxT(""));

    boxSizer20->Add(m_stcCredits, 1, wxEXPAND, WXC_FROM_DIP(5));

    m_stdBtnSizer4 = new wxStdDialogButtonSizer();

    boxSizer2->Add(m_stdBtnSizer4, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, WXC_FROM_DIP(5));

    m_button6 = new wxButton(this, wxID_OK, wxT(""), wxDefaultPosition, wxDLG_UNIT(this, wxSize(-1, -1)), 0);
    m_button6->SetDefault();
    m_stdBtnSizer4->AddButton(m_button6);
    m_stdBtnSizer4->Realize();

#if wxVERSION_NUMBER >= 2900
    if(!wxPersistenceManager::Get().Find(m_notebook8)) {
        wxPersistenceManager::Get().RegisterAndRestore(m_notebook8);
    } else {
        wxPersistenceManager::Get().Restore(m_notebook8);
    }
#endif

    SetName(wxT("clAboutDialogBase"));
    SetSize(wxDLG_UNIT(this, wxSize(-1, -1)));
    if(GetSizer()) {
        GetSizer()->Fit(this);
    }
    if(GetParent()) {
        CentreOnParent(wxBOTH);
    } else {
        CentreOnScreen(wxBOTH);
    }
    if(!wxPersistenceManager::Get().Find(this)) {
        wxPersistenceManager::Get().RegisterAndRestore(this);
    } else {
        wxPersistenceManager::Get().Restore(this);
    }
}

clAboutDialogBase::~clAboutDialogBase() {}