Page 1 of 1

Better way to manage my Ubuntu main menu...

Posted: Sat Mar 12, 2011 11:12 am
by Isaac
Here's what you do!
Open ~/.config/menus/applications.menu in your text editor of choice

then find the menu you want to add stuff to, like "Office".

You'll see

Code: Select all

<Menu>
	<Name>Office</Name>
	<Include>
		<Filename>Dia Diagram Editor.desktop</Filename>
	
	</Include>
	
	
	<Exclude>
		<Filename>gnome-dictionary.desktop</Filename>
	</Exclude>
	<AppDir>/home/isaac/.local/share/applications</AppDir>
	<Exclude>
		<Filename>evolution.desktop</Filename>
	</Exclude>
</Menu>
Find your .desktop files you want to move over like this:

Code: Select all


		<Filename>wine-Programs-Microsoft Office-Microsoft Office Word 2007.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office Excel 2007.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office Access 2007.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office PowerPoint 2007.desktop</Filename>
Place them within the <include> tags.

I can just use this line of text "<Filename>wine-Programs-Microsoft Office-Microsoft Office ______ 2007.desktop</Filename>" and replace the "_____" with the application name, so this is really easy editing. The icon and everything is correct once I'm done.

Code: Select all

<Menu>
	<Name>Office</Name>
	<Include>
		<Filename>Dia Diagram Editor.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office Word 2007.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office Excel 2007.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office Access 2007.desktop</Filename>
		<Filename>wine-Programs-Microsoft Office-Microsoft Office PowerPoint 2007.desktop</Filename>
	</Include>
	
	
	<Exclude>
		<Filename>gnome-dictionary.desktop</Filename>
	</Exclude>
	<AppDir>/home/isaac/.local/share/applications</AppDir>
	<Exclude>
		<Filename>evolution.desktop</Filename>
	</Exclude>
</Menu>
The effects are instant! You can separators and whatever you want. This file is very easy to play with.

I might make a Python app that handles it better than the regular edit menu does, however, this file isn't hard to use.

In case anyone was wondering, I took these screenshots using $ gnome-screenshot --delay 10

Re: Better way to manage my Ubuntu main menu...

Posted: Sat Mar 12, 2011 2:21 pm
by Jeff250
I didn't even know about being able to set a timer with gnome-screenshot or that Office 2007 even works with wine. :P I lost track of wine, but it seems like they're making good progress.
Isaac wrote:I might make a Python app that handles it better than the regular edit menu does, however, this file isn't hard to use.
Alacarte, the regular "menu edit" tool, is written in python, so you might think about how to enhance it instead.

Re: Better way to manage my Ubuntu main menu...

Posted: Sat Mar 12, 2011 2:32 pm
by Isaac
Yeah, it runs great in wine, even though I'm using a little netbook!
Jeff250 wrote:Alacarte, the regular "menu edit" tool, is written in python, so you might think about how to enhance it instead.
That's an awesome idea! Thanks!

Re: Better way to manage my Ubuntu main menu...

Posted: Sun Mar 13, 2011 12:54 pm
by snoopy
I have never liked the way that Gnome does menu icons. It's a pain to edit, because the shortcuts can exist in one of like 4 places. I went through this multiple times when I wanted to remove all of the icons that wine created when you ran an install.

Openbox relies on a single xml file, which has nice editing tools like obmenu. Also, it does pipe menus (on-demand menu generation, based on execution of a script.) I could go on but I guess I'm de-railing. I just wish that menu editing in gnome didn't require a tutorial every time you wanted to make a tweak.

Re: Better way to manage my Ubuntu main menu...

Posted: Sun Mar 13, 2011 2:01 pm
by Isaac
Yeah, the menu editor could use improvement, but it seems like an easy thing to improve on. I mean, it's more tedious than complicated, which is almost good news to programmers.

edit:
It probably wouldn't take much to make the editor work better.

Re: Better way to manage my Ubuntu main menu...

Posted: Sun Mar 13, 2011 4:09 pm
by Jeff250
Isaac wrote:It probably wouldn't take much to make the editor work better.
Talk is cheap. :P

Re: Better way to manage my Ubuntu main menu...

Posted: Sun Mar 13, 2011 6:16 pm
by Isaac
:twisted: hmmmmmmm....