.TH wxStatusBar 3erl "wx 2.2.2.1" "wxWidgets team." "Erlang Module Definition" .SH NAME wxStatusBar \- Functions for wxStatusBar class .SH DESCRIPTION .LP A status bar is a narrow window that can be placed along the bottom of a frame to give small amounts of status information\&. It can contain one or more fields, one or more of which can be variable length according to the size of the window\&. .LP \fIwxStatusBar\fR\& also maintains an independent stack of status texts for each field (see \fIpushStatusText/3\fR\& and \fIpopStatusText/2\fR\&)\&. .LP Note that in \fIwxStatusBar\fR\& context, the terms \fIpane\fR\& and \fIfield\fR\& are synonyms\&. .LP Styles .LP This class supports the following styles: .LP Remark: It is possible to create controls and other windows on the status bar\&. Position these windows from an OnSize() event handler\&. .LP Remark: Notice that only the first 127 characters of a string will be shown in status bar fields under Windows if a proper manifest indicating that the program uses version 6 of common controls library is not used\&. This is a limitation of the native control on these platforms\&. .LP See: \fIwxStatusBarPane\fR\& (not implemented in wx), \fIwxFrame\fR\&, Examples .LP This class is derived (and can use functions) from: \fIwxWindow\fR\& \fIwxEvtHandler\fR\& .LP wxWidgets docs: wxStatusBar .SH DATA TYPES .nf \fBwxStatusBar()\fR\& = wx:wx_object() .br .fi .SH EXPORTS .LP .nf .B new() -> wxStatusBar() .br .fi .br .RS .LP Default ctor\&. .RE .LP .nf .B new(Parent) -> wxStatusBar() .br .fi .br .RS .LP Types: .RS 3 Parent = wxWindow:wxWindow() .br .RE .RE .LP .nf .B new(Parent, Options :: [Option]) -> wxStatusBar() .br .fi .br .RS .LP Types: .RS 3 Parent = wxWindow:wxWindow() .br Option = {winid, integer()} | {style, integer()} .br .RE .RE .RS .LP Constructor, creating the window\&. .LP See: \fIcreate/3\fR\& .RE .LP .nf .B destroy(This :: wxStatusBar()) -> ok .br .fi .br .RS .LP Destructor\&. .RE .LP .nf .B create(This, Parent) -> boolean() .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Parent = wxWindow:wxWindow() .br .RE .RE .LP .nf .B create(This, Parent, Options :: [Option]) -> boolean() .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Parent = wxWindow:wxWindow() .br Option = {winid, integer()} | {style, integer()} .br .RE .RE .RS .LP Creates the window, for two-step construction\&. .LP See \fInew/2\fR\& for details\&. .RE .LP .nf .B getFieldRect(This, I) -> Result .br .fi .br .RS .LP Types: .RS 3 Result = .br {Res :: boolean(), .br Rect :: .br {X :: integer(), .br Y :: integer(), .br W :: integer(), .br H :: integer()}} .br This = wxStatusBar() .br I = integer() .br .RE .RE .RS .LP Returns the size and position of a field\&'s internal bounding rectangle\&. .LP Return: true if the field index is valid, false otherwise\&. .LP See: {X,Y,W,H} .RE .LP .nf .B getFieldsCount(This) -> integer() .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br .RE .RE .RS .LP Returns the number of fields in the status bar\&. .RE .LP .nf .B getStatusText(This) -> unicode:charlist() .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br .RE .RE .LP .nf .B getStatusText(This, Options :: [Option]) -> unicode:charlist() .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Option = {number, integer()} .br .RE .RE .RS .LP Returns the string associated with a status bar field\&. .LP Return: The status field string if the field is valid, otherwise the empty string\&. .LP See: \fIsetStatusText/3\fR\& .RE .LP .nf .B popStatusText(This) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br .RE .RE .LP .nf .B popStatusText(This, Options :: [Option]) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Option = {number, integer()} .br .RE .RE .RS .LP Restores the text to the value it had before the last call to \fIpushStatusText/3\fR\&\&. .LP Notice that if \fIsetStatusText/3\fR\& had been called in the meanwhile, \fIpopStatusText/2\fR\& will not change the text, i\&.e\&. it does not override explicit changes to status text but only restores the saved text if it hadn\&'t been changed since\&. .LP See: \fIpushStatusText/3\fR\& .RE .LP .nf .B pushStatusText(This, String) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br String = unicode:chardata() .br .RE .RE .LP .nf .B pushStatusText(This, String, Options :: [Option]) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br String = unicode:chardata() .br Option = {number, integer()} .br .RE .RE .RS .LP Saves the current field text in a per-field stack, and sets the field text to the string passed as argument\&. .LP See: \fIpopStatusText/2\fR\& .RE .LP .nf .B setFieldsCount(This, Number) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Number = integer() .br .RE .RE .LP .nf .B setFieldsCount(This, Number, Options :: [Option]) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Number = integer() .br Option = {widths, [integer()]} .br .RE .RE .RS .LP Sets the number of fields, and optionally the field widths\&. .RE .LP .nf .B setMinHeight(This, Height) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Height = integer() .br .RE .RE .RS .LP Sets the minimal possible height for the status bar\&. .LP The real height may be bigger than the height specified here depending on the size of the font used by the status bar\&. .RE .LP .nf .B setStatusText(This, Text) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Text = unicode:chardata() .br .RE .RE .LP .nf .B setStatusText(This, Text, Options :: [Option]) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Text = unicode:chardata() .br Option = {number, integer()} .br .RE .RE .RS .LP Sets the status text for the \fIi-th\fR\& field\&. .LP The given text will replace the current text\&. The display of the status bar is updated immediately, so there is no need to call \fIwxWindow:update/1\fR\& after calling this function\&. .LP Note that if \fIpushStatusText/3\fR\& had been called before the new text will also replace the last saved value to make sure that the next call to \fIpopStatusText/2\fR\& doesn\&'t restore the old value, which was overwritten by the call to this function\&. .LP See: \fIgetStatusText/2\fR\&, \fIwxFrame:setStatusText/3\fR\& .RE .LP .nf .B setStatusWidths(This, Widths_field) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Widths_field = [integer()] .br .RE .RE .RS .LP Sets the widths of the fields in the status line\&. .LP There are two types of fields: \fIfixed\fR\& widths and \fIvariable\fR\& width fields\&. For the fixed width fields you should specify their (constant) width in pixels\&. For the variable width fields, specify a negative number which indicates how the field should expand: the space left for all variable width fields is divided between them according to the absolute value of this number\&. A variable width field with width of -2 gets twice as much of it as a field with width -1 and so on\&. .LP For example, to create one fixed width field of width 100 in the right part of the status bar and two more fields which get 66% and 33% of the remaining space correspondingly, you should use an array containing -2, -1 and 100\&. .LP Remark: The widths of the variable fields are calculated from the total width of all fields, minus the sum of widths of the non-variable fields, divided by the number of variable fields\&. .LP See: \fIsetFieldsCount/3\fR\&, \fIwxFrame:setStatusWidths/2\fR\& .RE .LP .nf .B setStatusStyles(This, Styles) -> ok .br .fi .br .RS .LP Types: .RS 3 This = wxStatusBar() .br Styles = [integer()] .br .RE .RE .RS .LP Sets the styles of the fields in the status line which can make fields appear flat or raised instead of the standard sunken 3D border\&. .RE