Aurorae is a theme engine for KWin window decorations. It uses SVG to render the decoration and buttons and there is a simple config file for configuring the theme details.
This theme engine uses Plasma technology to render the window decoration. Every detail can be themed by the usage of SVG. The theme engine uses Plasma's FrameSvg for the window borders. This is described in more detail in Plasma's Theme description.
The theme consists of one folder containing svgz files for decoration and buttons, one KConfig file for the theme details and one metadata.desktop file which is used for theme name, author information, etc.
The engine supports ARGB decoration which is enabled by default, so that the theme can draw its own shadows. Nevertheless the themes should take care of the case that no desktop effects are used.
With Aurorae Designer there exists a special tool to design Aurorae themes. It is recommended to designers to use this tool. It helps to identify common pitfalls and provides an easy way to change settings and test if the theme contains all required elements.
The code of Aurorae Designer is developed in parallel to Aurorae, so Aurorae Designer might contain features which will be present in a future release of Aurorae, which is bound to the release schedule of the Software Compilation
The window decoration has to be provided in file decoration.svgz. This svg has to contain all the elements required for a Plasma theme background. The decoration has to use the element prefix decoration.
A different style for inactive windows can be provided in the same svg. The inactive elements must have the element prefix decoration-inactive. The theme engine tests for this prefix and if not provided inactive windows will be rendered with the same style as active windows.
A special decoration for opaque mode, that is when compositing is not active, has to be provided. This opaque decoration is used for generating the window mask. The element prefix is decoration-opaque for active and decoration-opaque-inactive for inactive windows. The mask is generated from the frame svg for active window only.
To summarize the following elements are supported:
In order to better support maximized windows there exists a special frame svg called decoration-maximized. In the same way as for the general decoration a version for inactive, opaque and inactive-opaque can be specified. This results in the following names:
In all cases only the center element will be used. There is no need to specify borders. Please note that in case of a window with translucent widgets the center element will be stretched to the size of the complete window.
The following fallback strategy is used: if inactive is not present it falls back to the active. If opaque is not present it falls back to the translucent. If none of the maximized elements are present the center element of the decoration is used!
In order to support Fitts' Law all TitleEdge Settings are set to 0. So the buttons will be directly next to the screen edges.
The support for maximized windows exists since KDE SC 4.5.
A svgz file has to be provided for each button. If the theme does not provide a file for a button type the engine will not include that button, so the decoration will miss it. There is no fallback to a default theme. The buttons are rendered using Plasma's FrameSvg just like the decoration. Each button has to provide the "center" element. Borders are not supported
The following buttons are supported:
Each button can have different states. So a button could be hovered, pressed, deactivated and the theme might want to provide different styles for active and inactive windows. The following element prefixes can be used to provide styles for the buttons:
At least the active element has to be provided. All other elements are optional and the active element is always used as a fallback. If the theme provides the inactive element, this is used as a fallback for the inactive states. That is, if the theme provides a hover element, but none for inactive, the inactive window will not have a hover effect. Same is true for pressed and deactivated.
The buttons alldesktops, keepabove, keepbelow and shade are toggle buttons. When clicking on them they will stay in state pressed(-inactive). By clicking them again they will change back to (in)active.
All of those elements have to be put into one svgz file for a button type. The name of the file is the one listed above. E.g. the svg file for the close button has to be named: close.svgz.
The configuration file is a normal KConfig file. You have to give it the name of your decoration with suffix "rc". So if your theme has the name "deco", your config file will be named "decorc". The following section shows the possible options with their default values.
The layout is based on the layout metric used by KCommonDecoration. The following diagrams illustrate which configuration value influences which part of the decoration. The available configuration options and their default values are listed below.
___________________________________________________________________ | PaddingTop | | _______________________________________________________________ | | | TitleEdgeTop | | | |_______________________________________________________________| | | | TitleEdgeLeft | [title] | TitleEdgeRight | | | |_______________|______________________________|________________| | | | TitleEdgeBottom | | | |_______________________________________________________________| | | | | | | | |PaddingLeft PaddingRight| | | | | | | | |BorderLeft BorderRight| | | |_|___________________________________________________________|_| | | | BorderBottom | | | |_______________________________________________________________| | | PaddingBottom | |___________________________________________________________________|
__________________________________________________________________________ | ButtonMarginTop | | ButtonMarginTop | |_____________________________| |______________________________| | [Buttons] | TitleBorderLeft | TitleHeight | TitleBorderRight | [Buttons] | |___________|_________________|_____________|__________________|___________|
_____________________________________________________________________________________________ | button | spacing | button | spacing | explicit spacer | spacing | ... | spacing | button | |________|_________|________|_________|_________________|_________|________|_________|________|
The theme must contain a file metadata.desktop for additional information like name, author, licence, etc. Those data is shown in the about dialog of the theme. The file is mandatory as the engine uses it to locate the theme. The format follows the Desktop Entry Specification and the following entries are read by Aurorae:
All theme files (decoration, buttons, metadata.desktop and configuration file) have to be stored in one directory with the name of the theme (this has to be identical to the one used for the config file). You have to create a tar.gz archive from that directory. This archive is the theme, which can be installed in the kcm for window decorations.