]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/statbox.cpp
Better #if checks for mac in ProcessPlatformProperty
[wxWidgets.git] / src / motif / statbox.cpp
index c7c8dd099ae0872da09259e0d487bec6b0f08a79..0c3d210a5e638aa101da81d47e77dfcb2649e75b 100644 (file)
@@ -9,7 +9,7 @@
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
-#ifdef __GNUG__
+#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
 #pragma implementation "statbox.h"
 #endif
 
@@ -105,13 +105,13 @@ bool wxStaticBox::Create(wxWindow *parent, wxWindowID id,
     bool hasLabel = (!label.IsNull() && !label.IsEmpty()) ;
     if (hasLabel)
     {
-        XmFontList fontList = (XmFontList) m_font.GetFontList(1.0, XtDisplay( parentWidget ) );
+        WXFontType fontType = m_font.GetFontType( XtDisplay( parentWidget ) );
         wxString label1(wxStripMenuCodes(label));
         wxXmString text(label1);
 
         m_labelWidget = (WXWidget) XtVaCreateManagedWidget ("staticboxlabel",
                 xmLabelWidgetClass, (Widget)m_mainWidget,
-                XmNfontList, fontList,
+                wxFont::GetFontTag(), fontType,                
                 XmNlabelString, text(),
 #if wxCHECK_MOTIF_VERSION( 2, 0 )
                 XmNframeChildType, XmFRAME_TITLE_CHILD,
@@ -121,7 +121,6 @@ bool wxStaticBox::Create(wxWindow *parent, wxWindowID id,
                 NULL);
     }
     
-    SetCanAddEventHandler(TRUE);
     AttachWidget (parent, m_mainWidget, NULL, pos.x, pos.y, size.x, size.y);
     ChangeBackgroundColour();