After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 170702 - merging user menus incorrectly handled
merging user menus incorrectly handled
Status: RESOLVED OBSOLETE
Product: gnome-menus
Classification: Core
Component: libgnome-menu
2.10.x
Other Linux
: Normal major
: ---
Assigned To: gnome-menus dummy account
gnome-menus dummy account
Depends on:
Blocks:
 
 
Reported: 2005-03-17 17:25 UTC by Matt Kynx
Modified: 2006-07-06 23:30 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10



Description Matt Kynx 2005-03-17 17:25:47 UTC
Distribution/Version: Gentoo (gnome-2.10.0_pre0 ebuilds)

1. Create the following file in ~/.config/menus/applications.menu:

<!DOCTYPE Menu PUBLIC "-//freedesktop//DTD Menu 1.0//EN"
"http://www.freedesktop.org/standards/menu-spec/1.0/menu.dtd">
<Menu>
  <Name>Applications</Name>
  <MergeFile>/etc/xdg/menus/applications.menu</MergeFile>
  <Menu>
    <Name>System</Name>
    <Exclude>
      <Filename>gdmflexiserver-xnest.desktop</Filename>
    </Exclude>
  </Menu>
</Menu>

2. killall gnome-panel

Expected:
"System Tools" menu does not contain "New Login in Nested Window" - it should
actually appear under "Other", since it's UnAllocated

Actual:
"System Tools" appears twice, the first time without "New Login in Nested
Window", the second time with it.

According to the spec:
(http://standards.freedesktop.org/menu-spec/menu-spec-latest.html#merge-algorithm)
"...if the user's menu file merges the system menu file, the user can always
override what the system menu specifies by placing elements after the
<MergeFile>  that incorporates the system file."
Comment 1 Matt Kynx 2005-03-17 17:59:33 UTC
Apologies, I've just realised that I had the following line in
/etc/xdg/menus/applications.menu menu:
<MergeFile>/home/matt/.config/menus/applications.menu</MergeFile>.

Without that line, only one "System Tools" menu appears, but "New Login in
Nested Window" is still in it.

Incidentally, I'm testing this against pyxdg, which handles both cases
correctly, moving "New Login..." to "Other"
Comment 2 Mark McLoughlin 2005-03-18 08:03:34 UTC
> "System Tools" menu does not contain "New Login in Nested Window" - it should
> actually appear under "Other", since it's UnAllocated

That's incorrect - an item which has been <Exclude>d is still considered
allocated. Check xdg archives over the last few months for details.


As for the bug you're trying to report, please just included the output of
MENU_VERBOSE=1 gnome-menu-spec-test which shows the problem.
Comment 3 Matt Kynx 2005-03-18 10:18:11 UTC
Oh boy, I seem to have been having a real day. I can't duplicate this on this
morning's clean setup. Apologies for wasting time.

Thanks for pointing out gnome-menu-spec-test, though.
Comment 4 André Klapper 2006-07-06 23:30:35 UTC
okay, closing as per last comment. matt, thanks for the feedback. :-)