Difference between revisions of "CSS"
Yvonne.milne (Talk | contribs) |
Yvonne.milne (Talk | contribs) |
||
Line 1: | Line 1: | ||
''Under Construction'' | ''Under Construction'' | ||
+ | |||
+ | ==See Also== | ||
+ | [http://doc.qt.io/qt-5/stylesheet-reference.html QT Style Sheets Reference], [http://doc.qt.io/qt-5/stylesheet-syntax.html QT Style Sheets Syntax] | ||
==Introduction== | ==Introduction== | ||
Line 38: | Line 41: | ||
In Custom Sections, the elements use the "name" property that you assign to them. | In Custom Sections, the elements use the "name" property that you assign to them. | ||
− | === | + | ===Type Selectors: Pages, Sections and Formitems=== |
lianja_ui_page | lianja_ui_page | ||
Line 67: | Line 70: | ||
− | === | + | ===Type Selectors: UI Framework=== |
lianja_ui_checkbox | lianja_ui_checkbox | ||
Line 160: | Line 163: | ||
====UI State Selectors==== | ====UI State Selectors==== | ||
UI State Selectors are special built-in Property Selectors for Canvas Section editable Advanced Controls. | UI State Selectors are special built-in Property Selectors for Canvas Section editable Advanced Controls. | ||
+ | |||
+ | Select based on whether the Mandatory attribute is true or false: | ||
[lianja_uistate_mandatory="true"] | [lianja_uistate_mandatory="true"] | ||
Line 165: | Line 170: | ||
[lianja_uistate_mandatory="false"] | [lianja_uistate_mandatory="false"] | ||
− | + | Select based on whether Validation returned true or false: | |
− | + | ||
[lianja_uistate_valid="true"] | [lianja_uistate_valid="true"] | ||
+ | |||
+ | [lianja_uistate_valid="false"] |
Revision as of 10:44, 22 September 2016
Under Construction
Contents
See Also
QT Style Sheets Reference, QT Style Sheets Syntax
Introduction
Defining
CSS Style Attribute
The name for use with setAttribute() and getAttribute() is cssStyle.
Stylesheet Common Property
The synonym css can also be used.
CSS Files
Selectors
Universal Selector
The asterisk * selects all objects.
ID Selectors
The CSS selector for a named object is #id.
Note: this corresponds to the Name attribute in the Attributes App Inspector tab or Attributes Dialog.
Each UI element is given a unique object id.
Page is the pageid.
Section is pageid + "_" + sectionid
Formitem is pageid + "_" + sectionid + "_" + formitemid;
e.g.
#page1_section1_field1
In Custom Sections, the elements use the "name" property that you assign to them.
Type Selectors: Pages, Sections and Formitems
lianja_ui_page
[lianja_ui_page_footer]
[lianja_ui_page_header]
[lianja_ui_page_panel]
lianja_ui_section
[lianja_ui_section_footer]
lianja_ui_section_formitem
[lianja_ui_section_formitem_data]
[lianja_ui_section_formitem_divider]
[lianja_ui_section_formitem_gadget]
[lianja_ui_section_formitem_label]
[lianja_ui_section_formitem_separator]
[lianja_ui_section_formitem_subtitle]
Type Selectors: UI Framework
lianja_ui_checkbox
lianja_ui_combobox
lianja_ui_commandbutton
lianja_ui_container
lianja_ui_control
lianja_ui_datetextbox
lianja_ui_datetimetextbox
lianja_ui_editbox
lianja_ui_editor
lianja_ui_form
lianja_ui_grid
Sub-control: lianja_ui_grid::item
lianja_ui_header
lianja_ui_label
lianja_ui_listbox
lianja_ui_menu
lianja_ui_menubar
lianja_ui_menuitem
lianja_ui_navbar
lianja_ui_optionbutton
lianja_ui_pageframe
lianja_ui_pagesidebar
lianja_ui_popupmenu
lianja_ui_progressbar
lianja_ui_richeditbox
lianja_ui_spinner
lianja_ui_splitter
lianja_ui_tabpage
lianja_ui_textbox
lianja_ui_toolbar
lianja_ui_toolbox
lianja_ui_tree
Sub-control: lianja_ui_tree::item
Pseudo-State Selectors
Selectors may contain pseudo-states. They are prefixed with a colon (:).
hover
lianja_ui_grid::item:!hover { background:pink; } lianja_ui_grid::item:hover { background:yellow; }
Property Selectors
e.g.
[user_attr1="1"] { color:red; } [user_attr1="16"] { color:blue; }
UI State Selectors
UI State Selectors are special built-in Property Selectors for Canvas Section editable Advanced Controls.
Select based on whether the Mandatory attribute is true or false:
[lianja_uistate_mandatory="true"]
[lianja_uistate_mandatory="false"]
Select based on whether Validation returned true or false:
[lianja_uistate_valid="true"]
[lianja_uistate_valid="false"]