You are not logged in.
Traceback (most recent call last):
File "obiconadder.py", line 72, in <module>
if getIconTheme() != None : iconDirs.append("/usr/share/icons/" + getIconTheme() + "/48x48")
File "obiconadder.py", line 49, in getIconTheme
contents = contents.split("\n")
UnboundLocalError: local variable 'contents' referenced before assignment
Offline
Whoops. Fixed.
Offline
Nearly perfect!
Last edited by tekkkz (2015-09-27 13:55:53)
Offline
Any more bugs/issues with it?
Offline
It cant find sth for KCalc cause its something with -calculator for it
Offline
Hmmm. According to the .desktop file it needs accessories-calculator which for me is available as /usr/share/icons/gnome/48x48/apps/accessories-calculator.png. The .desktop check doesn't look like it should fail - there should be a match between kcalc in your menu file and Exec=kcalc in the .desktop. Perhaps your icon theme doesn't provide that icon.
What I'll do is always add the gnome-icon-theme dir if it exists. That should take care of any missing icons.
Offline
yap tell me when fixed
Offline
With any luck, I think it should be fixed now.
Edit: I tested it by putting the kcalc .desktop file in my /usr/share/applications and the script successfully picked up the icon for kcalc and added it to the test menu file so I think that's been taken care of.
Anyway, this thread has gotten rather long and cumbersome but the long and the short of it is, if you're looking to add icons to an existing Openbox menu file without throwing away the old contents, you can try my script linked to in post #19. Also see the suggestion in post #14.
Last edited by Chazza (2015-09-27 15:23:26)
Offline
you have to install gtk2-perl to obmenu-generator get the icons
Offline
This thread is six years old. Please do not necrobump.
Closing.
Offline