Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sat 20 Sep 2014, 02:10
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
9menu - creates menus from the command line
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [8 Posts]  
Author Message
stu90


Joined: 25 Feb 2010
Posts: 1401
Location: England. Dell Inspiron 1501. Dpup

PostPosted: Wed 23 May 2012, 07:47    Post subject:  9menu - creates menus from the command line  

Here is a .pet for the application 9menu
http://pwet.fr/man/linux/commandes/9menu
Quote:
9menu is a simple program that accepts a list of menu item and command pairs on the command line. It creates a window that consists of nothing but a menu. When a particular item is selected, the corresponding command is executed.


How to use:
9menu -file "/path/to/menu/file"

In menu file:
menu item : command
menu item : command


example:
9menu-1.8.5.pet
Description 
pet

 Download 
Filename  9menu-1.8.5.pet 
Filesize  7.99 KB 
Downloaded  274 Time(s) 
Back to top
View user's profile Send private message 
penguinpowerppp

Joined: 14 Apr 2012
Posts: 5

PostPosted: Thu 24 May 2012, 20:53    Post subject:  

This uses 9menu for an app menu
http://www.murga-linux.com/puppy/viewtopic.php?t=77660
Back to top
View user's profile Send private message 
harii4


Joined: 30 Jan 2009
Posts: 444
Location: La Porte City, IA , U.S.A.

PostPosted: Thu 24 May 2012, 22:14    Post subject:  

@stu90
Hope you don't mind if i post an 9menu example? Smile
examples of 9menu are hard to come by and someone might find them useful?

I start mine as scripts.
sample "inet.sh" place in my-applications/bin


Code:
#!/bin/sh

9menu -geometry 150x66+300+16 -bg "#000000" -fg "#F2EDD7" -font "-*-lucidatypewriter-*-*-*-*-10-*-*-*-*-*-*-*" -popup -label 'Internet' \
"links2":"xlinks2 &" \
"Dillo Browser":"dillo \"$@\" &" \
"Safer Browser":"SafeBrowse &" \
"FireFox":"/lib/firefox/firefox \"$@\" &" \
----------:inet.sh \
"gFTP":"gftp &" \
"PMirrorget":"pmwget &" \
"VOIP + IM":"psip &" \
"Podcast-Grab":"/usr/local/bin/ppg-gui.sh &" \
"downloader":"pwsget &" \
"Transmission":"transmission &" \
----------:inet.sh \
Close:exit


\ = line wrap around - system sees it as one long line of text.

thank you for the 9menu pet. Very Happy

_________________
3.01 Fat Free / Fire Hydrant featherweight/ TXZ_pup / 431JP2012
----------------------------------------------------------------------------------------
Peace and Justice are two sides of the same coin.
Back to top
View user's profile Send private message Visit poster's website 
stu90


Joined: 25 Feb 2010
Posts: 1401
Location: England. Dell Inspiron 1501. Dpup

PostPosted: Sat 26 May 2012, 11:13    Post subject:  

harii4 wrote:
@stu90
Hope you don't mind if i post an 9menu example? Smile
examples of 9menu are hard to come by and someone might find them useful?

I start mine as scripts.
sample "inet.sh" place in my-applications/bin


Code:
#!/bin/sh

9menu -geometry 150x66+300+16 -bg "#000000" -fg "#F2EDD7" -font "-*-lucidatypewriter-*-*-*-*-10-*-*-*-*-*-*-*" -popup -label 'Internet' \
"links2":"xlinks2 &" \
"Dillo Browser":"dillo \"$@\" &" \
"Safer Browser":"SafeBrowse &" \
"FireFox":"/lib/firefox/firefox \"$@\" &" \
----------:inet.sh \
"gFTP":"gftp &" \
"PMirrorget":"pmwget &" \
"VOIP + IM":"psip &" \
"Podcast-Grab":"/usr/local/bin/ppg-gui.sh &" \
"downloader":"pwsget &" \
"Transmission":"transmission &" \
----------:inet.sh \
Close:exit


\ = line wrap around - system sees it as one long line of text.

thank you for the 9menu pet. Very Happy


Hi harii4,
Yes feel free to post how you use 9menu Cool

I use it like this:

in script 9main located in /usr/bin i have:
Code:
#!/bin/sh
9menu -label "Main Menu" -warp -popdown -geometry "0+0"  -bg "#5A5A5A" -fg "#D4D4D4" -font "-misc-fixed-medium-r-normal-*-14-*-*-*-*-*-*-*"  -file "$@" 


Then in a plain .txt file menu1.txt i have the menu some thing like this (you dont need to line break or escaped characters):
Code:

==============
| Terminal   |: urxvt
| Browser    |: defaultbrowser
| Links      |: urxvt -e links
| Editor     |: geany
| MOCP       |: urxvt -e mocp
| Streams    |: urxvt -e tradio
| Media      |: urxvt -e tmedia   
==============
 


to use i add an Alt + key bindings to openbox which is: 9main /path/to/menu1.txt

I do it this way so i can have different menus but with the same set up and colours.

thanks.
Back to top
View user's profile Send private message 
harii4


Joined: 30 Jan 2009
Posts: 444
Location: La Porte City, IA , U.S.A.

PostPosted: Sat 02 Jun 2012, 19:55    Post subject:  

when -popdown option is used the script keeps running in the background long after it launches the picked app. to run?
when using -popup the script closes itself after launching the app.

Just an reminder for window managers that don't "iconify the menu"
- popdown
like evilwm and cwm

Code:
)    (( Archive  ))    (:file-roller %U
)    (( Calc.    ))    (:xcalc
)    (( Calendar ))    (:osmo
)    (( CLI apps ))    (:gedit ./cliapps
)    (( Clock    ))    (:xclock -digital -fg "#000000" -bg "#00ffff" -hl "#000000" -bd "#00ffff" -update 1 -twentyfour -padding 6
)    (( Education))    (:tuxtype
)    (( Files M  ))    (:nautilus
)    (( Image V  ))    (:mirage
)    (( Internet ))    (:./firefox/firefox
)    (( Media    ))    (:vlc
)    (( Search   ))    (:gnome-search-tool
)    (( prtScrn  ))    (:./pic
)    (( Sys Mon  ))    (:xterm -fn "-*-fixed-*-r-*-*-14-*-*-*-*-*-*-*" -fg cyan  -bg black -geometry 100x42+49+23 htop
)    (( Terminal ))    (:gnome-terminal
)    (( Text     ))    (:gedit
)    (( charact  ))    (:gucharmap
========================
)(Extra Browsers)(
========================
)    (( Chromium ))    (:chromium-browser
)    (( ChromiumI))    (:chromium-browser -incognito
)    (( Elinks   ))    (:xterm -fn "-*-fixed-*-r-*-*-14-*-*-*-*-*-*-*" -fg cyan  -bg black -geometry 100x42+49+23 elinks
)    (( Links2   ))    (:xlinks2
========================
)(Systems Tools)(
========================
)    (( Conky    ))    (:./conky
)    (( Ccsm     ))    (:ccsm
)    (( Disk Utl.))    (:gksu palimpsest
)    (( Gdmsetup ))    (:gksu gdmsetup
)    (( Gconf    ))    (:gconf-editor
)    (( Icons    ))    (:MagIcons
)    (( Synaptic ))    (:gksudo synaptic
)    (( Theme ch ))    (:/usr/bin/gtk-chtheme
========================
)(  LogOut  )(:killall compiz
)(  Wifi  )(:gksudo ./wifi
)(  Shutdown  )(:gdmflexiserver
========================
   ( Close )  :exit

you can really dress the 9menu up
from:
http://www.necopost.com/2011/11/awesome-lightweight-menu-for-your-linux.html

_________________
3.01 Fat Free / Fire Hydrant featherweight/ TXZ_pup / 431JP2012
----------------------------------------------------------------------------------------
Peace and Justice are two sides of the same coin.
Back to top
View user's profile Send private message Visit poster's website 
stu90


Joined: 25 Feb 2010
Posts: 1401
Location: England. Dell Inspiron 1501. Dpup

PostPosted: Sun 03 Jun 2012, 13:04    Post subject:  

Hi harii4,
Yes with the -popdown option after a menu item is selected the menu is minimized but not closed.
Also the -warp option will move the mouse into the menu over the last menu selection.
Back to top
View user's profile Send private message 
technosaurus


Joined: 18 May 2008
Posts: 4351

PostPosted: Mon 04 Jun 2012, 00:20    Post subject:  

here is a static build against musl libc and tinyx11 with latest debian patches (The binary may be larger, but the resource usage is much lower)
9menu-1.8.tar.gz
Description 
gz

 Download 
Filename  9menu-1.8.tar.gz 
Filesize  54.62 KB 
Downloaded  245 Time(s) 

_________________
Web Programming - Pet Packaging 100 & 101
Back to top
View user's profile Send private message 
Gnuxo

Joined: 09 Feb 2012
Posts: 365

PostPosted: Mon 11 Jun 2012, 02:32    Post subject:  

I love this program.

The menus look so cool. I usually use it with oroborus.

Haven't installed any other WMs in a long time though.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [8 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0769s ][ Queries: 13 (0.0050s) ][ GZIP on ]