add rofi-rbw tooling

This commit is contained in:
Joel Beckmeyer 2023-07-28 09:18:09 -04:00
parent c33b936f84
commit 08e7bb2f31
2 changed files with 28 additions and 0 deletions

View File

@ -0,0 +1,14 @@
#!/bin/sh
current_layout=$(dbus-send --print-reply=literal --dest=org.kde.keyboard \
/Layouts org.kde.KeyboardLayouts.getLayout | xargs | tr " " ":")
trap reset_layout 1 2 3 6 15
reset_layout() {
dbus-send --type=method_call --dest=org.kde.keyboard /Layouts org.kde.KeyboardLayouts.setLayout "$current_layout"
}
dbus-send --type=method_call --dest=org.kde.keyboard /Layouts org.kde.KeyboardLayouts.setLayout uint32:0
rofi-rbw --typer=dotool
reset_layout

View File

@ -0,0 +1,14 @@
#!/bin/sh
current_layout=$(dbus-send --print-reply=literal --dest=org.kde.keyboard \
/Layouts org.kde.KeyboardLayouts.getLayout | xargs | tr " " ":")
trap reset_layout 1 2 3 6 15
reset_layout() {
dbus-send --type=method_call --dest=org.kde.keyboard /Layouts org.kde.KeyboardLayouts.setLayout "$current_layout"
}
dbus-send --type=method_call --dest=org.kde.keyboard /Layouts org.kde.KeyboardLayouts.setLayout uint32:0
rofi-rbw --typer=dotool --target=totp
reset_layout