TINT2

NAME

tint2 - lightweight panel/taskbar

DESCRIPTION

tint2 is a simple panel/taskbar made for modern X window managers. It was specifically made for Openbox but it should also work with other window managers (GNOME, KDE, XFCE etc.).

Features:

Goals:

SYNOPSIS

tint2 [OPTION...]

OPTIONS

-c path_to_config_file
Specifies which configuration file to use instead of the default.
-v, --version
Prints version information and exits.
-h, --help
Display this help and exits.

CONFIGURATION

Table of contents

Introduction

These are instructions for configuring tint2 directly by editing its config file. You may also use instead the graphical interface tint2conf.

The first time you run tint2, it will create the config file in $HOME/.config/tint2/tint2rc (This applies if you have done a clean install. Running tint2 in the source directory without doing 'make install' will not create the config file.)

You can also specify another file on the command line with the -c option, e.g.: tint2 -c $HOME/tint2.conf. This can be used to run multiple instances of tint2 that use different settings.

If you change the config file while tint2 is running, the command killall -SIGUSR1 tint2 will force tint2 to reload it.

All the configuration options supported in the config file are listed below. Try to respect as much as possible the order of the options as given below.

Backgrounds and borders

The tint2 config file starts with the options defining background elements with borders:

You can define as many backgrounds as you want. For example, the following config defines two backgrounds:

rounded = 1
border_width = 0
background_color = #282828 100
border_color = #000000 0

rounded = 1
border_width = 0
background_color = #f6b655 90
border_color = #cccccc 40

tint2 automatically identifies each background with a number starting from 1 (1, 2, ...). Afterwards, you can apply a background to objects (panel, taskbar, task, clock, systray) using the background id, for example:

panel_background_id = 1
taskbar_background_id = 0
task_background_id = 0
task_active_background_id = 2
systray_background_id = 0
clock_background_id = 0

Identifier 0 refers to a special background which is fully transparent, identifier 1 applies the first background defined in the config file etc.

Gradients

(Available since 0.13.0)

Backgrounds also allow specifying gradient layers that are drawn on top of the solid color background.

First the user must define one or more gradients in the config file, each starting with gradient = TYPE. These must be added before backgrounds.

Then gradients can be added by index to backgrounds, using the gradient_id = INDEX, gradient_id_hover = INDEX and gradient_id_pressed = INDEX, where INDEX is the gradient index, starting from 1.

Gradient types

Gradients vary the color between fixed control points: * vertical gradients: top-to-bottom; * horizontal gradients: left-to-right; * radial gradients: center-to-corners.

The user must specify the start and end colors, and can optionally add extra color stops in between using the color_stop option, as explained below.

Vertical gradient, with color varying from the top edge to the bottom edge, two colors
gradient = vertical
start_color = #rrggbb opacity
end_color = #rrggbb opacity
Horizontal gradient, with color varying from the left edge to the right edge, two colors
gradient = horizontal
start_color = #rrggbb opacity
end_color = #rrggbb opacity
Radial gradient, with color varying from the center to the corner, two colors:
gradient = radial
start_color = #rrggbb opacity
end_color = #rrggbb opacity
Adding extra color stops (0% and 100% remain fixed, more colors at x% between the start and end control points)
color_stop = percentage #rrggbb opacity

Gradient examples

# Gradient 1: thin film effect
gradient = horizontal
start_color = #111122 30
end_color = #112211 30
color_stop = 60 #221111 30

# Gradient 2: radial glow
gradient = radial
start_color = #ffffff 20
end_color = #ffffff 0

# Gradient 3: elegant black
gradient = vertical
start_color = #444444 100
end_color = #222222 100

# Gradient 4: elegant black
gradient = horizontal
start_color = #111111 100
end_color = #222222 100

# Background 1: Active desktop name
rounded = 2
border_width = 1
border_sides = TBLR
background_color = #555555 10
border_color = #ffffff 60
background_color_hover = #555555 10
border_color_hover = #ffffff 60
background_color_pressed = #555555 10
border_color_pressed = #ffffff 60
gradient_id = 3
gradient_id_hover = 4
gradient_id_pressed = 2

[...]

Panel

# The panel's width is 94% the size of the monitor, the height is 30 pixels:
panel_size = 94% 30

Launcher

Taskbar / Pager

Taskbar buttons

The following options configure the task buttons in the taskbar:

For the next 3 options STATUS can be active / iconified / urgent:
* task_STATUS_font_color = color opacity (0 to 100)

Mouse actions for taskbar buttons

The possible mouse events are: left, middle, right, scroll_up, scroll_down.

The possible mouse actions are: none, close, toggle, iconify, shade, toggle_iconify, maximize_restore, desktop_left, desktop_right, next_task, prev_task.

Use mouse_event = action to customize mouse actions. Example: mouse_middle = none mouse_right = close mouse_scroll_up = toggle mouse_scroll_down = iconify

The action semantics:
* none : If wm_menu = 1 is set, the mouse event is forwarded to the window manager. Otherwise it is ignored. * close : close the task * toggle : toggle the task * iconify : iconify (minimize) the task * toggle_iconify : toggle or iconify the task * maximize_restore : maximized or minimized the task * shade : shades (collapses) the task * desktop_left : send the task to the desktop on the left * desktop_right : send the task to the desktop on the right * next_task : send the focus to next task * prev_task : send the focus to previous task

System Tray

Clock

Tooltip

Battery

Executor

Executor samples

execp = new
execp_command = hostname
execp_interval = 0
execp = new
execp_command = df -h | awk '/\/$/ { print $6 ": " $2 " " $5}'
execp_interval = 10
Button with icon and rich text, executes command when clicked
execp = new
execp_command = echo /usr/share/icons/elementary-xfce/emblems/24/emblem-colors-blue.png; echo '<span foreground="#7f7">Click</span> <span foreground="#77f">me</span> <span foreground="#f77">pls</span>'
execp_has_icon = 1
execp_interval = 0
execp_centered = 1
execp_font = sans 9
execp_markup = 1
execp_font_color = #aaffaa 100
execp_padding = 2 0
execp_tooltip = I will tell you a secret...
execp_lclick_command = zenity --info "--text=$(uname -sr)"
execp_background_id = 2
Desktop pager with text
execp = new
execp_command = xprop -root -spy | awk '/^_NET_CURRENT_DESKTOP/ { print "Workspace " ($3 + 1) ; fflush(); }'
execp_interval = 1
execp_continuous = 1
Desktop pager with icon
execp_command = xprop -root -spy | awk -v home="$HOME" '/^_NET_CURRENT_DESKTOP/ { print home "/.config/myPager/" ($3 + 1) ".png\n" ; fflush(); }'
execp_interval = 1
execp_has_icon = 1
execp_cache_icon = 1
execp_continuous = 2
Round-trip time to the gateway, refreshed every second
execp = new
execp_command = ping -i 1 -c 1 -W 1 -O -D -n $(ip route | grep default | grep via | grep -o '[0-9]*\.[0-9]*\.[0-9]*\.[0-9]*') | awk '/no/ { print "<span foreground=\"#faa\">timeout</span>"; fflush(); }; /time=/ { gsub(/time=/, "", $8); printf "<span foreground=\"#7af\">%3.0f %s</span>\n", $8, $9; fflush(); } '
execp_continuous = 0
execp_interval = 1
execp_markup = 1
Memory usage
# Note the use of "stdbuf -oL" to force the program to flush the output line by line.
execp = new
execp_command = free -b -s1 | stdbuf -oL awk '/^Mem:/ { printf "Mem: %s %.0f%%\n", $2, 100 * ($2 - $7) / $2 }' | stdbuf -oL numfmt --to=iec-i --field=2 -d' '
execp_interval = 1
execp_continuous = 1
Network load
execp = new
execp_command = stdbuf -oL bwm-ng -o csv -t 1000 | stdbuf -oL awk -F ';' '/total/ { printf "Net: %.0f Mb/s\n", ($5*8/1.0e6) }'
execp_continuous = 1
execp_interval = 1

Button

Separator

Example configuration

See /etc/xdg/tint2/tint2rc.

AUTHOR

tint2 was written by Thierry Lorthiois lorthiois@bbsoft.fr. It is based on ttm, originally written by Pål Staurland staura@gmail.com.

This manual page was originally written by Daniel Moerner dmoerner@gmail.com, for the Debian project (but may be used by others). It was adopted from the tint2 docs.

SEE ALSO

The main website https://gitlab.com/o9000/tint2 and the wiki page at https://gitlab.com/o9000/tint2/wikis/home.

This documentation is also provided in HTML and Markdown format in the system's default location for documentation files, usually /usr/share/doc/tint2 or /usr/local/share/doc/tint2. . .