Style Dialog

style-dialog

Access the style dialog by clicking on the Style button on the Toolbar.

This dialog allows the user to customize how the UI looks by using the Qt styling language known as QSS. A detailed discussion of QSS is beyond the scope of this page, however general usage of the dialog is described.

Anything entered in the main textbox will automatically be applied to the entire program after a brief pause. When you dismiss this dialog by clicking Ok, whatever was shown in the main textbox will get written to a file in the settings folder named default.qss. This will be loaded on all subsequent runs of the program.

You can restore the defaults by deleting default.qss.

Be sure to note the comment text at the top and adjust the size of the tabs to suit your visual preference. There is no one correct value that works well on all systems, so it’s incumbent upon the user to set it themselves.

dark.qss

Fractorium comes with a sample dark style in a file named dark_*.qss (* is the name of your operating system) that resides in the settings folder. Load it into the main text box by clicking the Load button, navigating to C:\Users\[USER NAME]\AppData\Roaming\Fractorium on Windows, or /usr/share/fractorium on Linux, and selecting the dark_*.qss file.

If dark_*.qss does not suit your needs, you may make your own QSS file. It is strongly recommended that you use dark_*.qss as a template and do not start from scratch. This is because dark_*.qss takes special action on specific instances of controls to ensure they all look perfect. Leaving out any of these can lead to strange artifacts and inconsistent styling.

There is also a stylesheet named lightdark.qss which is a more modern take on dark_*.qss, and another named uranium.qss which is based on the uranium color scheme for the old media player named Winamp.

These can also serve as a starting point for further customization.

Add color, spacing, border, font

These will add the needed QSS syntax for modifying these fields for a particular control. Be sure to always add them between curly braces.

Set theme

In addition to the custom styling, there is a set of overall looks that Qt ships with that are listed here. These differ by operating system.

The sample dark_*.qss and lightdark.qss themes have been tested to look good with any of these.

Basic

Reset the style to the original default.

Medium

Reset the style to the original default and provide a template for editing styles for the most common controls.

Advanced

Reset the style to the original default and provide a template for editing every control in the entire program.

This is unlikely to ever be used and is only meant for extreme cases where a particular control does not look right and you want to experiment with changing its look. The syntax of each specific control is ControlType#ControlInstanceName.

Once the proper look for the specific control is to your liking, roll the changes back into a template like dark_*.qss or lightdark.qss.

Ok

Dismiss the dialog and save the contents of the main text box to default.qss in the settings folder. Save the selected theme to the settings file.

Cancel

Do not save the contents of the main text box. Revert the current style and theme back to what they were when the dialog was originally shown.