Advanced menu (prototype, working)

Under development: PCMCIA, wireless, etc.
Post Reply
Message
Author
User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

Advanced menu (prototype, working)

#1 Post by MU »

this is far from being finished.

You also need a "puppyfied" /etc/xdg/menus/applications.menu:
http://murga-linux.com/puppy/viewtopic. ... ch&id=7899
( from http://murga-linux.com/puppy/viewtopic.php?t=25925 )

Requires GtkBasic 003.

It reads in /etc/xdg/menus/applications.menu to build the category-structure, then checks if something changed in /usr/share/applications/ (the *.desktop files that contain menu names, executables, icons).
If yes, it re-scans the *.desktop-files, and creates /root/.Gtbmenu/cached.menu
(So this will be created in any case you run it the first time)

To rebuild the cache on my system (with many KDE files), it needs 12 seconds.
Puppys fixmenus needs 50 seconds.
This may slow down in future with subcategories and planned Icon-file search as used in the GtkBasic-Panel.

It has a simplified menustructure like jwm, but even simpler (currently no subcategories yet).

It could be used by other menu-programs, as it is easy to convert.

If you just want to use it as converter, run it like
GtBmenu -consolemode=1

This forces to rebuild the menu, and then exits without displaying the Gtk-based interface.


The interface currently does not use the "menu" widget, but consists of 2 clists, and displays no icons yet.
The clist-based interface will make it easy to add an "edit" option.
A menu-widget might follow later, I did not check yet if that works in GtkBasic already.
As I said: prototype ;)

The XDG-syntax is not fully supported.
Not working: And , Or.
Partially working: Not (but not nested ones)


Good night,
Mark
Attachments
GtBmenu.pup
(19.42 KiB) Downloaded 515 times
GtBmenu.jpg
(47.34 KiB) Downloaded 1251 times
Last edited by MU on Wed 05 Mar 2008, 19:38, edited 1 time in total.
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#2 Post by MU »

I made quite some progress.

It is usable now, though some things must be fixed and added for a productive release.

You can run programs or edit their entries by checking a checkbox.
Some more parameters are supported, like -popup=1.
That will show it without titlebar, what gives a nicer visual integration in toolbars or so.

I added a script "bottom-menu".
Drag it on your desktop and click on it, to open the menu where normally the JWM/Icewm menu appears.
I soon will add a button that "flows" over the JWM/Icewm -menubutton.


On my system (P700) the menu needs 2-3 seconds to start.
This is slightly slower than the icewm-menu, when that has loaded all pictures.
But Icewm often has a large delay the first time it is opened, so you wait more than 15 seconds (not counting the time for fixmenus!).
So my solution seems to be quite speedy.

Icons are searched in many locations, the final cached.menu contains the full pathname and filename.
Like this also the KDE .desktop-files work, that often just call their icons "example" instead of "/usr/share/icons/default.kde/16x16/apps/example.png".

This feature slows down rebuilding the cache (the internal equivalent of "fixmenus"), it now needs 30 seconds instead of 12.
In a test without the KDE files, it needs 10 seconds. Not so bad though.

Todo: It now also scans /root/.local/share/applications, but does not check it yet for changes.
Todo: add exporters for JWM/Icewm/lxpanel.

To try it, you MUST install GtkBasic 003 again, as I just uploaded an extended version. The old one could not handle all those objects (over 1000 pixmaps for internal scaling and such).


Mark
Attachments
GtBmenu2.jpg
(98.12 KiB) Downloaded 955 times
Last edited by MU on Sat 23 Feb 2008, 03:07, edited 2 times in total.
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
Lobster
Official Crustacean
Posts: 15522
Joined: Wed 04 May 2005, 06:06
Location: Paradox Realm
Contact:

#3 Post by Lobster »

Good night,
Mark
Moin.
Hope you slept well Mark :)
. . . not still coding? :oops:

This with XDG and language support will give fantastic flexibility
to Muppy, Puppy and those developing their specific need remasters

woof woof
Last edited by Lobster on Thu 28 Feb 2008, 08:50, edited 1 time in total.
Puppy Raspup 8.2Final 8)
Puppy Links Page http://www.smokey01.com/bruceb/puppy.html :D

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#4 Post by MU »

Good morning Ed,

yesterday I did not code, as I'm a bit ill.
Today it is better.
The sine-generator in my head just creates a light hissing sound, not a strong sine-wave as yesterday.

I have this "tinitus" when I am not in good health or had too much noise around me.

However it was better today, and I could continue.

Now Im not really tired yet, but too unconcentrated to continue coding.

Wish you a very nice weekend :)
You are often very early up in the morning, right?

Mark
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#5 Post by MU »

No new upload today.

Just some info to keep you informed.

I made enhancements, now the menu starts showing only a button on the desktop. To load it, takes 2-3 seconds - once.
This button can cover the JWM or Icewm menubutton.
If you click on this button, the menu is shown - immedeatly without any delay.
So now the whole application must not start from new, each time you want to see the menu.
I currently extend this code, so that it can be used as a plugin in the GtkBasic-Panel.
It already integrates as a big button, that displays the cached menu on click.
I now must add the code, that generates the cache.
Then some more conditions that check, if it runs as standalone application or as plugin.

I hope I can finish that tomorrow.
Then update some code of the panel to use some of the new functions of GtkBasic, what gets rid of several warnings and should slightly new speed (though on my P700 it runs already very fast).
When that is done, I'll upload it (so hopefully in 2 days).

I then will continue to add a settings-dialog to the panel.
Then it should be finished for the moment, and I could continue on the MIME-System.

The attached screenshot shows it running as plugin in the panel.

Mark
Attachments
gtbmenu3.jpg
(51.79 KiB) Downloaded 1106 times
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#6 Post by zigbert »

Hi Mark.

This sounds like a hit. I wouldn't be surprised if we now see gtkbasic again in the official Puppy. - Only this menu-app could be worth it.

I have a suggestion: It would be perfect with a search-file/web-field. If the search command also could be user-defined, I could finally get Pfind (or other) closer to the Puppy-starting-point. pfind -c searchtext skips Pfind start-gui. It shows progress-dialog and ends with an overview with the hits.

Sigmund

User avatar
Lobster
Official Crustacean
Posts: 15522
Joined: Wed 04 May 2005, 06:06
Location: Paradox Realm
Contact:

#7 Post by Lobster »

You are often very early up in the morning, right?
:) Yes.

At the moment I am nursing some Dill seeds (Yum with fish) and growing tomato and parsley seedlings ( also to go with fish :oops: - is there a pattern emerging . . .)

Growing plants are part of the ultimate form of evolutionary coding.

So I am working on a menu too - just a different sort . . .

I hope to be working on a mantra soon (every boddhisattva needs a mantra). Part of it will be 'moin'.

http://tmxxine.com/wik/wikka.php?wakka=NewBodhis

I will be awaiting signs of guidance (even if totally imagined) :lol:
I hope this amuses you and your friends and is not
amiss or embarrassing in any way . . .

It serves several purposes:

1. Ensure I am certifiably insane
2. Provide hope to programmers too busy
to take care of their spiritual needs
3. Generate goodwill, harmony and laughter
Puppy Raspup 8.2Final 8)
Puppy Links Page http://www.smokey01.com/bruceb/puppy.html :D

User avatar
Eyes-Only
Posts: 1043
Joined: Thu 10 Aug 2006, 06:32
Location: La Confederation Abenaquaise

#8 Post by Eyes-Only »

Looking at this Mark my eyes go wide :shock: and about all I can say is: WOW! I'm near speechless over this project of yours!

Do you think it will likewise work for such window managers as Fluxbox as well? Particularly if we're using the ROX desktop with Fluxbox?

Another question: Do you think this will work on other distros too? Besides Puppy I spend a lot of time in Linux Mint and use either my own install of IceWM or Fluxbox with the ROX desktop and pinboard (for icon/wallpaper support obviously ;) ), very seldom ever using the Gnome desktop provided. It would be interesting to see if this would work in there, Mint, as well, but I'm not sure if it has Gtkbasic003...

At any rate my friend---keep up the fabulous work! You never cease to amaze me, and you always inspire me! :)

Mazzel/mfg!

Eyes-Only
"L'Peau-Rouge"
*~*~*~*~*~*
Proud user of LXpup and 3-Headed Dog. 8)
*~*~*~*~*~*

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#9 Post by MU »

Lobster,
I hope this amuses you and your friends and is not
amiss or embarrassing in any way . . .
yes, that is ok :lol:


Jimmy,
thank you.
I meanwhile almost finished the integration in the panel, but a bug appears, the text disapears after 100 clicks.
I will have to add a modification to solve that (organize the lists in a notebook maybe).
So no promise it is finished tomorrow, might take 1 more day.
Do you think it will likewise work for such window managers as Fluxbox as well? Particularly if we're using the ROX desktop with Fluxbox?
yes :P
Another question: Do you think this will work on other distros too?
It should.
GtkBasic just depends on Gtk2.
It is
/usr/bin/gtkbasic003
/usr/lib/wxbasicscript/
/usr/local/Gtkbasic-003/

If you copy those to another distro, it should work, as long as it is binary-compatible.
If it will not, I will try to help you to get it to work :)

Please note also this great enhancement Plinej made to lxpanel:
http://murga-linux.com/puppy/viewtopic.php?t=25118
He has achived a dramatic speed-improvement.

Mark
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
Eyes-Only
Posts: 1043
Joined: Thu 10 Aug 2006, 06:32
Location: La Confederation Abenaquaise

#10 Post by Eyes-Only »

No problem on when you release this Mark as it may be awhile before I can even get the chance to try it. I've been busy since yesterday (Thursday) and I don't see that stopping much before Monday when I'll have time to myself. Also, when I get this busy there are "other things" I must watch out for health-wise. :( But I am anxious to give this a try in the three distros I use the most! I like in one of the screenies how you had it added as a type of "additional menu" beside the regular IceWM menu. That was very nice! (Even in Mint and PCLOS I prefer using IceWM as default. In Mint it even looks like Gnome. ;) )

Yes, I saw plinej's work on LXpanel! Very Impressive! I've been toying with the idea of giving that a try on my Mint/PCLOS as both have OpenBox installed and I could use that as the taskbar.

So many things to play with... and so little time! hehe!

Mazzel Mark and have a great weekend over there, okie my friend?

mfg,

Eyes-Only
"L'Peau-Rouge"
*~*~*~*~*~*
Proud user of LXpup and 3-Headed Dog. 8)
*~*~*~*~*~*

Post Reply