by wxStatusBar::SetStatusWidths().}
@row3col{styles, @ref overview_xrcformat_type_string,
Comma-separated list of @em fields flags. Each value specifies status bar
- fieldd style and can be one of @c wxSB_NORMAL, @c wxSB_FLAT or
- @c wxSB_RAISED. See wxStatusBar::SetStatusStyles() for their description.}
+ fieldd style and can be one of @c wxSB_NORMAL, @c wxSB_FLAT,
+ @c wxSB_RAISED or, since wxWidgets 2.9.5, @c wxSB_SUNKEN. See
+ wxStatusBar::SetStatusStyles() for their description.}
@endTable
#define wxSB_NORMAL 0x0000
#define wxSB_FLAT 0x0001
#define wxSB_RAISED 0x0002
+#define wxSB_SUNKEN 0x0003
// ----------------------------------------------------------------------------
// wxStatusBarPane: an helper for wxStatusBar
// field styles
// ------------
- // Set the field style. Use either wxSB_NORMAL (default) for a standard 3D
- // border around a field, wxSB_FLAT for no border around a field, so that it
- // appears flat or wxSB_POPOUT to make the field appear raised.
- // Setting field styles only works on wxMSW
+ // Set the field border style to one of wxSB_XXX values.
virtual void SetStatusStyles(int n, const int styles[]);
int GetStatusStyle(int n) const
#define wxSB_NORMAL 0x0000
#define wxSB_FLAT 0x0001
#define wxSB_RAISED 0x0002
+#define wxSB_SUNKEN 0x0003
/**
number passed to SetFieldsCount() the last time it was called.
@param styles
Contains an array of @a n integers with the styles for each field.
- There are three possible styles:
- - @c wxSB_NORMAL (default): The field appears sunken with a standard 3D border.
+ There are four possible styles:
+ - @c wxSB_NORMAL (default): The field appears with the default native border.
- @c wxSB_FLAT: No border is painted around the field so that it appears flat.
- @c wxSB_RAISED: A raised 3D border is painted around the field.
+ - @c wxSB_SUNKEN: A sunken 3D border is painted around the field
+ (this style is new since wxWidgets 2.9.5).
*/
virtual void SetStatusStyles(int n, const int* styles);
StatusBar_SetPaneStyleNormal,
StatusBar_SetPaneStyleFlat,
StatusBar_SetPaneStyleRaised,
+ StatusBar_SetPaneStyleSunken,
StatusBar_SetStyleSizeGrip,
StatusBar_SetStyleEllipsizeStart,
EVT_MENU(StatusBar_SetPaneStyleNormal, MyFrame::OnSetPaneStyle)
EVT_MENU(StatusBar_SetPaneStyleFlat, MyFrame::OnSetPaneStyle)
EVT_MENU(StatusBar_SetPaneStyleRaised, MyFrame::OnSetPaneStyle)
+ EVT_MENU(StatusBar_SetPaneStyleSunken, MyFrame::OnSetPaneStyle)
EVT_MENU(StatusBar_SetStyleSizeGrip, MyFrame::OnSetStyle)
EVT_MENU(StatusBar_SetStyleEllipsizeStart, MyFrame::OnSetStyle)
MyFrame::OnUpdateForDefaultStatusbar)
EVT_UPDATE_UI(StatusBar_Toggle, MyFrame::OnUpdateStatusBarToggle)
EVT_UPDATE_UI_RANGE(StatusBar_SetPaneStyleNormal,
- StatusBar_SetPaneStyleRaised,
+ StatusBar_SetPaneStyleSunken,
MyFrame::OnUpdateSetPaneStyle)
EVT_UPDATE_UI_RANGE(StatusBar_SetStyleSizeGrip, StatusBar_SetStyleShowTips,
MyFrame::OnUpdateSetStyle)
wxT("&Raised"),
wxT("Sets the style of the first field to raised look")
);
+ statbarPaneStyleMenu->AppendCheckItem
+ (
+ StatusBar_SetPaneStyleSunken,
+ wxT("&Sunken"),
+ wxT("Sets the style of the first field to sunken look")
+ );
statbarMenu->Append(StatusBar_SetPaneStyle, wxT("Field style"),
statbarPaneStyleMenu);
case StatusBar_SetPaneStyleRaised:
event.Check(m_statbarPaneStyle == wxSB_RAISED);
break;
+ case StatusBar_SetPaneStyleSunken:
+ event.Check(m_statbarPaneStyle == wxSB_SUNKEN);
+ break;
}
}
case StatusBar_SetPaneStyleRaised:
m_statbarPaneStyle = wxSB_RAISED;
break;
+ case StatusBar_SetPaneStyleSunken:
+ m_statbarPaneStyle = wxSB_SUNKEN;
+ break;
}
ApplyPaneStyle();
return; // happens when the status bar is shrunk in a very small area!
int style = m_panes[i].GetStyle();
- if (style != wxSB_FLAT)
+ if (style == wxSB_RAISED || style == wxSB_SUNKEN)
{
// Draw border
- // For wxSB_NORMAL: paint a grey background, plus 3-d border (one black rectangle)
+ // For wxSB_SUNKEN: paint a grey background, plus 3-d border (one black rectangle)
// Inside this, left and top sides (dark grey). Bottom and right (white).
// Reverse it for wxSB_RAISED
style = SBT_NOBORDERS;
break;
+ case wxSB_SUNKEN:
case wxSB_NORMAL:
default:
style = 0;
case wxSB_FLAT:
style = SBT_NOBORDERS;
break;
+ case wxSB_SUNKEN:
case wxSB_NORMAL:
default:
style = 0;
style[i] = wxSB_FLAT;
else if (first == wxT("wxSB_RAISED"))
style[i] = wxSB_RAISED;
+ else if (first == wxT("wxSB_SUNKEN"))
+ style[i] = wxSB_SUNKEN;
else if (!first.empty())
{
ReportParamError