+void wxRadioBox::ChangeFont(bool keepOriginalSize)
+{
+ wxWindow::ChangeFont(keepOriginalSize);
+
+ XmFontList fontList = (XmFontList) m_font.GetFontList(1.0, XtDisplay((Widget) GetTopWidget()));
+
+ int i;
+ for (i = 0; i < m_noItems; i++)
+ {
+ WXWidget radioButton = m_radioButtons[i];
+
+ XtVaSetValues ((Widget) radioButton,
+ XmNfontList, fontList,
+ XmNtopAttachment, XmATTACH_FORM,
+ NULL);
+ }
+}
+
+void wxRadioBox::ChangeBackgroundColour()
+{
+ wxWindow::ChangeBackgroundColour();
+
+ DoChangeBackgroundColour((Widget) m_frameWidget, m_backgroundColour);
+
+ int selectPixel = wxBLACK->AllocColour(wxGetDisplay());
+
+ int i;
+ for (i = 0; i < m_noItems; i++)
+ {
+ WXWidget radioButton = m_radioButtons[i];
+
+ DoChangeBackgroundColour(radioButton, m_backgroundColour, TRUE);
+
+ XtVaSetValues ((Widget) radioButton,
+ XmNselectColor, selectPixel,
+ NULL);
+ }
+}
+
+void wxRadioBox::ChangeForegroundColour()
+{
+ wxWindow::ChangeForegroundColour();
+
+ int i;
+ for (i = 0; i < m_noItems; i++)
+ {
+ WXWidget radioButton = m_radioButtons[i];
+
+ DoChangeForegroundColour(radioButton, m_foregroundColour);
+ }
+}
+
+static int CalcOtherDim( int items, int dim )
+{
+ return items / dim + ( items % dim ? 1 : 0 );
+}
+
+int wxRadioBox::GetRowCount() const
+{
+ return m_windowStyle & wxRA_SPECIFY_ROWS ? m_noRowsOrCols
+ : CalcOtherDim( GetCount(), m_noRowsOrCols );
+}
+
+int wxRadioBox::GetColumnCount() const
+{
+ return m_windowStyle & wxRA_SPECIFY_COLS ? m_noRowsOrCols
+ : CalcOtherDim( GetCount(), m_noRowsOrCols );
+}
+