table of contents
cagebreak-config(5) | Cagebreak Manual | cagebreak-config(5) |
NAME¶
cagebreak-config Cagebreak configuration file
SYNOPSIS¶
$XDG_CONFIG_PATH/cagebreak/config
DESCRIPTION¶
The cagebreak configuration is a plain text file.
Each line consists of a comment or a command and its arguments which are parsed sequentially but independently from the rest of the file.
Each line starting with a "#" is a comment.
Note that nesting of commands is limited to 50 times. Lines are arbitrarily long in practice, though a reasonable limit of 4Mb has been set.
See KEY DEFINITIONS for details on modifier keys and MODES for details on modes.
COMMANDS¶
abort
background <r> <g> <b>
# Set background to red background 1.0 0.0 0.0
bind <key> <command>
bind <key> <command> # is equivalent to definekey root <key> <command>
close
configure_message [font <font description>|[f|b]g_color <r> <g> <b> <a>|display_time <n>|anchor <position>]
- font <font description> sets the font of the message. Here, <font
description> is either
- an X core font description or
- a FreeType font description via pango - fg_color <r> <g> <b> <a> sets the RGBA of the foreground
- bg_color <r> <g> <b> <a> sets the RGBA of the background
- display_time <n> sets the display time in seconds
- anchor <position> sets the position of the message.
<position> may be one of {top,bottom}_{left,center,right} or center.
# Set font ## Set example X code font configure_message font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1 ## Set example FreeType font description configure_message font pango:monospace 10 # Set foreground RGBA to red configure_message fg_color 1.0 0.0 0.0 1.0 # Set background RGBA to red configure_message bg_color 1.0 0.0 0.0 1.0 # Set duration for message display to four seconds configure_message display_time 4
cursor [enable|disable]
This simply hides the cursor. Pointing and clicking is still possible.
custom_event <message>
This sends an event of type "custom_event" to all programs listening to the IPC socket along with the string <message>. See cagebreak-socket(7) for more details.
definekey <mode> <key> <command>
definemode <mode>
# define new mode and create a mapping for it definemode foo definekey foo C-t abort
dump
escape <key>
escape <key> # is equivalent to definekey top <key> mode root
exchangedown
exchangeleft
exchangeright
exchangeup
exec <command>
focus
focusdown
focusleft
focusprev
focusright
focusup
hsplit
input <identifier> <setting> <value>
- touchpad
- pointer
- keyboard
- touch
- tablet_tool
- tablet_pad
- switch
Configurations are applied sequentially. Currently, only libinput devices may be configured. The available settings and their corresponding values are as follows:
accel_profile adaptive|flat
calibration_matrix <6 space-separated floating point values>
click_method none|button_areas|clickfinger
drag enabled|disabled
drag_lock enabled|disabled
dwt enabled|disabled
events enabled|disabled|disabled_on_external_mouse
keybindings [enabled|disabled]
left_handed enabled|disabled
middle_emulation enabled|disabled
natural_scroll enabled|disabled
pointer_accel [<-1|1>]
scroll_button disable|<event-code-or-name>
scroll_factor <floating point value>
scroll_method none|two_finger|edge|on_button_down
repeat_delay <n>
repeat_rate <n>
tap enabled|disabled
tap_button_map lrm|lmr
message <text>
mode <mode>
movetonextscreen
movetoprevscreen
movetoscreen <n>
movetoworkspace <n>
next
nextscreen
only
output <name> [[pos <xpos> <ypos> res <width>x<height> rate <rate> [scale <scale>]] | enable | disable | [permanent|peripheral] | prio <n> | rotate <n>]
- <xpos> and <ypos> are the position of the monitor in pixels. The top-left monitor should have the coordinates 0 0.
- <width> and <height> specify the resolution in pixels.
- <rate> sets the refresh rate of the monitor (often this is 50 or 60).
- <scale> sets the output scale (default is 1.0)
- enable and disable enable or disable <name>. Note that if <output> is the only enabled output, output <output> disable has no effect.
- permanent sets <name> to persist even on disconnect. When the physical monitor is disconnected, the output is maintained and operates identically to the attached monitor. On reconnect, the monitor operates as though it was never disconnected. Setting the output role to peripheral when the monitor is disconnected, destroys the output, as if the monitor were disconnected.
- peripheral sets the role of <name> to peripheral, meaning that on disconnecting the respective monitor, all views will be moved to another available output. The default role is peripheral.
- prio <n> is used to set the priority of an output. If nothing else is set, outputs are added as they request to be added and have a numerical priority of -1. Using prio <n> it is possible to set priorities for outputs, where <n> >= 1. The larger <n> is, the higher the priority is, that is to say, the earlier the output will appear in the list of outputs.
- rotate <n> is used to rotate the output by `<n> mod 4 x 90` degrees counter-clockwise.
# Don't rotate output DP-1 rotate 0 # rotate 90 degrees counter-clockwise output DP-1 rotate 1 # rotate 180 degrees counter-clockwise output DP-1 rotate 2 # rotate 270 degrees counter-clockwise output DP-1 rotate 3
- output addresses outputs by their name and is vaguely symmetric to input.
- Any screen command deals with the number identifying a monitor within a Cagebreak session either explicitly or implicitly (i.e. the commands containing next and prev).
prev
prevscreen
quit
resizedown
resizeleft
resizeright
resizeup
screen <n>
show_info
setmode <mode>
switchvt <n>
time
vsplit
workspace <n>
workspaces <n>
MODES¶
By default, three modes are defined:
top
- definekey can be used to set keybindings for top mode.
- setmode can be used to set a different default mode.
root
- •
- bind can be used to set keybindings for root mode.
resize
definemode can be used to create additional modes.
KEY DEFINITIONS¶
Keys are specified by their names as displayed for example by xev.
Modifiers can be specified using the following syntax:
The supported modifiers are:
A - Alt
C - Control
L - Logo
S - Shift
2 - Mod 2
3 - Mod 3
5 - Mod 5
For example to specify the keybinding Control+t, the expression
C-t
is used.
SEE ALSO¶
BUGS¶
See GitHub Issues: <https://github.com/project-repo/cagebreak/issues>
Mail contact: `cagebreak @ project-repo . co`
GPG Fingerprints:
- 0A268C188D7949FEB39FD1462F2AD980247E4918
- 283D10F54201B0C6CCEE2C561DE04E4B056C749D
LICENSE¶
Copyright (c) 2020-2024 The Cagebreak authors
Copyright (c) 2018-2020 Jente Hidskes
Copyright (c) 2019 The Sway authors
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2024-01-27 | Version 2.3.1 |