I switched repositories for my Gnome installation to the LATEST STABLE GNOME 3.8 http://download.opensuse.org/repositories/GNOME:/STABLE:/3.8/openSUSE_12.3

After updating to Gnome 3.8, I was then unable to edit my Gnome menu via the alacarte program/script. I then decided to query the forums, and found a link to this one here:

When clicking on the “New Item” button, there was no response from Alacarte. I then went about debugging, executing the program via a terminal, to investigate program output.

The error I was getting was getting was as below:

File "/usr/lib/python2.7/site-packages/Alacarte/MainWindow.py", line 258, in on_new_item_button_clicked
editor = LauncherEditor(self.main_window, file_path)
AttributeError: 'MainWindow' object has no attribute 'main_window'

I then went about editing the script /usr/lib/python2.7/site-packages/Alacarte/MainWindow.py

Use vi to edit the script as below

sudo vi /usr/lib/python2.7/site-packages/Alacarte/MainWindow.py

Add a new line after line 54, to define the missing main_window member:

55 self.main_window = None
Added new member to MainWindow class (main_window)

Added new member to MainWindow class (main_window)

Edit the Run method, to initialize the new member as below. Add a new line after line 66. The number displayed in the code is just a line number, please omit that in your edit

67 self.main_window = self.tree.get_object('mainwindow')
Assigned the Gtk main window to the newly added main_window member

Assigned the Gtk main window to the newly added main_window member

Save and exit the script. Now execute the alacarte program, and attempt to edit your menus

NB: What I did find though is that the newly added menu items, via this procedure, aren’t displayed in alacarte main window, but you’re able to find them in your start/activities menu.

(Visited 1 times, 1 visits today)
Tags: ,
Category: Desktop, SUSE Linux Enterprise Desktop, Technical Solutions
This entry was posted Thursday, 21 November, 2013 at 11:15 am
You can follow any responses to this entry via RSS.

Leave a Reply

Your email address will not be published. Required fields are marked *

No comments yet