#include "wx/sizer.h"
#include "widgets.h"
-
+#if 1
#include "icons/button.xpm"
// ----------------------------------------------------------------------------
sizerRight->Add(0, 0, 1, wxCENTRE);
sizerRight->Add(m_button, 1, wxCENTRE);
sizerRight->Add(0, 0, 1, wxCENTRE);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerButton = sizerRight; // save it to modify it later
// the 3 panes panes compose the window
wxLogMessage(_T("Test button clicked."));
}
+#endif
\ No newline at end of file
#include "wx/sizer.h"
#include "widgets.h"
-
+#if 1
#include "icons/combobox.xpm"
// ----------------------------------------------------------------------------
0, NULL,
0);
sizerRight->Add(m_combobox, 1, wxGROW | wxALL, 5);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerCombo = sizerRight; // save it to modify it later
// the 3 panes panes compose the window
#endif //wxUSE_COMBOBOX
+#endif
#include "wx/sizer.h"
#include "widgets.h"
-
+#if 1
#include "icons/gauge.xpm"
// ----------------------------------------------------------------------------
wxSizer *sizerRight = new wxBoxSizer(wxHORIZONTAL);
m_gauge = new wxGauge(this, GaugePage_Gauge, m_range);
sizerRight->Add(m_gauge, 1, wxCENTRE | wxALL, 5);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerGauge = sizerRight; // save it to modify it later
// the 3 panes panes compose the window
wxLogMessage(_T("Progress finished."));
}
+#endif
\ No newline at end of file
#include "wx/checklst.h"
#include "widgets.h"
-
+#if 1
#include "icons/listbox.xpm"
// ----------------------------------------------------------------------------
0, NULL,
wxLB_HSCROLL);
sizerRight->Add(m_lbox, 1, wxGROW | wxALL, 5);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerLbox = sizerRight; // save it to modify it later
// the 3 panes panes compose the window
CreateLbox();
}
+#endif
\ No newline at end of file
#include "wx/artprov.h"
#include "widgets.h"
-
+#if 1
#include "icons/notebook.xpm"
// ----------------------------------------------------------------------------
wxSizer *sizerRight = new wxBoxSizer(wxHORIZONTAL);
m_notebook = new wxNotebook(this, NotebookPage_Notebook);
sizerRight->Add(m_notebook, 1, wxGROW | wxALL, 5);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerNotebook = sizerRight; // save it to modify it later
// the 3 panes panes compose the window
event.Skip();
}
+#endif
\ No newline at end of file
#include "wx/sizer.h"
#include "widgets.h"
-
+#if 1
#include "icons/radiobox.xpm"
// ----------------------------------------------------------------------------
// default values for the number of radiobox items
static const size_t DEFAULT_NUM_ENTRIES = 12;
-static const size_t DEFAULT_MAJOR_DIM = 4;
+static const size_t DEFAULT_MAJOR_DIM = 3;
// ----------------------------------------------------------------------------
// RadioWidgetsPage
m_radioDir = new wxRadioBox(this, -1, _T("Numbering:"),
wxDefaultPosition, wxDefaultSize,
- WXSIZEOF(layoutDir), layoutDir);
+ WXSIZEOF(layoutDir), layoutDir,
+ 1, wxRA_SPECIFY_COLS);
sizerLeft->Add(m_radioDir, 0, wxGROW | wxALL, 5);
// if it's not defined, we can't change the radiobox direction
#endif // wxRA_LEFTTORIGHT
wxSizer *sizerRow;
- sizerRow = CreateSizerWithTextAndLabel(_T("&Major dimension"),
+ sizerRow = CreateSizerWithTextAndLabel(_T("&Major dimension:"),
-1,
&m_textMajorDim);
sizerLeft->Add(sizerRow, 0, wxGROW | wxALL, 5);
- sizerRow = CreateSizerWithTextAndLabel(_T("&Number of buttons"),
+ sizerRow = CreateSizerWithTextAndLabel(_T("&Number of buttons:"),
-1,
&m_textNumBtns);
sizerLeft->Add(sizerRow, 0, wxGROW | wxALL, 5);
wxStaticBox *box2 = new wxStaticBox(this, -1, _T("&Change parameters"));
wxSizer *sizerMiddle = new wxStaticBoxSizer(box2, wxVERTICAL);
- sizerRow = CreateSizerWithTextAndLabel(_T("Current selection"),
+ sizerRow = CreateSizerWithTextAndLabel(_T("Current selection:"),
-1,
&m_textCurSel);
sizerMiddle->Add(sizerRow, 0, wxGROW | wxALL, 5);
sizerRow = CreateSizerWithTextAndButton(RadioPage_Selection,
- _T("&Change selection"),
+ _T("&Change selection:"),
-1,
&m_textSel);
sizerMiddle->Add(sizerRow, 0, wxGROW | wxALL, 5);
sizerRow = CreateSizerWithTextAndButton(RadioPage_Label,
- _T("&Label for box"),
+ _T("&Label for box:"),
-1,
&m_textLabel);
sizerMiddle->Add(sizerRow, 0, wxGROW | wxALL, 5);
sizerRow = CreateSizerWithTextAndButton(RadioPage_LabelBtn,
- _T("&Label for buttons"),
+ _T("&Label for buttons:"),
-1,
&m_textLabelBtns);
sizerMiddle->Add(sizerRow, 0, wxGROW | wxALL, 5);
// right pane
wxSizer *sizerRight = new wxBoxSizer(wxHORIZONTAL);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerRadio = sizerRight; // save it to modify it later
Reset();
// the 3 panes panes compose the window
sizerTop->Add(sizerLeft, 0, wxGROW | (wxALL & ~wxLEFT), 10);
sizerTop->Add(sizerMiddle, 1, wxGROW | wxALL, 10);
- sizerTop->Add(sizerRight, 1, wxGROW | (wxALL & ~wxRIGHT), 10);
+ sizerTop->Add(sizerRight, 0, wxGROW | (wxALL & ~wxRIGHT), 10);
// final initializations
SetAutoLayout(TRUE);
event.Enable(enable);
}
+#endif
\ No newline at end of file
#include "wx/sizer.h"
#include "widgets.h"
-
+#if 1
#include "icons/slider.xpm"
// ----------------------------------------------------------------------------
// right pane
wxSizer *sizerRight = new wxBoxSizer(wxHORIZONTAL);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerSlider = sizerRight; // save it to modify it later
Reset();
// the 3 panes panes compose the window
sizerTop->Add(sizerLeft, 0, wxGROW | (wxALL & ~wxLEFT), 10);
- sizerTop->Add(sizerMiddle, 1, wxGROW | wxALL, 10);
+ sizerTop->Add(sizerMiddle, 0, wxGROW | wxALL, 10);
sizerTop->Add(sizerRight, 1, wxGROW | (wxALL & ~wxRIGHT), 10);
// final initializations
wxLogMessage(_T("Slider value changed, now %d"), value);
}
+#endif
\ No newline at end of file
#include "wx/sizer.h"
#include "widgets.h"
-
+#if 1
#include "icons/spinbtn.xpm"
// ----------------------------------------------------------------------------
// right pane
wxSizer *sizerRight = new wxBoxSizer(wxVERTICAL);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerSpin = sizerRight; // save it to modify it later
Reset();
// the 3 panes panes compose the window
sizerTop->Add(sizerLeft, 0, wxGROW | (wxALL & ~wxLEFT), 10);
- sizerTop->Add(sizerMiddle, 1, wxGROW | wxALL, 10);
+ sizerTop->Add(sizerMiddle, 0, wxGROW | wxALL, 10);
sizerTop->Add(sizerRight, 1, wxGROW | (wxALL & ~wxRIGHT), 10);
// final initializations
wxLogMessage(_T("Spin control value changed, now %d"), value);
}
+#endif
\ No newline at end of file
#include "wx/statline.h"
#include "widgets.h"
-
+#if 1
#include "icons/statbox.xpm"
// ----------------------------------------------------------------------------
// right pane
wxSizer *sizerRight = new wxBoxSizer(wxHORIZONTAL);
- sizerRight->SetMinSize(250, 0);
+ sizerRight->SetMinSize(150, 0);
m_sizerStatic = sizerRight;
CreateStatic();
// the 3 panes panes compose the window
sizerTop->Add(sizerLeft, 0, wxGROW | (wxALL & ~wxLEFT), 10);
- sizerTop->Add(sizerMiddle, 1, wxGROW | wxALL, 10);
+ sizerTop->Add(sizerMiddle, 0, wxGROW | wxALL, 10);
sizerTop->Add(sizerRight, 1, wxGROW | (wxALL & ~wxRIGHT), 10);
// final initializations
m_statText->SetLabel(m_textLabel->GetValue());
}
+#endif
\ No newline at end of file
#include "widgets.h"
+#if 1
#include "icons/text.xpm"
// ----------------------------------------------------------------------------
#endif // __WXMSW__
wxButton *btn = new wxButton(this, TextPage_Reset, _T("&Reset"));
- sizerLeft->Add(5, 5, 0, wxGROW | wxALL, 5); // spacer
+ sizerLeft->Add(2, 2, 0, wxGROW | wxALL, 1); // spacer
sizerLeft->Add(btn, 0, wxALIGN_CENTRE_HORIZONTAL | wxALL, 15);
// middle pane
wxSizer *sizerMiddleUp = new wxStaticBoxSizer(box2, wxVERTICAL);
btn = new wxButton(this, TextPage_Set, _T("&Set text value"));
- sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 5);
+ sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 1);
btn = new wxButton(this, TextPage_Add, _T("&Append text"));
- sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 5);
+ sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 1);
btn = new wxButton(this, TextPage_Insert, _T("&Insert text"));
- sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 5);
+ sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 1);
btn = new wxButton(this, TextPage_Load, _T("&Load file"));
- sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 5);
+ sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 1);
btn = new wxButton(this, TextPage_Clear, _T("&Clear"));
- sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 5);
+ sizerMiddleUp->Add(btn, 0, wxALL | wxGROW, 1);
wxStaticBox *box4 = new wxStaticBox(this, -1, _T("&Info:"));
wxSizer *sizerMiddleDown = new wxStaticBoxSizer(box4, wxVERTICAL);
m_sizerText = new wxStaticBoxSizer(box3, wxHORIZONTAL);
Reset();
CreateText();
- m_sizerText->SetMinSize(250, 0);
+ m_sizerText->SetMinSize(150, 0);
// the 3 panes panes compose the upper part of the window
wxSizer *sizerTop = new wxBoxSizer(wxHORIZONTAL);
{
CreateText();
}
-
+#endif
);
m_lboxLog = new wxListBox(m_panel, -1);
sizerDown->Add(m_lboxLog, 1, wxGROW | wxALL, 5);
- sizerDown->SetMinSize(100, 200);
+ sizerDown->SetMinSize(100, 150);
wxBoxSizer *sizerBtns = new wxBoxSizer(wxHORIZONTAL);
wxButton *btn = new wxButton(m_panel, Widgets_ClearLog, _T("Clear &log"));