+ wxString smax('9', m_textMax->GetValue().length());
+ wxSize
+ size = m_spinctrl->GetSizeFromTextSize(m_spinctrl->GetTextExtent(smax));
+
+ m_spinctrl->SetMinSize(size);
+ m_spinctrl->SetSize(size);
+
+ smax += ".0";
+ size = m_spinctrldbl->GetSizeFromTextSize(
+ m_spinctrldbl->GetTextExtent(smax)
+ );
+ m_spinctrldbl->SetMinSize(size);
+ m_spinctrldbl->SetSize(size);