12DIALOG_SIM_FORMAT_VALUE_BASE::DIALOG_SIM_FORMAT_VALUE_BASE( wxWindow* parent, wxWindowID
id,
const wxString& title,
const wxPoint& pos,
const wxSize& size,
long style ) :
DIALOG_SHIM( parent, id, title, pos, size, style )
14 this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
16 wxBoxSizer* bMainSizer;
17 bMainSizer =
new wxBoxSizer( wxVERTICAL );
19 wxFlexGridSizer* fgSizer;
20 fgSizer =
new wxFlexGridSizer( 3, 2, 8, 0 );
21 fgSizer->AddGrowableCol( 1 );
22 fgSizer->SetFlexibleDirection( wxBOTH );
23 fgSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
25 m_precisionLabel =
new wxStaticText(
this, wxID_ANY,
_(
"Significant digits:"), wxDefaultPosition, wxDefaultSize, 0 );
29 m_precisionCtrl =
new wxSpinCtrl(
this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS, 1, 9, 3 );
30 fgSizer->Add(
m_precisionCtrl, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 );
32 m_rangeLabel =
new wxStaticText(
this, wxID_ANY,
_(
"Range:"), wxDefaultPosition, wxDefaultSize, 0 );
34 fgSizer->Add(
m_rangeLabel, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
36 wxString m_rangeCtrlChoices[] = {
_(
"Auto"),
_(
"f"),
_(
"p"),
_(
"n"),
_(
"u"),
_(
"m"), wxEmptyString,
_(
"K"),
_(
"M"),
_(
"G"),
_(
"T"),
_(
"P") };
37 int m_rangeCtrlNChoices =
sizeof( m_rangeCtrlChoices ) /
sizeof( wxString );
38 m_rangeCtrl =
new wxChoice(
this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_rangeCtrlNChoices, m_rangeCtrlChoices, 0 );
40 fgSizer->Add(
m_rangeCtrl, 0, wxEXPAND|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL, 5 );
43 fgSizer->Add( 0, 0, 1, wxEXPAND, 5 );
46 bMainSizer->Add( fgSizer, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 10 );
48 wxBoxSizer* bBottomSizer;
49 bBottomSizer =
new wxBoxSizer( wxHORIZONTAL );
52 bBottomSizer->Add( 50, 0, 1, wxEXPAND, 5 );
61 bBottomSizer->Add(
m_sdbSizer1, 0, wxEXPAND|wxALL, 5 );
64 bMainSizer->Add( bBottomSizer, 0, wxEXPAND, 5 );
67 this->SetSizer( bMainSizer );
69 bMainSizer->Fit(
this );
71 this->Centre( wxBOTH );
Dialog helper object to sit in the inheritance tree between wxDialog and any class written by wxFormB...