NumeRe v1.1.4
NumeRe: Framework für Numerische Rechnungen
GroupPanel Class Reference

This class simplifies the creation of simple windows and creates a common layout among all windows. More...

#include <grouppanel.hpp>

Inheritance diagram for GroupPanel:
Collaboration diagram for GroupPanel:

Public Member Functions

 GroupPanel (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, bool useVerticalSizer=true)
 Constructor. More...
 
wxBoxSizer * getVerticalSizer ()
 Return the pointer to the vertical sizer. More...
 
wxBoxSizer * getHorizontalSizer ()
 Return the pointer to the horizontal sizer. More...
 
wxBoxSizer * getMainSizer ()
 Return the pointer to the current main layout sizer. More...
 
void AddSpacer (int nSize=10, wxSizer *sizer=nullptr)
 Add extra space between the last added (main) element and the next element to be added. More...
 
wxStaticText * AddStaticText (wxWindow *parent, wxSizer *sizer, const wxString &text, int id=wxID_STATIC, int alignment=wxALIGN_CENTER_VERTICAL)
 Add some static test to the current sizer and window. More...
 
wxStaticBoxSizer * createGroup (const wxString &sGroupName, int orient=wxVERTICAL, wxWindow *parent=nullptr, wxSizer *sizer=nullptr, int expand=0)
 Member function to create a group (a static box with a label) in the panel. More...
 
wxBoxSizer * createGroup (int orient=wxVERTICAL, wxSizer *sizer=nullptr, int expand=0)
 Member function to create a group represented as a box sizer. More...
 
wxCollapsiblePane * createCollapsibleGroup (const wxString &label, wxWindow *parent=nullptr, wxSizer *sizer=nullptr)
 Member function to create a collapsible group. More...
 
wxTextCtrl * CreatePathInput (wxWindow *parent, wxSizer *sizer, const wxString &description, int buttonID, int id=wxID_ANY)
 This member function creates the layout for a path input dialog including the "choose" button. More...
 
TextFieldCreateTextInput (wxWindow *parent, wxSizer *sizer, const wxString &description, const wxString &sDefault=wxEmptyString, int nStyle=0, int id=wxID_ANY, const wxSize &size=wxSize(310,-1), int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a text input. More...
 
wxCheckBox * CreateCheckBox (wxWindow *parent, wxSizer *sizer, const wxString &description, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a usual checkbox. More...
 
SpinButCreateSpinControl (wxWindow *parent, wxSizer *sizer, const wxString &description, int nMin, int nMax, int nInitial, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a spin control including the assigned text. More...
 
wxListView * CreateListView (wxWindow *parent, wxSizer *sizer, int nStyle=wxLC_REPORT, wxSize size=wxDefaultSize, int id=wxID_ANY)
 This member function creates the layout for a listview control. More...
 
wxTreeListCtrlCreateTreeListCtrl (wxWindow *parent, wxSizer *sizer, int nStyle=wxTL_SINGLE, wxSize size=wxDefaultSize, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a treelist control. More...
 
wxcode::wxTreeListCtrl * CreateWxcTreeListCtrl (wxWindow *parent, wxSizer *sizer, int nStyle=wxTR_TWIST_BUTTONS|wxTR_FULL_ROW_HIGHLIGHT|wxTR_EXTENDED, wxSize size=wxDefaultSize, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a treelist control in the wxCode variant. More...
 
wxButton * CreateButton (wxWindow *parent, wxSizer *sizer, const wxString &description, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a button. More...
 
wxRadioBox * CreateRadioBox (wxWindow *parent, wxSizer *sizer, const wxString &description, const wxArrayString &choices, int style=wxHORIZONTAL, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a radio box. More...
 
wxChoice * CreateChoices (wxWindow *parent, wxSizer *sizer, const wxArrayString &choices, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a dropdown list. More...
 
wxComboBox * CreateComboBox (wxWindow *parent, wxSizer *sizer, const wxArrayString &choices, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a combobox. More...
 
wxGauge * CreateGauge (wxWindow *parent, wxSizer *sizer, int style, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a progress bar. More...
 
wxStaticBitmap * CreateBitmap (wxWindow *parent, wxSizer *sizer, const wxString &filename, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a static bitmap. More...
 
wxSlider * CreateSlider (wxWindow *parent, wxSizer *sizer, int nMin, int nMax, int nInitial, int style, int id=wxID_ANY, int alignment=wxALIGN_CENTER_VERTICAL)
 This member function creates the layout for a slider. More...
 

Private Attributes

wxBoxSizer * verticalSizer
 
wxBoxSizer * horizontalSizer
 
wxBoxSizer * mainSizer
 

Detailed Description

This class simplifies the creation of simple windows and creates a common layout among all windows.

Definition at line 187 of file grouppanel.hpp.

Constructor & Destructor Documentation

◆ GroupPanel()

GroupPanel::GroupPanel ( wxWindow *  parent,
wxWindowID  id = wxID_ANY,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxDefaultSize,
long  style = wxTAB_TRAVERSAL,
bool  useVerticalSizer = true 
)

Constructor.

Parameters
parentwxWindow*
idwxWindowID
posconst wxPoint&
sizeconst wxSize&
stylelong

Definition at line 35 of file grouppanel.cpp.

References horizontalSizer, mainSizer, and verticalSizer.

Member Function Documentation

◆ AddSpacer()

void GroupPanel::AddSpacer ( int  nSize = 10,
wxSizer *  sizer = nullptr 
)

Add extra space between the last added (main) element and the next element to be added.

Parameters
nSizeint
sizerwxSizer*
Returns
void

Definition at line 120 of file grouppanel.cpp.

References mainSizer.

Referenced by CustomWindow::layoutChild(), and RenameSymbolsDialog::RenameSymbolsDialog().

◆ AddStaticText()

wxStaticText * GroupPanel::AddStaticText ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  text,
int  id = wxID_STATIC,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

Add some static test to the current sizer and window.

Parameters
parentwxWindow*
sizerwxSizer*
textconst wxString&
idint
Returns
wxStaticText*

Definition at line 140 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CellValueShaderDialog::createIntervalExclPage(), CellValueShaderDialog::createIntervalPage(), CellValueShaderDialog::createLtGtPage(), CustomWindow::layoutChild(), and PackageRepoBrowser::PackageRepoBrowser().

◆ CreateBitmap()

wxStaticBitmap * GroupPanel::CreateBitmap ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  filename,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a static bitmap.

Parameters
parentwxWindow*
sizerwxSizer*
filenameconst wxString&
idint
alignmentint
Returns
wxStaticBitmap*

Definition at line 566 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CustomWindow::layoutChild().

◆ CreateButton()

wxButton * GroupPanel::CreateButton ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  description,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a button.

Parameters
parentwxWindow*
sizerwxSizer*
descriptionconst wxString&
idint
alignmentint
Returns
wxButton*

Definition at line 447 of file grouppanel.cpp.

References ELEMENT_BORDER, and mainSizer.

Referenced by CustomWindow::layoutChild(), PackageDialog::PackageDialog(), and PackageRepoBrowser::PackageRepoBrowser().

◆ CreateCheckBox()

wxCheckBox * GroupPanel::CreateCheckBox ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  description,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

◆ CreateChoices()

wxChoice * GroupPanel::CreateChoices ( wxWindow *  parent,
wxSizer *  sizer,
const wxArrayString &  choices,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a dropdown list.

Parameters
parentwxWindow*
wxSizer*sizer
choicesconst wxArrayString&
idint
alignmentint
Returns
wxChoice*

Definition at line 495 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CellValueShaderDialog::createLtGtPage(), and CustomWindow::layoutChild().

◆ createCollapsibleGroup()

wxCollapsiblePane * GroupPanel::createCollapsibleGroup ( const wxString &  label,
wxWindow *  parent = nullptr,
wxSizer *  sizer = nullptr 
)

Member function to create a collapsible group.

Parameters
labelconst wxString&
parentwxWindow*
sizerwxSizer*
Returns
wxCollapsiblePane*
Warning
This group is currently quite buggy.

Definition at line 215 of file grouppanel.cpp.

References mainSizer.

Referenced by CustomWindow::layoutChild().

◆ CreateComboBox()

wxComboBox * GroupPanel::CreateComboBox ( wxWindow *  parent,
wxSizer *  sizer,
const wxArrayString &  choices,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a combobox.

Parameters
parentwxWindow*
wxSizer*sizer
choicesconst wxArrayString&
idint
alignmentint
Returns
wxComboBox*

Definition at line 520 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CustomWindow::layoutChild().

◆ CreateGauge()

wxGauge * GroupPanel::CreateGauge ( wxWindow *  parent,
wxSizer *  sizer,
int  style,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a progress bar.

Parameters
parentwxWindow*
wxSizer*sizer
styleint
idint
alignmentint
Returns
wxGauge*

Definition at line 545 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CustomWindow::layoutChild(), and PackageRepoBrowser::PackageRepoBrowser().

◆ createGroup() [1/2]

wxStaticBoxSizer * GroupPanel::createGroup ( const wxString &  sGroupName,
int  orient = wxVERTICAL,
wxWindow *  parent = nullptr,
wxSizer *  sizer = nullptr,
int  expand = 0 
)

◆ createGroup() [2/2]

wxBoxSizer * GroupPanel::createGroup ( int  orient = wxVERTICAL,
wxSizer *  sizer = nullptr,
int  expand = 0 
)

Member function to create a group represented as a box sizer.

Parameters
orientint
sizerwxSizer*
expandint
Returns
wxBoxSizer*

Definition at line 189 of file grouppanel.cpp.

References mainSizer.

◆ CreateListView()

wxListView * GroupPanel::CreateListView ( wxWindow *  parent,
wxSizer *  sizer,
int  nStyle = wxLC_REPORT,
wxSize  size = wxDefaultSize,
int  id = wxID_ANY 
)

This member function creates the layout for a listview control.

Parameters
parentwxWindow*
sizerwxSizer*
wxLC_REPORTint nStyle=
wxDefaultSizewxSize size=
idint
Returns
wxListView*

Definition at line 376 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by PackageDialog::PackageDialog(), and RenameSymbolsDialog::RenameSymbolsDialog().

◆ CreatePathInput()

wxTextCtrl * GroupPanel::CreatePathInput ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  description,
int  buttonID,
int  id = wxID_ANY 
)

This member function creates the layout for a path input dialog including the "choose" button.

Parameters
parentwxWindow*
sizerwxSizer*
descriptionconst wxString&
buttonIDint
idint
Returns
wxTextCtrl*

Definition at line 245 of file grouppanel.cpp.

References _guilang, ELEMENT_BORDER, and Language::get().

Referenced by OptionsDialog::CreatePathPage().

Here is the call graph for this function:

◆ CreateRadioBox()

wxRadioBox * GroupPanel::CreateRadioBox ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  description,
const wxArrayString &  choices,
int  style = wxHORIZONTAL,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a radio box.

Parameters
parentwxWindow*
sizerwxSizer*
descriptionconst wxString&
choicesconst wxArrayString&
styleint
idint
alignmentint
Returns
wxRadioBox*

Definition at line 474 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CustomWindow::layoutChild().

◆ CreateSlider()

wxSlider * GroupPanel::CreateSlider ( wxWindow *  parent,
wxSizer *  sizer,
int  nMin,
int  nMax,
int  nInitial,
int  style,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a slider.

Parameters
parentwxWindow*
sizerwxSizer*
nMinint
nMaxint
nInitialint
styleint
idint
alignmentint
Returns
wxSlider*

Definition at line 590 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CustomWindow::layoutChild().

◆ CreateSpinControl()

SpinBut * GroupPanel::CreateSpinControl ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  description,
int  nMin,
int  nMax,
int  nInitial,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a spin control including the assigned text.

Parameters
parentwxWindow*
sizerwxSizer*
descriptionconst wxString&
nMinint
nMaxint
nInitialint
idint
alignmentint
Returns
SpinBut*

Definition at line 342 of file grouppanel.cpp.

References ELEMENT_BORDER, and SpinBut::m_label.

Referenced by OptionsDialog::CreateConfigPage(), OptionsDialog::CreateDebuggerPage(), OptionsDialog::CreateEditorPage(), OptionsDialog::CreateMiscPage(), and CustomWindow::layoutChild().

◆ CreateTextInput()

TextField * GroupPanel::CreateTextInput ( wxWindow *  parent,
wxSizer *  sizer,
const wxString &  description,
const wxString &  sDefault = wxEmptyString,
int  nStyle = 0,
int  id = wxID_ANY,
const wxSize &  size = wxSize(310,-1),
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a text input.

Parameters
parentwxWindow*
sizerwxSizer*
descriptionconst wxString&
sDefaultconst wxString&
nStyleint
idint
sizeconst wxSize&
alignmentint
Returns
TextField*

Definition at line 285 of file grouppanel.cpp.

References ELEMENT_BORDER, and TextField::m_label.

Referenced by CellValueShaderDialog::createIntervalExclPage(), CellValueShaderDialog::createIntervalPage(), CellValueShaderDialog::createLtGtPage(), CustomWindow::layoutChild(), and RenameSymbolsDialog::RenameSymbolsDialog().

◆ CreateTreeListCtrl()

wxTreeListCtrl * GroupPanel::CreateTreeListCtrl ( wxWindow *  parent,
wxSizer *  sizer,
int  nStyle = wxTL_SINGLE,
wxSize  size = wxDefaultSize,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a treelist control.

Parameters
parentwxWindow*
sizerwxSizer*
nStyleint
sizewxSize
idint
alignmentint
Returns
wxTreeListCtrl*

Definition at line 399 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by CustomWindow::layoutChild().

◆ CreateWxcTreeListCtrl()

wxcode::wxTreeListCtrl * GroupPanel::CreateWxcTreeListCtrl ( wxWindow *  parent,
wxSizer *  sizer,
int  nStyle = wxTR_TWIST_BUTTONS | wxTR_FULL_ROW_HIGHLIGHT | wxTR_EXTENDED,
wxSize  size = wxDefaultSize,
int  id = wxID_ANY,
int  alignment = wxALIGN_CENTER_VERTICAL 
)

This member function creates the layout for a treelist control in the wxCode variant.

Parameters
parentwxWindow*
sizerwxSizer*
nStyleint
sizewxSize
idint
alignmentint
Returns
wxcode::wxTreeListCtrl*

Definition at line 424 of file grouppanel.cpp.

References ELEMENT_BORDER.

Referenced by PackageRepoBrowser::PackageRepoBrowser().

◆ getHorizontalSizer()

wxBoxSizer * GroupPanel::getHorizontalSizer ( )

Return the pointer to the horizontal sizer.

Returns
wxBoxSizer*

Definition at line 91 of file grouppanel.cpp.

References horizontalSizer.

◆ getMainSizer()

wxBoxSizer * GroupPanel::getMainSizer ( )

◆ getVerticalSizer()

wxBoxSizer * GroupPanel::getVerticalSizer ( )

Return the pointer to the vertical sizer.

Returns
wxBoxSizer*

Definition at line 78 of file grouppanel.cpp.

References verticalSizer.

Referenced by OptionsDialog::CreateDebuggerPage(), OptionsDialog::CreateMiscPage(), and RenameSymbolsDialog::RenameSymbolsDialog().

Member Data Documentation

◆ horizontalSizer

wxBoxSizer* GroupPanel::horizontalSizer
private

Definition at line 191 of file grouppanel.hpp.

Referenced by getHorizontalSizer(), and GroupPanel().

◆ mainSizer

wxBoxSizer* GroupPanel::mainSizer
private

◆ verticalSizer

wxBoxSizer* GroupPanel::verticalSizer
private

Definition at line 190 of file grouppanel.hpp.

Referenced by getVerticalSizer(), and GroupPanel().


The documentation for this class was generated from the following files: