Re: [proaudio] Script to generate fvwm-crystal menu entries

[ Thread Index | Date Index | More lists.tuxfamily.org/proaudio Archives ]


Le Thu, 1 Mar 2007 17:42:04 +0100,
Thomas Kuther <gimpel@xxxxxxxxxxxxxxxx> a écrit :

> On Do, 01.03.07 14:32 Dominique Michel <dominique.michel@xxxxxxxxxxxx>
> wrote:
> 
> > I am slowly making a script to generate fvwm-crystal menu entries
> > from desktop files. I am actually making the part that will sort the
> > Categories in order to get something useful to generate the menu
> > entries with. The worst is not to make the script but to interpret
> > freedesktop spec.
> > 
> > If I understand well what is on
> > http://standards.freedesktop.org/menu-spec/latest/apa.html
> > it must be only one valid main category with the exception of Audio
> > that must have AudioVideo and Video that must have AudioVideo.
> > 
> > That implies at something as Category=Audio;AudioVideo is valid,
> > Category=Video;AudioVideo is valid, but
> > Category=Audio;AudioVideo;Video is not valid, Category=Audio;Video is
> > not valid and Category=Graphics;Office is not valid.
> > 
> > Can anyone comment on this?
> > 
> > -- 
> > Dominique Michel
> > 
> > --
> > N.B.: Tous les emails que je reçois sont filtrés par spamassassin
> > avant de me parvenir.
> 
> Sounds resonable, as Audio;Video; == AudioVideo. And both Audio and
> Video are subcategories of AudioVideo.

Not exactly.

quote:
The list of Main Categories consist of those categories that every conforming
desktop environment MUST support. By including one of these categories in an
application's desktop entry file the application will be ensured that it will
show up in a section of the application menu dedicated to this category. The
list of Additional Categories provides categories that can be used to provide
more fine grained information about the application. Additional Categories
should always be used in combination with one of the Main Categories.
endquote

It is a list og main categories. In it, we can read:
Audio Desktop entry must include AudioVideo as well
Video Desktop entry must include AudioVideo as well

That implies at Audio;AudioVideo;Video will not be valid. It can be discussed
because they write first "By including one of these categories", not "By
including only one of these categories"

 What my script do for now is:
Audio+AudioVideo+Video=> non valid, skip. (easy to change)
Audio+AudioVideo=> create the entry in Audio
Video+AudioVideo=> create in Video
On of those 3 alone=> create in the given cat.

In all the other cases, if it is more as one main categories, the entry will be
created in the first found main cat.

If a desktop file contain only a sub cat but no main cat, => non valid, skip.

The good news is at it begin to work with the new type of desktop file. Remain
a few things to debug and the old type of desktop files to do.

The icon generation was the easy part. The worst are many kde program using Qt
or KDE as main cat when those keys are sub cat, or missing OnlyShowIn=KDE key.

Ciao,
Dominique
> 
> Tom


-- 
Dominique Michel

--
N.B.: Tous les emails que je reçois sont filtrés par spamassassin avant de me
parvenir.



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/