| Author |
Message |
sunburnt

Joined: 08 Jun 2005 Posts: 4001 Location: Arizona, U.S.A.
|
Posted: Thu 25 Mar 2010, 23:53 Post subject:
.desktop file is supposed to make Menu entry? [Solved] |
|
Here`s a file I made and put in: /use/share/applications/driveman.desktop
| Code: | [Desktop Entry]
Encoding=UTF-8
Name=DriveMan Drive Manager
Icon=mini-fdisk
Comment=DriveMan Drive Manager
Exec=/root/my-applications/driveman/driveman
Terminal=false
Type=Application
Categories=X-FilesystemMount
GenericName=DriveMan Drive Manager |
Nothing is added to the Puppy Menu.
I don`t see how it adds itself to a sub menu, no mention of it that I can see...
Do I really have to add a line to: /root/.jwmrc like this:
| Code: | JWMRC=$(</root/.jwmrc)
H=`echo "$JWMRC" |head -$((`echo "$JWMRC" |grep -n Filesystem |sed 's/:.*$//'`+1))`
T=`echo "$JWMRC" |tail +$(($N+1))`
M='<Program label=" DriveMan Drive Manager" icon="mini-fdisk">/root/my-applications/driveman/driveman</Program>'
echo -e "$H\\n$M\\n$T" > /root/.jwmrc |
Last edited by sunburnt on Sun 04 Apr 2010, 16:54; edited 1 time in total
|
|
Back to top
|
|
 |
8-bit

Joined: 03 Apr 2007 Posts: 3012 Location: Oregon
|
Posted: Fri 26 Mar 2010, 00:10 Post subject:
|
|
Depending on the version of Puppy you may have to open a terminal, type "fixmenus" and then restart JWM.
Puppy 431 will automatically do it IF the program is installed as a PET.
|
|
Back to top
|
|
 |
sunburnt

Joined: 08 Jun 2005 Posts: 4001 Location: Arizona, U.S.A.
|
Posted: Fri 26 Mar 2010, 00:25 Post subject:
|
|
I rebooted just to be sure, apparently there`s something I`m missing ( Wow... That`s new... ).
I never did understand how the .desktop files generated Menu entries.
I get how the .desktop files are used to add entries to the default Puppy menu in: /root.jwmrc
But as I said, I see no info. in the .desktop file about how they are placed in the menu.
Somehow I would think it would have to reference the sub-menu it`s to go in.
|
|
Back to top
|
|
 |
Pizzasgood

Joined: 04 May 2005 Posts: 6270 Location: Knoxville, TN, USA
|
Posted: Fri 26 Mar 2010, 01:20 Post subject:
|
|
It's based on the category. Which category belongs to which menu is listed in /etc/xdg/menus/hierarchy. The fixmenus script uses the stuff in /etc/xdg/templates and /etc/xdg/menus to create the menu file that you get in ~/. Depending on which WM is being used, I believe fixmenus also uses jwm-xdgmenu, icewm-xdgmenu, etc.
I just tested the desktop file you posted and it worked for me (4.1.2). Except, in your post you said it was under the "use" directory, instead of "usr". I assume that was just a typo in your post, and that you did in fact place it under "usr".
Make sure you run fixmenus.
_________________ Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib

|
|
Back to top
|
|
 |
sunburnt

Joined: 08 Jun 2005 Posts: 4001 Location: Arizona, U.S.A.
|
Posted: Fri 26 Mar 2010, 02:25 Post subject:
|
|
Thanks for the tutorial Pizzasgood; I always appreciate the help!
I knew the menu setup was rather complex and used many files to do it`s thing.
Fixed an error, the .desktop file had, no "xpm" extention on the icon file name. Looks great!
I set my app. to copy the .desktop file, fix the menus, and restart jwm.
And yes... The "e" key is too close to the "r" key for rapid typing.
|
|
Back to top
|
|
 |
|