Recover your full Logout menu

How to do things, solutions, recipes, tutorials
Post Reply
Message
Author
vg1
Posts: 142
Joined: Sun 02 Dec 2007, 18:56

Recover your full Logout menu

#1 Post by vg1 »

In puppy420 the shutdown/logout menu has been replaced by a shutdown dialog. The dialog has some advantage if you wish to add more actions/buttons & distribute them accross several tabs. It may look more elegant to some. It also requires a few more clicks than the menu type. And it uses more resources being a gtk dialog, although it only happens at shutdown. This may make a difference on a slower pc.
If, like me, you prefer the old menu type and want it back, read on. And there's no reason why you should not have both.

Here is a simple tweak I did to get my logout menu back. While I was at it I also added an icewm-lite option, ie running icewm only, without the tray. So I have a choice to run it with or without the tray. Again, can save some resorces on a slower pc. So here goes

NOTE: before any changes make a backup on full installs. Not required for frugal:

1. copy /usr/bin/jwm2icewm as jwm2icewm1

2. edit jwm2icewm1 with a text editor & change:

Code: Select all

cp /usr/share/icewm/jwm2icewm/windowmanager /etc/windowmanager
to

Code: Select all

cp /usr/share/icewm/jwm2icewm/windowmanager1 /etc/windowmanager
ie add a '1' to the 1st 'windowmanager'.

Save the file & make it executable. For me the easiest way is to right-click it, select properties, and click the exec column.

3. copy /usr/share/icewm/jwm2icewm/windowmanager as windowmanager1

4. edit widowmanager1: change

Code: Select all

 icewm-session
to

Code: Select all

 icewm
& save the file.

5. open /etc/xdg/templates/_root_.jwmrc in a text editor, delete this line [line 30 in my case]:

Code: Select all

  <Program label="Shutdown" icon="shutdown24.png">exec /usr/bin/shutdownjwm</Program>
and replace it with this:

Code: Select all

 <Menu label="Shutdown" icon="shutdown24.png" height="16">
   <Exit confirm="false" label="Exit to prompt" icon="prompt16.xpm" />
   <Program label="Reboot computer" icon="mini-turn.xpm">exec /usr/X11R7/bin/wmreboot</Program>
   <Program label="Power-off computer" icon="mini-stop.xpm">exec /usr/X11R7/bin/wmpoweroff</Program>
   <Program label="Restart X server" icon="mini-x.xpm">restartwm</Program>
   <Program label="Restart with IceWM&tray" icon="mini-windows.xpm">jwm2icewm</Program>
   <Program label="Restart with IceWM-lite" icon="mini-windows.xpm">jwm2icewm1</Program>
   <Restart label="Restart JWM" icon="mini-windows.xpm"/>
<Program label="  Shutdown" icon="shutdown24.png">exec /usr/bin/shutdownjwm</Program>   
  </Menu>

Save the file.

6. open /etc/xdg/templates/_root_.icewm_menu in a text editor, delete the last line [line 55 in my case]:

Code: Select all

 prog "Shutdown" shutdown24 /usr/bin/shutdown
and replace it with this:

Code: Select all

menu "Shutdown" shutdown24 {
prog "Exit to Prompt" prompt16 killall X
prog "Reboot" mini-turn wmreboot
prog "Shutdown" shutdown24 wmpoweroff
	restart "Restart with Fluxbox" mini-windows startfluxbox
	restart "Restart with Blackbox" mini-windows startblackbox
	restart "Temp switch to JWM" mini-windows jwm
	restart "Restart with JWM" mini-windows icewm2jwm
	restart "Restart IceWM" mini-windows icewm
	restart "Restart with Xfce4" mini-windows xfce4-session
	prog "Restart X server" mini-x restartwm
	prog "Shutdown" shutdown24 /usr/bin/shutdown
}
Save the file.

7. Refresh menus & you're done.

Unless there's a typo in the entries above you should now have a full logout menu in both jwm & icewm, and still have the new shutdown dialog available as the last entry in the menu. You can change it to first if you like. It just sits there without using any resources at all until you click it. In addition, in jwm you have the choice to run full icewm & tray, or the slim & fast version without the tray. The fluxbox, balckbox & xfce entries will only appear if you have these wms installed.

In my case all the icons appear correctly in the logout menu. If they don't for you then you will have to adjust their names in the added code to the actual icon names in your puppy.

Of course, as always the above steps can be done in different ways [the copying, making executable etc]. They all produce the same result, these are the simplest for me.

To each his own - I hope you enjoy it.

regards
vg

straypup
Posts: 47
Joined: Mon 04 Feb 2008, 00:17

#2 Post by straypup »

Any chance of a .pet for the command challenged?
Thanks stray :oops:

vg1
Posts: 142
Joined: Sun 02 Dec 2007, 18:56

#3 Post by vg1 »

Here it is. Please confirm if it works as expected.

ps- in icewm adding this to prefoverride:
ShowLogoutMenu=1
will show a simple logout menu.

regards
vg
Attachments
logout_menu.pet
Full shutdown menu for jwm &amp; icewm
(2.93 KiB) Downloaded 492 times

straypup
Posts: 47
Joined: Mon 04 Feb 2008, 00:17

#4 Post by straypup »

Worked very nicely. Thanks.
stray :D :D :D

Post Reply