This here is a KWin script that makes Konsole behave more like Guake does.
- Clone this repository
git clone https://github.com/pschmitt/kwin-konsole-scratchpad.git
cd ./kwin-konsole-scratchpad
- Choose one of the following two install paths:
- Shortcut only (recommended)
- KWin script
- Setup a custom shortcut that triggers
./konsole-scratchpad.sh
(Optional flags available. See./konsole-scratchpad.sh --help
). - Set up a scratchpad service (see below)
- Optional Install uglifyjs to make the loading of the script a tiny bit faster
- Edit settings in
./contents/code/main.js
- Run
./install.sh
- Open System Settings:
Window Management > KWin Scripts
and make sure that "Konsole Scratchpad" is enabled - Setup a custom key binding for "Toggle Konsole Scratchpad"
- Set up a scratchpad service (see below)
Since this script is mainly intended to have a Konsole window stick to the bottom of the screen and show/hide on a keypress I suggest you autostart konsole via one of the following methods:
See ./extra/konsole-scratchpad.desktop
To install:
cp ./extra/konsole-scratchpad.desktop ~/.config/autostart
See ./extra/konsole-scratchpad.service
To install:
cp ./extra/konsole-scratchpad.service ~/.config/systemd/user
systemctl --user enable --now konsole-scratchpad.service
Once done you should be able to show/hide your Konsole scratchpad with the "Toggle Konsole Scratchpad" shortcut (F1 by default)
For this script to work reliably you need to ensure that Konsole's window/tab
title contains the caption
set in
./contents/code/main.js.
To do this you can either:
- set a static title in your Konsole profile
- make the startup program set it at runtime (provided that in your Konsole
profile the "Tab Title Format" contains
%w
) with:
title="scratchpad"
echo -ne "\e]0;${title}\a"
- Run
./uninstall.sh
- Restart KWin 🤷