X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f37907ff76827b0f77f61448abfd0acabf029843..28169f14ec80f07874464412c72d7523a7768d81:/src/motif/radiobut.cpp?ds=inline diff --git a/src/motif/radiobut.cpp b/src/motif/radiobut.cpp index 46906f1a93..87c20587a9 100644 --- a/src/motif/radiobut.cpp +++ b/src/motif/radiobut.cpp @@ -72,9 +72,9 @@ bool wxRadioButton::Create(wxWindow *parent, wxWindowID id, wxString label1(wxStripMenuCodes(label)); - XmString text = XmStringCreateSimple ((char*) (const char*) label1); + wxXmString text( label1 ); - XmFontList fontList = (XmFontList) m_font.GetFontList(1.0, XtDisplay(parentWidget)); + WXFontType fontType = m_font.GetFontType(XtDisplay(parentWidget)); Widget radioButtonWidget = XtVaCreateManagedWidget ("toggle", #if wxUSE_GADGETS @@ -82,12 +82,11 @@ bool wxRadioButton::Create(wxWindow *parent, wxWindowID id, #else xmToggleButtonWidgetClass, parentWidget, #endif - XmNfontList, fontList, - XmNlabelString, text, + wxFont::GetFontTag(), fontType, + XmNlabelString, text(), XmNfillOnSelect, True, XmNindicatorType, XmONE_OF_MANY, // diamond-shape NULL); - XmStringFree (text); XtAddCallback (radioButtonWidget, XmNvalueChangedCallback, (XtCallbackProc) wxRadioButtonCallback, (XtPointer) this); @@ -96,7 +95,6 @@ bool wxRadioButton::Create(wxWindow *parent, wxWindowID id, XtManageChild (radioButtonWidget); - SetCanAddEventHandler(TRUE); AttachWidget (parent, m_mainWidget, (WXWidget) NULL, pos.x, pos.y, size.x, size.y); ChangeBackgroundColour();