Instructions about how to create a custom theme. Francesco Fumanti francesco.fumanti@gmx.net 2016

This work is licensed under the GNU General Public License version 3 or any later version.

Theme creation and customisation
Introduction

The look of a layout in Onboard is specified through themes. They specify among others the colors used by the onscreen keyboard, whether the keys are flat or have a gradient, whether the keys should have rounded corners, etc. The themes however, do not specify size and position of the keys; these are specified in the layout files. You can learn more about layouts in the page.

A theme consists of two xml files:

The xml file with .theme as extension contains information among others about key style, key stroke, label overrides, what font to use and a reference to the xml file with the color information.

The xml file with .colors as extension contains the information about what colors to use for the different keys.

In the two following sections, you can find brief descriptions of the structure of both both files.

If you want to use custom themes with Onboard, simply put them into the themes directory in the .onboard of your home folder and Onboard will automatically pick them up.

Structure of the a <file>.theme</file> file

The xml structure of the a .theme file is quite simple and should not need any explanation to get understood as the tags used in the file are quite descriptive. I invite you to have a look at the Ambiance.theme file shipping with Onboard: it contains all the tags to use in a .theme xml file.

Structure of the a <file>.colors</file> file

The xml structure of the a .colors file is quite straightforward:

There are <pane> tags defining color and opacity of the different panes.

There are <key_group> tags that define also defining various color properties for the keys that are member of the <key_group>. To add a key to a <key_group>, simply add it between the opening and closing tags of the <key_group>. If a key is listed in more than one <key_group>, it will get the colors of the last <key_group> that has the key in its key list.

I invite you to have a look at the Aubergine.colors file shipping with Onboard as a sample of a .colors xml file.