add alignment flags support to wxSpinCtrl[Double] (closes #10621)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59719 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2009-03-22 09:18:46 +00:00
parent 0e5bf041b0
commit 7e4952db83
11 changed files with 98 additions and 26 deletions

View File

@@ -118,6 +118,16 @@ bool wxSpinCtrlGTKBase::Create(wxWindow *parent, wxWindowID id,
gtk_spin_button_set_value( GTK_SPIN_BUTTON(m_widget), initial);
m_value = gtk_spin_button_get_value( GTK_SPIN_BUTTON(m_widget));
gfloat align;
if ( HasFlag(wxTE_RIGHT) )
align = 1.0;
else if ( HasFlag(wxTE_CENTRE) )
align = 0.5;
else
align = 0.0;
gtk_entry_set_alignment(GTK_ENTRY(m_widget), align);
gtk_spin_button_set_wrap( GTK_SPIN_BUTTON(m_widget),
(int)(m_windowStyle & wxSP_WRAP) );