You are not logged in.
Pages: 1
Anyone want to try out a new pipemenu? It displays all your Openbox keybinds, and also can open rc.xml for editing after first making a backup.
obkb-pipemenu.py can be run in a terminal on its own, when it writes the keybinds to screen. They are saved in a textfile first (.config/openbox/kbinds.txt), which is what is read by the pipemenu.
If the textfile doesn't exist then the pipemenu runs the python script first.
EDIT: Now with added clickability! This only applies to menu items that have <action name=Execute>; those with Openbox window commands just close the menu.
You can get the scripts from my github
bl-kb-pipemenu
obkb-pipemenu.py
(Choose "Raw" and C&P in a text editor)
(If you just want a standalone script which displays your keybinds in a zenity text dialog or the terminal, then try
obkb.py )
I'd appreciate some feedback; and if you have suggestions about improving the code, then by all means say so
Last edited by damo (2015-04-08 13:57:14)
BunsenLabs Group on deviantArt
damo's gallery on deviantArt
Openbox themes
Forum Moderator
Offline
I have an older obkb.py and obkb2.py soooooooo #3 ... but
07 Apr 15 | 17:22:40 ~
$ obkb3.py
File "/home/sector11/bin/obkb3.py", line 34
from lxml import etree
^
IndentationError: expected an indented block
07 Apr 15 | 17:22:47 ~
$
In Waldorf does that make a difference? First two work.
Will try in Jessie later today.
EDIT: Result the same in Jessie.
· ↓ ↓ ↓ ↓ ↓ ↓ ·
BunsenLabs Forums now Open for Registration
· ↑ ↑ ↑ ↑ ↑ ↑ · BL ModSquad
Offline
are the pipemenu entries clickable? meaning, do they execute the actual keybind? that would be cool.
i once did sth similar:
http://crunchbang.org/forums/viewtopic.php?id=29997
Offline
I have an older obkb.py and obkb2.py soooooooo #3 ... but
07 Apr 15 | 17:22:40 ~ $ obkb3.py File "/home/sector11/bin/obkb3.py", line 34 from lxml import etree ^ IndentationError: expected an indented block 07 Apr 15 | 17:22:47 ~ $
In Waldorf does that make a difference? First two work.
Will try in Jessie later today.
EDIT: Result the same in Jessie.
You have an indentation error in the script. Python uses indents as part of the syntax, so that line should match the rest. One tab per indent, or 4 spaces per indent are commonly used.
Turn on whitespace in geany to see what is happening in your copy of the script.
BunsenLabs Group on deviantArt
damo's gallery on deviantArt
Openbox themes
Forum Moderator
Offline
are the pipemenu entries clickable? meaning, do they execute the actual keybind? that would be cool.
i once did sth similar:
http://crunchbang.org/forums/viewtopic.php?id=29997
I also did obkb.py which displays keybinds in a terminal or in a zenity text dialog. The pipemenu uses the output from the same script (slightly edited to take out the text formatting).
I tried it with clickable items. It works great for <command>bash command</command>, but throws up errors for the Openbox commands. I decided to use "echo >/dev/null 2>&1" as the menu item command, so the menu just closes.
Maybe version 2 will be clickable! (I'm working on it )
EDIT: In the meantime, if you want clickable menu items for those that have "<action name="Execute">", edit the bl-kb-pipemenu at line 51
# menuItem "$curItem" "echo >/dev/null 2>&1" #<command> closes menu on screen
menuItem "$curItem" "$b" #<command> uses command/execute
EDIT 2 : I really should get round to changing the deprecated <execute> to <command> in my rc.xml's :8
Last edited by damo (2015-04-07 22:01:27)
BunsenLabs Group on deviantArt
damo's gallery on deviantArt
Openbox themes
Forum Moderator
Offline
EDIT: Now with added clickability!
BunsenLabs Group on deviantArt
damo's gallery on deviantArt
Openbox themes
Forum Moderator
Offline
Pages: 1
Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: acrobat