ApplicationWindow

The Application window control is based off Kirigami.ApplicationWindow.

The Maui implementation follows the Maui HIG and suggests the use of toolbars. It is layout vertically and contains by default: a HeadBar, a Content area, a FootBar and a GlobalDrawer.

The HeadBar and FootBar, are both based on another Maui component: Maui.ToolBar, so they inhere its properties.

The Content area itself is actually a Maui.Page with a few and small property mods and a Kirigami.PageRow as default content item.

The Content area content can be any other QCC2 control, such a a SwipeView, StackView, etc…, but for default there is a PageRow from Kirigami.

The Content area, as mentioned earlier can be any other control, although the Maui HIG suggests the following horizontal layouts, that can be achieve by making use of a SwipeView or Kirigami.PageRow.

Components

Properties

bool altToolBars

If set to True, the HeadBar will be moved to the bottom of the application window.

By default is set to the isMobile property, so if the target is a mobile device the HeadBar will be moved to the bottom.

If set to False, then the HeadBar will stay at the top of the application window even on mobile devices.

bool floatingBar

If set to True, the FootBar will act as a floating bar, it will not occupy the full width of the application window, but instead use the minimum width required to place its children content. Also it will be colored by making use of the theming property accentColor and cast a shadow.

By default the floating bar does not overlaps the content area, to make it overlap the content the footBarOverlap property will have to be set to True

By default this property is set to the altToolBars property.

int footBarAligment

By default it is set to Qt.AlignCenter, but can be set to any other alignment value. Changes will be only visible if the floatingBar property is set to True.

bool footBarOverlap

If set to True, and also only if the floatingBar property is set to True too, the FootBar will act as a floating bar overlapping the content of the window.

When this property is set to True, the content will flick when scrolled down to show a reserved space for the FootBar in order to not overlap important content positioned at the bottom.

By default this property is set to False

int footBarMargins

This property adds margins to the FootBar when it is set as a floating bar using the floatinBar property. It is useful when the FootBar needs to stand out.

Theming Properties

This properties can be changed to alter the look of the application from the Maui Kit controls and to the application own controls.

By default the colours are picked up from the system colour palette.

int iconSize color borderColor color backgroundColor color textColor color highlightColor color highlightedTextColor color buttonBackgroundColor color viewBackgroundColor color altColor color altColorText color accentColor color bgColor

Read-only Properties

bool isMobile

Defines if the target device is a mobile device or not. By default it uses the property Kirigami.Settings.isMobile

bool isAndroid

Defines if the operating system of the target device is Android or not.

int unit

Defines an unit making use of point size rather than pixel size. It is useful when the target device does not support pixel units right, like Plasma Mobile right now. By default is uses the property Kirigami.Units.devicePixelRatio

int rowHeight

Defines a standardized height for rows, such is in lists and menus. It is used on the templated controls inside the Maui Kit, and it is recommend it to be used in the application.

int rowHeightAlt

Defines a standardized height for alternative rows, such is in sub-items in lists and menus. It is used on the templated controls inside the Maui Kit, and it is recommend it to be used in the application. It has a smaller height size than the rowHeight property.

int toolBarHeight

Defines a standardized height for the toolbars. It is used on the templated controls inside the Maui Kit and for the Maui.ToolBar control, and it is recommend it to be used in the application where fitted.

int toolBarHeightAlt

Defines a standardized height for the alternative toolbars. It is used on the templated controls inside the Maui Kit and for toolbars inside the Maui.Page control, and it is recommend it to be used in the application where fitted.

int contentMargins

Defines a standardized size for content margins in places like Page, Panes and other controls.

var fontSizes

Defines a standardized set of sizes to be used to with fonts.

The possible values are: tiny, small, medium, default, big, large

var space

Defines a standardized set of sizes to be used for spacing items and layouts.

The possible values are: tiny, small, medium, big, large, huge, enormus

var iconSizes

Defines a standardized set of sizes to be used for icons and buttons.

The possible values are: tiny, small, medium, big, large, huge, enormus

Last updated