- m_selectedButton = -1;
- m_noRowsOrCols = 0;
- m_noItems = n;
-
- SetName(name);
- SetValidator(val);
-
- parent->AddChild(this);
- m_backgroundColour = parent->GetDefaultBackgroundColour() ;
- m_foregroundColour = parent->GetDefaultForegroundColour() ;
-
- m_windowStyle = (long&)style;
-
- int x = pos.x;
- int y = pos.y;
- int width = size.x;
- int height = size.y;
-
- if (id == -1)
- m_windowId = NewControlId();
- else
- m_windowId = id;
-
-
- m_noRowsOrCols = majorDim;
- if (majorDim==0)
- m_majorDim = n ;
- m_majorDim = majorDim ;
- HWND the_handle ;
-
- long msStyle = GROUP_FLAGS;
-
- bool want3D;
- WXDWORD exStyle = Determine3DEffects(0, &want3D) ;
- // Even with extended styles, need to combine with WS_BORDER
- // for them to look right.
- if (want3D && ((m_windowStyle & wxSIMPLE_BORDER) || (m_windowStyle & wxRAISED_BORDER) ||
- (m_windowStyle & wxSUNKEN_BORDER) || (m_windowStyle & wxDOUBLE_BORDER)))
- msStyle |= WS_BORDER;
-
- m_hWnd = (WXHWND) CreateWindowEx((DWORD) exStyle, GROUP_CLASS, (title == "" ? NULL : (const char *)title),
- msStyle,
- 0,0,0,0,
- (HWND) parent->GetHWND(), (HMENU) m_windowId, wxGetInstance(), NULL) ;
-
-/*
- if (labelFont)
- {
- labelFont->RealizeResource();
- if (labelFont->GetResourceHandle())
- SendMessage(ms_handle,WM_SETFONT,
- (WPARAM)labelFont->GetResourceHandle(),0L);
- }
-*/
- the_handle = (HWND) parent->GetHWND();
+ m_selectedButton = -1;
+ m_noRowsOrCols = 0;
+ m_noItems = n;
+
+ SetName(name);
+ SetValidator(val);
+
+ parent->AddChild(this);
+ m_backgroundColour = parent->GetBackgroundColour() ;
+ m_foregroundColour = parent->GetForegroundColour() ;
+
+ m_windowStyle = (long&)style;
+
+ int x = pos.x;
+ int y = pos.y;
+ int width = size.x;
+ int height = size.y;
+
+ if (id == -1)
+ m_windowId = NewControlId();
+ else
+ m_windowId = id;
+
+
+ m_noRowsOrCols = majorDim;
+ if (majorDim==0)
+ m_majorDim = n ;
+ m_majorDim = majorDim ;
+ HWND the_handle ;
+
+ long msStyle = GROUP_FLAGS;
+
+ bool want3D;
+ WXDWORD exStyle = Determine3DEffects(0, &want3D) ;
+ // Even with extended styles, need to combine with WS_BORDER
+ // for them to look right.
+ if ( want3D || wxStyleHasBorder(m_windowStyle) )
+ msStyle |= WS_BORDER;
+
+ m_hWnd = (WXHWND) CreateWindowEx((DWORD) exStyle, GROUP_CLASS, (title == "" ? NULL : (const char *)title),
+ msStyle,
+ 0,0,0,0,
+ (HWND) parent->GetHWND(), (HMENU) m_windowId, wxGetInstance(), NULL) ;
+
+ the_handle = (HWND) parent->GetHWND();