Re: Running menu-editor with python-2.3



Right, this is similar to the patch I was going to post to get menu-editor to run with python-2.3.

A couple of other notes. On my SuSE system at least, menu-editor uses ~/.config/menu/applications.menu to load its initial menu structure. Such did not exist and so it created one for me. The contents of the created file point to /etc/xdg/menu/applications.menu. But unless you compile garnome with --sysconf=/etc, this is not correct. I modified my ~/.config/menu/applications.menu to point to /home/rintoul/garnome/etc/xdg/menu/applications.menu (I installed garnome in my home directory). From that point on I could use menu-editor to modify my menus.

Note that menu-editor does not actually change the system menu files (/home/rintoul/garnome/etc/xdg/menu/applications.menu in my case) unless you are root. All changes to the system menu are stored in ~/.local/share/applications.

Another thing to note, menu-editor cannot change the "categories" ie the main menu items. It just seems to manage the applications which appear and each category. Also you cannot seem to add submenus.

Hope this helps.

Doug.
Joseph E. Sacco, Ph.D. wrote:
In order to run menu-editor with python-2.3, you will need a definition
for the function rsplit(), which is now part of the string module in
python-2.4.

This works:

def rsplit(string, sep, count=-1):
   L = [part[::-1] for part in string[::-1].split(sep[::-1], count)]
   L.reverse()
   return L

If you are using python-2.3 and wish to experiment with
menu-editor-0.4.3
	http://dev.realistanew.com/menu-editor/

add this function definition to the menu-editor script after the line

	import gtk

-Joseph






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]