Module gui

Source
Available on crate feature gui only.
Expand description

High-level GUI abstractions for user windows and native controls. They can be created programmatically or by loading resources from a .res file. These files can be created with a WYSIWYG resource editor.

§Windows

There are 5 types of windows, which can host child controls:

You’ll probably want to start your GUI application using the WindowMain.

§Native controls

Native controls are hosted by windows, and receive various types of user input.

Modules§

collections
Objects which exposes methods to work upon individual items of certain native controls.
events
Exposes native control messages that can be handled.

Structs§

Button
Native button control.
ButtonOpts
Options to create a Button programmatically with Button::new.
CheckBox
Native check box control, actually a variation of the ordinary Button: just a button with a specific style.
CheckBoxOpts
Options to create a CheckBox programmatically with CheckBox::new.
ComboBox
Native combo box control.
ComboBoxOpts
Options to create a ComboBox programmatically with ComboBox::new.
DateTimePicker
Native date and time picker control.
DateTimePickerOpts
Options to create a DateTimePicker programmatically with DateTimePicker::new.
Edit
Native edit (text box) control.
EditOpts
Options to create an Edit programmatically with Edit::new.
Header
Native header control.
HeaderItem
A single item of a Header control.
HeaderOpts
Options to create a Header programmatically with Header::new.
Label
Native label control.
LabelOpts
Options to create a Label programmatically with Label::new.
ListBox
Native list box control. Not to be confused with the more complex list view control.
ListBoxOpts
Options to create a ListBox programmatically with ListBox::new.
ListView
Native list view control. Not to be confused with the simpler list box control.
ListViewCol
A single column of a ListView control.
ListViewItem
A single item of a ListView control.
ListViewOpts
Options to create a ListView programmatically with ListView::new.
MonthCalendar
Native month calendar control.
MonthCalendarOpts
Options to create a MonthCalendar programmatically with MonthCalendar::new.
MsgError
An error that occurred within a closure of a window message handling. Usually these errors are thrown by the user closures.
ProgressBar
Native progress bar control.
ProgressBarOpts
Options to create a ProgressBar programmatically with ProgressBar::new.
RadioButton
Native radio button control.
RadioButtonOpts
Options to create a RadioButton programmatically with RadioGroup::new.
RadioGroup
A group of native RadioButton controls.
StatusBar
Native status bar control, which has one or more parts.
StatusBarPart
A single part of a StatusBar control.
Tab
Native tab control.
TabItem
A single item of a Tab control.
TabOpts
Options to create a Tab programmatically with Tab::new.
Trackbar
Native trackbar control.
TrackbarOpts
Options to create a Trackbar programmatically with Trackbar::new.
TreeView
Native tree view control.
TreeViewItem
A single item of a TreeView control.
TreeViewOpts
Options to create a TreeView programmatically with TreeView::new.
UpDown
Native up-down control.
UpDownOpts
Options to create an UpDown programmatically with UpDown::new.
WindowControl
An user child window, which can handle events. Can be programmatically created or load a dialog resource from a .res file.
WindowControlOpts
Options to create a WindowControl programmatically with WindowControl::new.
WindowMain
An user main window, which can handle events. Usually, this is the first window of your application, launched directly from the main function. Can be programmatically created or load a dialog resource from a .res file.
WindowMainOpts
Options to create a WindowMain programmatically with WindowMain::new.
WindowMessageOnly
A message-only window, which can handle events.
WindowModal
An user modal window, which can handle events. Can be programmatically created or load a dialog resource from a .res file.
WindowModalOpts
Options to create a WindowModal programmatically with WindowModal::new.
WindowModeless
An user modeless window, which can handle events. Can be programmatically created or load a dialog resource from a .res file.
WindowModelessOpts
Options to create a WindowModeless programmatically with WindowModeless::new.

Enums§

Brush
The class background brush to be loaded for WindowMainOpts, WindowModalOpts or WindowControlOpts.
Cursor
The class cursor to be loaded for WindowMainOpts, WindowModalOpts or WindowControlOpts.
HeaderArrow
Possible states of the arrow in a HeaderItem.
HeaderJustify
Text justification for a HeaderItem.
Horz
Specifies the horizontal behavior of the control when the parent window is resized.
Icon
The class icon to be loaded for WindowMainOpts, WindowModalOpts or WindowControlOpts.
SbPart
Used when adding the parts in StatusBar::new.
Vert
Specifies the vertical behavior of the control when the parent window is resized.

Functions§

dpi
Returns the values adjusted according to the current horizontal and vertical system DPI, retrieved with HDC::GetDeviceCaps.
dpi_x
Returns the value adjusted according to the current horizontal system DPI, retrieved with HDC::GetDeviceCaps.
dpi_y
Returns the value adjusted according to the current vertical system DPI, retrieved with HDC::GetDeviceCaps.