UCI Styles
You can install custom Cascading Style Sheet (.css) files to a design, and then apply a selected style to a user control interface (UCI). This makes it easy to apply the same style to multiple UCI elements. It also allows for UCI design uniformity throughout an organization, since the same styles can be used for multiple designs.
Note: The web browser UCI viewer accessible from Q-SYS Core Manager does not currently support CSS UCI styles.
Q-SYS Designer checks the following directory for .css files to install: \Users\user-name\Documents\QSC\Q-SYS Designer\Styles
- Within the above the directory, create a folder for each style. The folder name is used for the style name in Q-SYS Designer.
- Create a file called
style.css
and place it in the folder for your style.- Use a common code authoring tool such as Visual Studio Code to write your style.
- Refer to Supported CSS Properties to see what selectors are compatible with Q-SYS UCI design graphic and control elements. Q-SYS supports common CSS selectors.
- If your style uses images or custom fonts, place them in the folder containing your style. Ensure that your .css file refers to the proper subfolders for referenced files.
- Install the style to a design. See Managing UCI Styles.
- Apply the style to a UCI. See Applying and Updating UCI Styles.
Tip: Because style .css files are installed to the design, if you share a design containing installed styles with someone else, that person will also see those styles.
Installing New Styles to a Design
- Place the .css file and any supporting image files into the Styles folder. See Getting Started.
- In Q-SYS Designer, create or open a design file.
- Click Tools > Manage UCI Styles.
- From the Available list, select the style name, and then click Add.
- Close the Manage UCI Styles window.
The installed style is now available for selection in your UCI. See Applying and Updating UCI Styles.
Removing Styles from a Design
- In Q-SYS Designer, create or open a design file.
- Click Tools > Manage UCI Styles.
- From the Installed list, select the style name, and then click Remove.
- Close the Manage UCI Styles window.
Saving Styles from a Design
If a design contains a styles file that is not currently on your local disk, you can save it from the design. You can then edit the file.
- Click Tools > Manage UCI Styles.
- In the Installed column, if a style is not currently saved to disk, a button appears next to the design name. Click the button.
The style is now saved to the Styles folder on-disk.
Note: Referenced image files are not saved.
Once you have installed a UCI style file to a design, you can then apply it to a UCI. Applied styles take precedence over individual graphic and control properties in Designer.
- With your design file open in Q-SYS Designer, select User Control Interfaces in the left pane.
- Select your UCI name.
- In the User Control Interface Properties (right side pane), select a Style from the drop-down menu.
- Optionally, use the CSS Class Name property to adjust the assigned classes for a UCI element (button, fader, text box, etc.). An element can belong to as many CSS classes as needed to provide the desired styling.
Tip: Click to access the Manage UCI Styles window from the UCI Properties pane.
Updating Styles
If you modify a styles .css file – either via an update from Q-SYS Asset Manager or in a code editor – Q-SYS Designer detects any changes and prompts you to update the style in your design.
You can modify a .css file whether your design is open is Q-SYS Designer or not. To allow Q-SYS Designer to automatically update styles while your design is open (without prompting), click Tools > Auto Update Styles.
Note: The Auto Update Styles option is not saved with the design. The option reverts to disabled the next time you open your design file.
The following tables indicate what selectors are supported for specific UCI graphic and control elements.
= Supported
Graphics
Property | Page | Textblock | Groupbox | Header | Image | Polygon |
---|---|---|---|---|---|---|
background |
|
|
|
|
||
background-color |
|
|
|
|
||
background-image |
|
|
|
|
||
background-position |
|
|
|
|
||
background-size |
|
|
|
|
||
border |
|
|
||||
border-width |
|
|
||||
border-* |
|
|
||||
border-*-width |
|
|
||||
border-*-color |
|
|
||||
border-radius |
|
|
||||
color |
|
|
|
|||
content |
|
|
|
|||
font-family |
|
|
|
|||
font-size |
|
|
|
|||
margin |
|
|||||
opacity |
|
|
|
|
||
padding |
|
|||||
text-align |
|
|
|
|||
text-transform |
|
|
|
|||
vertical-align |
|
|||||
-qsc-font-style3 |
|
|
|
1. Only supports single border color and thickness (uses left).
2. Only supports single corner radius (uses top left).
3. Specific to QSC, and uses the same values as the Font Style property drop-down – Bold, Italic, Bold Italic, etc.
Controls
Button | Textbox | Knob | Led | Fader | Meter | Combobox | Listbox | |
---|---|---|---|---|---|---|---|---|
background |
|
|
|
|
|
|
||
background-color |
|
|
|
|
|
|
|
|
background-image |
|
|
|
|
|
|
||
background-position |
|
|
|
|
|
|
||
background-size |
|
|
|
|
|
|
||
border |
|
|
|
|
|
|
||
border-width |
|
|
|
|
|
|
||
border-* |
|
|
|
|
|
|
||
border-*-width |
|
|
|
|
|
|
||
border-*-color |
|
|
|
|
|
|
||
border-radius |
|
|
|
|
|
|
||
color |
|
|
|
|
|
|
||
content |
|
|
||||||
font-family |
|
|
|
|
|
|||
font-size |
|
|
|
|
|
|||
margin |
|
|
|
|
|
|
||
opacity |
|
|
|
|
|
|
|
|
padding |
|
|
||||||
text-align |
|
|
|
|
|
|||
text-transform |
|
|
|
|
||||
vertical-align |
|
|
|
|||||
-qsc-font-style |
|
|
|
|
|
1. Only supports color (not images) on the background.
2. Only supports single border color and thickness (uses left).
3. Only supports single corner radius (uses top left).
Creating, Installing, and Applying a Style
Create a new folder within the \Users\user-name\Documents\QSC\Q-SYS Designer\Styles
folder on your PC. This folder name becomes the style name in Designer. Create a file called style.css
and place it and any images or custom fonts you plan to reference in this folder.
Use a text or code editor to author the style. This example shows Visual Studio Code.
Note: Click here to see the CSS content shown in this video.
Go to Tools > Manage UCI Styles to install the style.
When you select the installed style, the elements of the UCI receive the styling from the style.css file.
After you apply the style, you can optionally fine-tune what CSS classes are applied to each element in the UCI. Select a UCI element and use the CSS Class Name property to assign one or more classes. In this example, the fader already has the GainLevelFader class assigned, which sets its color and border width. However, the user desires to use the same background color as the knob, so he selects the GainLevelKnob class as well.
Setting CSS Properties
Defined CSS style properties override the same properties in Designer. For example, in this style.css file, all buttons are defined to use a blue background. Therefore, if a button is set to use red in the Designer properties, it is overridden by the applied style and therefore uses blue. Note, however, that because there is no font size defined in the style, the size specified in Designer is used.
button{ background: Blue; font-family: Lato; font-face: Bold; }
In this example, the On state of the button is set with button:value(1). The code sets the On state color for all buttons to be red:
button:value(1){ background: Red; }
To apply styling to a subset of items (for example, source buttons), you first define a class in the CSS document. The example code below adds a class for preset buttons and sets the buttons to be green when Off and orange when On. Note that you can use names, RGB values, or RGBA values when defining colors.
.source{ background: Green; } .souce:value(1){ background: rgb(255, 174, 0); }
Referencing Images and Custom Fonts
Reference images by providing a path to the image file as the background-image property – for example, for buttons.
.pc{ background-image: url(images/pc.png); }
Reference custom fonts in your CSS file using the @font-face
rule. Make sure to reference the location where your fonts are stored in relation to your CSS file. For example, here is a reference to a font stored in a fonts
subfolder at the same level as the CSS file:
@font-face { font-family: "My Fancy Font"; src: url( fonts/fancyfont.ttf ); } textbox { font-family: "My Fancy Font"; }