Diff for review: Was: Menu spec: sorting
Heinrich Wendel
h_wendel at cojobo.net
Thu Sep 25 22:23:13 EEST 2003
On Fri, Sep 19, 2003 at 10:56:40AM +0200, Waldo Bastian wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> I have updated the menu-spec in CVS as version 0.7 (cvs r1.5) see also below.
>
> Please check the CVS version if all your concerns have been properly
> addressed.
There is no way to change the default values of the inline and show_empty attributes.
I added a patch to correct that, please review.
>
> Cheers,
> Waldo
mfg, Heinrich :)
-------------- next part --------------
--- menu-spec.xml 2003-09-25 16:02:59.000000000 +0200
+++ menu-spec.xml.new 2003-09-25 21:20:24.000000000 +0200
@@ -780,7 +780,7 @@
</listitem>
</varlistentry>
<varlistentry>
- <term><Layout [show_empty="false"]></term>
+ <term><Layout></term>
<listitem>
<para>
The <Layout> element is an optional part of this specification.
@@ -800,14 +800,11 @@
menu as defined by the <Include> and <Exclude> elements should
be ignored. References to sub-menus that are not directly contained in this
menu as defined by the <Menu> elements should be ignored.
- The show_empty attribute defines whether a menu that contains no desktop
- entries and no sub-menus should be shown at all. The show_empty attribute
- can be "true" or "false". The default is "false".
</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><DefaultLayout></term>
+ <term><DefaultLayout [show_empty="false"] [inline="false"] [inline_limit="4"] [inline_header="true"] [inline_alias="false"]></term>
<listitem>
<para>
The <DefaultLayout> element is an optional part of this specification.
@@ -820,33 +817,38 @@
any default-layout specified by a parent menu.
The default-layout defines the suggested layout if a <Menu> element
does either not have <Layout> element or if it has an empty <Layout> element.
+ For explanations of the various attributes see the <Menuname> element.
If no default-layout has been specified then the layout as specified by the following
elements should be assumed:
- <DefaultLayout><Merge type="menus"/><Merge type="files"/></DefaultLayout>
+ <DefaultLayout show_empty="false" inline="false" inline_limit="4" inline_header="true" inline_alias="false"><Merge type="menus"/><Merge type="files"/></DefaultLayout>
</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><Menuname [inline="false"] [inline_limit="4"] [inline_header="true"] [inline_alias="false"]></term>
+ <term><Menuname [show_empty="..."] [inline="..."] [inline_limit="..."] [inline_header="..."] [inline_alias="..."]></term>
<listitem>
<para>
This element may only appear as a child of a <Layout> or <DefaultLayout>
menu. Its contents references an immediate sub-menu of the current menu as defined
with the <Menu> element, as such it should never contain a slash.
If no such sub-menu exists the element should be ignored.
- It may have an inline attribute that can be either "true" or "false", the default is "false".
+ This element may have various attributes, the default values are taken from the DefaultLayout key.
+ The show_empty attribute defines whether a menu that contains no desktop
+ entries and no sub-menus should be shown at all. The show_empty attribute
+ can be "true" or "false".
+ It may have an inline attribute that can be either "true" or "false".
If the inline attribute is "true" the menu that is referenced may be copied into the
current menu at the current point instead of being inserted as sub-menu of the current menu.
The optional inline_limit attribute defines the maximum number of entries that can be inlined.
If the sub-menu has more entries than inline_limit, the sub-menu will not be inlined.
- If the inline_limit is 0 (zero) there is no limit. The default inline_limit is 4.
+ If the inline_limit is 0 (zero) there is no limit.
The optional inline_title attribute defines whether an inlined menu should be preceeded with
a header entry listing the caption of the sub-menu.
- The inline_title attribute can be either "true" or "false", the default is "true".
+ The inline_title attribute can be either "true" or "false".
The optional inline_alias attribute defines whether a single inlined entry should adopt the
caption of the inlined menu. In such case no additional header entry will be added regardless
of the value of the inline_title attribute.
- The inline_alias attribute can be either "true" or "false", the default is "false".
+ The inline_alias attribute can be either "true" or "false".
Example: if a menu has a sub-menu titled "WordProcessor" with a single entry "OpenOffice 4.2",
and both inline="true" and inline_alias="true" are specified then this would result in the
"OpenOffice 4.2" entry being inlined in the current menu but the "OpenOffice 4.2" caption
More information about the xdg
mailing list