Skip to content
Fernando Vásquez edited this page Jan 27, 2018 · 16 revisions

Table of Contents

templates-tab

What are Templates

In wpgtk templates are textfiles with .base extension which gets read parsed and has special keywords in it replaced, then copied over to a file that is sym-linked to the original config file, this way it is ensured that the original file only receives already processed information and is updated on the fly, the base files created are stored under $HOME/.config/wpg/templates.

A tipical template will look like this rofi.base

rofi.columns:                        1
rofi.font:                           roboto mono 10
rofi.color-normal:                   #COLOR0, #COLORX15, #COLOR0, #COLORACT, #COLORX15
rofi.color-urgent:                   #COLOR0, #d6b48d, #22231D, #d6b48d, #COLORX15
rofi.color-active:                   #COLOR0, #COLORX14, #COLOR0, #COLORX14, #COLOR0
rofi.color-window:                   #COLOR0, #COLORACT, #COLORIN

Default Keywords

Here are the default keywords included with wpgtk, these might change with the passage of time.

COLOR0 through COLOR9
COLORX10 through COLORX15
COLORACT  # for active color
COLORIN   # for inactive color
COLORBG  
COLORTOOL # for tooltips (needed in old templates)

Adding a Template

This will create a backup in the location specified under filename.bak to avoid losing any precious data if you regret adding the file later, it also creates a copy of that file under $HOME/.config/wpg/templates with the .base extension, in which you can edit and place keywords for wpgtk to replace.

CLI

wpg -xa ./path/to/file

GUI

Using the Add button under the Templates tab

Clone this wiki locally