15PANEL_TEMPLATE_FIELDNAMES_BASE::PANEL_TEMPLATE_FIELDNAMES_BASE( wxWindow* parent, wxWindowID
id,
const wxPoint& pos,
const wxSize& size,
long style,
const wxString&
name ) : wxPanel( parent, id, pos, size, style,
name )
17 wxBoxSizer* bPanelSizer;
18 bPanelSizer =
new wxBoxSizer( wxVERTICAL );
20 m_title =
new wxStaticText(
this, wxID_ANY,
_(
"Field name templates:"), wxDefaultPosition, wxDefaultSize, 0 );
22 bPanelSizer->Add(
m_title, 0, wxTOP|wxLEFT|wxEXPAND, 8 );
25 bPanelSizer->Add( 0, 3, 0, wxEXPAND, 5 );
27 m_grid =
new WX_GRID(
this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
30 m_grid->CreateGrid( 0, 3 );
31 m_grid->EnableEditing(
true );
32 m_grid->EnableGridLines(
true );
33 m_grid->EnableDragGridSize(
false );
34 m_grid->SetMargins( 0, 0 );
37 m_grid->SetColSize( 0, 300 );
38 m_grid->SetColSize( 1, 60 );
39 m_grid->SetColSize( 2, 60 );
40 m_grid->EnableDragColMove(
false );
41 m_grid->EnableDragColSize(
true );
42 m_grid->SetColLabelValue( 0,
_(
"Name") );
43 m_grid->SetColLabelValue( 1,
_(
"Visible") );
44 m_grid->SetColLabelValue( 2,
_(
"URL") );
46 m_grid->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
49 m_grid->EnableDragRowSize(
true );
50 m_grid->SetRowLabelSize( 0 );
51 m_grid->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
56 m_grid->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_CENTER );
57 m_grid->SetMinSize( wxSize( -1,180 ) );
59 bPanelSizer->Add(
m_grid, 1, wxEXPAND|wxRIGHT, 5 );
62 bSizer10 =
new wxBoxSizer( wxHORIZONTAL );
68 bSizer10->Add( 20, 0, 0, wxEXPAND, 5 );
74 bPanelSizer->Add( bSizer10, 0, wxEXPAND, 10 );
77 this->SetSizer( bPanelSizer );
79 bPanelSizer->Fit(
this );
STD_BITMAP_BUTTON * m_addFieldButton
virtual void OnAddButtonClick(wxCommandEvent &event)
virtual void OnSizeGrid(wxSizeEvent &event)
~PANEL_TEMPLATE_FIELDNAMES_BASE()
virtual void OnDeleteButtonClick(wxCommandEvent &event)
STD_BITMAP_BUTTON * m_deleteFieldButton
PANEL_TEMPLATE_FIELDNAMES_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
void SetColLabelSize(int aHeight)
Hide wxGrid's SetColLabelSize() method with one which makes sure the size is tall enough for the syst...