Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (9) </ ... 4 5 6 7 8 [9] >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: A TWM for Open DSL< Next Oldest | Next Newest >
henk1955 Offline





Group: Members
Posts: 249
Joined: June 2004
Posted: Jan. 15 2005,21:59 QUOTE

Code Sample
defmenu("mainmenu", {
 submenu("Apps", {
   submenu("Editors", {
     menuentry("Beaver", make_exec_fn('beaver')),
     menuentry("Vim", make_exec_fn('rxvt -rv -e vi')),
     menuentry("Nano", make_exec_fn('rxvt -rv -T "Nano" -e nano-tiny')),      
     }),
   submenu("Graphics", {
     menuentry("xzgv Image Viewer", make_exec_fn('/usr/bin/xzgv')),
     menuentry("Xpaint", make_exec_fn('/usr/bin/X11/xpaint')),
     }),
   submenu("Office", {
     menuentry("Pathetic Writer", make_exec_fn('/usr/local/bin/pw')),
     menuentry("Siag Spreadsheet", make_exec_fn('/usr/local/bin/siag')),
     menuentry("Xpdf", make_exec_fn('/usr/local/bin/xpdf')),
     menuentry("Xcalc", make_exec_fn('xcalc')),
     menuentry("SQLite Book", make_exec_fn('/usr/local/bin/sqlitebook.pl')),    
     menuentry("PIM using Index", make_exec_fn(' rxvt -rv -T "PIM using Index" -e /usr/bin/index')),      
     menuentry("Net Dictionary", make_exec_fn(' rxvt -rv -T "Internet Dictionary" -e /usr/local/bin/getword')),      
     }),
   submenu("Sound/MPEG/VoIP", {
     menuentry("gPhone", make_exec_fn('gphone')),
     submenu("XMMS", {
       menuentry("Xmms Audio/MPEG", make_exec_fn('xmms')),
       menuentry("Xmms Play CD", make_exec_fn('xmms /dev/cdrom')),
       menuentry("Download High Bandwidth Mp3 Streams", make_exec_fn('rxvt -rv -T "Grabbing streams..." -e /opt/.xmms_streams_grab.sh highbandwidth')),
       menuentry("Download Low Bandwidth Mp3 Streams", make_exec_fn('rxvt -rv -T "Grabbing streams..." -e /opt/.xmms_streams_grab.sh lowbandwidth')),
       submenu("Xmms News Feeds", {
         menuentry("Xmms Play 'The Linux Show'", make_exec_fn('xmms  http://audio.ibiblio.org:8000/linuxlive')),
         menuentry("Xmms 'KCPW NPR News'", make_exec_fn('xmms  http://kcpw.xmission.com:80/kcpw.ogg')),
         menuentry("Xmms 'CBC Radio One News'", make_exec_fn('xmms  http://oggtrial.nm.cbc.ca:80/cbcr1-toronto.ogg')),
       }),
       menuentry("wMix", make_exec_fn('wmix')),
     }),
   }),
 }),
 menuentry("Help", querylib.query_man),
 menuentry("About Ion", querylib.show_aboutmsg),
 submenu("Styles", "stylemenu"),
 submenu("Exit", {
   --menuentry("Restart", querylib.query_restart),
   menuentry("Restart", restart_wm),
   menuentry("Restart Fluxbox", function() restart_other_wm("fluxbox") end),
   --menuentry("Exit", querylib.query_exit),
   menuentry("Exit", exit_wm),
 }),
})

this part of the fluxbox menu i convertetd by hand.
you can see it is linear.

there is only ONE defmenu

the syntax is:
defmenu( "menuname", {
 menuentry(" menuentry title", make_exec_fn('command')),
 submenu( "submenu title1", {
   menuentry(" menuentry title1", make_exec_fn('command1')),
   menuentry(" menuentry title2", make_exec_fn('command2')),
   submenu( "subsubmenu title1", {
     menuentry(" menuentry level2", make_exec_fn('command3')),
   }),
 }),
 submenu( "submenu title2", {
 }),
 submenu( "submenu title3", {
 }),
})


simpliefied that is:

defmenu( "title", { sequence of submenu or menuitems seperated by ,})

submenu( "title", { sequence of submenu or menuitems seperated by ,})

menuentry( "title", function())


--------------
You have a Q or just want to chat?
Come to #damnsmalllinux on irc.freenode.net!
Open 24/7

dell latitude c640 p4@1.6Ghz 256Mb DSL0.9.1-remaster
asus p4p800-vm p4@2.8Ghz HT / celeron@2.4Ghz 512Mb DSL0.9.1-remaster (alsadebs.dsl)
ABit BE6 celeron@466 256Mb DSL0.9.1-remaster (xawtv)
Back to top
Profile PM WEB MSN 
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Jan. 15 2005,22:50 QUOTE

And this works in Ion?
So I must be doing something wrong in my script.  I'm saving this page for reference.
And if i get it working you will definitely be credited in the script...you are keeping me from completely hating Ion =o)


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
41 replies since Jan. 10 2005,01:43 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (9) </ ... 4 5 6 7 8 [9] >/
reply to topic new topic new poll
Quick Reply: A TWM for Open DSL

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code