WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: How to replace menu in fluxbox  (Read 4016 times)

Offline SuSonicTH

  • Newbie
  • *
  • Posts: 2
How to replace menu in fluxbox
« on: August 07, 2010, 03:01:34 AM »
HI!

First of all I want to say thanks for that great distribution! I tried many different small and live distributions and I like Tinycore best for it's size, performance and flexibility.

But now to my Question:

I have Tinycore 3.0 installed and I'm using fluxbox as my windowmanager because I like to have a taskbar. I would like to replace the standard menu with my custom one  to have a submenu with some scrips for wifi or connecting to some smb shares and so on.
The editing of ~/.fluxbox/menu is no problem but it gets overwritten on every startx. How can I prevent that automatic menu generation?

Thanks in Advance for your help,
Michael

P.S.: Please excuse my poor english.

Offline jerramy

  • Jr. Member
  • **
  • Posts: 76
Re: How to replace menu in fluxbox
« Reply #1 on: August 07, 2010, 11:55:44 AM »
Has it been added to your /opt/.filetool.lst file?

Offline roberts

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 7361
  • Founder Emeritus
Re: How to replace menu in fluxbox
« Reply #2 on: August 07, 2010, 01:49:16 PM »
Actually the window manager's _initmenu is called from startx.

This allows for easy switching of window managers and occurs after restoring from backup or bootlocal.sh.

If your goal is replace our dynamic menu with a custom static one, then I would think a copy should work from within .xsession after waitforX and before the call to "$DESKTOP".

Using a custom static menu will likely break any further automatic updates to such menu.
10+ Years Contributing to Linux Open Source Projects.

Offline SuSonicTH

  • Newbie
  • *
  • Posts: 2
Re: How to replace menu in fluxbox
« Reply #3 on: August 07, 2010, 06:19:08 PM »

If your goal is replace our dynamic menu with a custom static one, then I would think a copy should work from within .xsession after waitforX and before the call to "$DESKTOP".

Using a custom static menu will likely break any further automatic updates to such menu.

Thanks that did the trick!

Best regards,
Michael

Offline rbacher

  • Newbie
  • *
  • Posts: 23
Re: How to replace menu in fluxbox
« Reply #4 on: August 10, 2010, 12:46:52 AM »
I just experienced the exact same problem, as I prefer to edit the fluxbox menu to suit my particular needs and then keep it that way, so I was very happy to find this thread . . . But, I'm not sure what you mean by putting "a copy" in .xsession.  I see the "waitfor X" and "DESKTOP" is the next line in my .xsession -- so something goes in between.  What exactly goes there?  Thanks. 

Offline rbacher

  • Newbie
  • *
  • Posts: 23
Re: How to replace menu in fluxbox
« Reply #5 on: August 10, 2010, 11:32:40 AM »
I figured out one way to do it.  First, put the menu you want in the home directory ~/.  Second, tell .xsession to copy that file to the .fluxbox directory by entering the following line in .xsession "cp ~/menu ~/.fluxbox &"

But isn't there a more direct way to accomplish this by disabling the dynamic menu in the first place?  I want a very simple custom menu on a very minimal window manager within a very small linux (that's why I switched to tinycore in the first place).  I want NO extra bells and whistles.  If I did, I would run Ubuntu  (I don't even run tinycore, exactly -- I installed microcore plus Xlibs, Xprogs, and Xfbdev on the XO computer -- the XO is very underpowered so I am aiming for the absolutely smallest setup that will boot fast and run a browser and nothing else -- to date that's microcore (at least til the google chrome OS is adapted to the XO)

Offline tinypoodle

  • Hero Member
  • *****
  • Posts: 3857
Re: How to replace menu in fluxbox
« Reply #6 on: August 10, 2010, 01:10:01 PM »
IMHO your described goals sound like they contradict with installing fluxbox which is not exactly a very minimal window manager, at least not compared to e.g. flwm(-topside) or
jwm(-snapshot) - and there are several others which are even smaller -, being more than 10 times bigger than any of latter.
(I wouldn't know about memory usage of busybox).
"Software gets slower faster than hardware gets faster." Niklaus Wirth - A Plea for Lean Software (1995)

Offline rbacher

  • Newbie
  • *
  • Posts: 23
Re: How to replace menu in fluxbox
« Reply #7 on: August 10, 2010, 02:17:44 PM »
Okay, good to know.  I am new to linux and learning.  If flwm(-topside) and jwm(-snapshot) are smaller, I will try them instead.  Do you (or anyone reading this) have a suggestion for the smallest window manager that works with microcore?  BTW I used fluxbox because someone else said it was small, hardly because I came up with the idea myself.

Offline tinypoodle

  • Hero Member
  • *****
  • Posts: 3857
Re: How to replace menu in fluxbox
« Reply #8 on: August 10, 2010, 03:08:38 PM »
Ah ok, now makes more sense... Of course compared with default wm's (or whole desktop environment) in some other distros, busybox could be considered relatively small, it is all relative  ;)

You can use "manager" as a search term in appsbrowser, to have them filtered out  ;)

Looks like tinywm being smallest, also evilwm being pretty small, but question is also what is minimal functionality you request for your purposes.

For reference: my jwm-snapshot is using 2760 Kb of RES memory atm.
EDIT: checked flwm_topside as in base of tinycore: 1948 Kb RES memory

But isn't there a more direct way to accomplish this by disabling the dynamic menu in the first place?  

I'd guess that might also depend upon configuration of particular wm.
In jwm i think you could just try to comment the line
Code: [Select]
<Include>/usr/local/tce.menu/menu</Include>
in ~/.jwmrc out, or possibly replace it by an 'include' pointing to your own customized menu file.
« Last Edit: August 10, 2010, 10:47:41 PM by tinypoodle »
"Software gets slower faster than hardware gets faster." Niklaus Wirth - A Plea for Lean Software (1995)

Offline rbacher

  • Newbie
  • *
  • Posts: 23
Re: How to replace menu in fluxbox
« Reply #9 on: August 10, 2010, 04:30:22 PM »
but question is also what is minimal functionality you request for your purposes.
The minimal functionality I am trying to set up at this point is (1) fast boot (given that I am working with an XO computer which is very slow) and (2) a web browser. That's it.  I am looking forward to the Google Chrome OS but it's not ready for the XO yet.  So I am using microcore plus the minimum.  That appears to be microcore plus Xlibs.gz, Xprogs.gz, Xfbdev.tcz, a window manager and a browser.  I got to the point of installing the window manager, and I installed fluxbox based on information that it was small, light and fast.  That's when I found this thread because I was having a problem with the fluxbox menu.  But based on your information that other window managers are smaller, I will delete fluxbox and try one of the others (at which point I am off topic of this thread).

Offline rbacher

  • Newbie
  • *
  • Posts: 23
Re: How to replace menu in fluxbox
« Reply #10 on: August 15, 2010, 11:45:12 PM »
I tried both flwm and jwm.  I didn't like flwm -- it had the same problem as fluxbox (menu dynamically overwritten when startx runs) but jwm allows a static menu, so I am using jwm.  So far I am quite happy with it (and I have now been able to get the minimal set up I was trying to get -- 25 seconds from cold boot to window manager on a little XO computer, and the menu stays the same).