[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: XDG menu spec implementation in kf5 or plasma5
From:       Weng Xuetian <wengxt () gmail ! com>
Date:       2016-01-16 16:50:33
Message-ID: CAKiDycEJ0myv3zdnKshCCNTRZhBnWxS19cXJ-OdrgxqQwZwC1w () mail ! gmail ! com
[Download RAW message or body]

Just FYI, related code can be found via:
https://lxr.kde.org/search?_filestring=&_string=XDG_MENU_PREFIX

On Sat, Jan 16, 2016 at 8:36 AM, Franklin Weng
<franklin@goodhorse.idv.tw> wrote:
> Hi,
>
>
> Again, when developing new version of ezgo, which is based on Kubuntu 15.10,
> I got the same problem:
>
> With the following environment variables  set:
>
> XDG_MENU_PREFIX=ezgo-
> XDG_CONFIG_DIRS=/etc/xdg
> XDG_DATA_DIRS=/usr/share:/usr/share/kde-plasma:/usr/share/ezgo/ezgo-menu:/usr/local/share
>
> In Kubuntu 15.10 live, the menu behavior is:
>  - Main menu layout and desktop-directories followed
> /etc/xdg/menus/kf5-applications.menu
>  - The desktop files were read from /usr/share/ezgo/ezgo-menu/applications
> (which I defined in the /etc/xdg/menus/ezgo-applications.menu, and the zh_TW
> name in this folder were changed)
>  - If I define the ezgo-*.directory file in kf5-applications.menu without
> specifying any new <AppDir>, it still works.  That means the
> ezgo-applications.menu were read, but seemed to be overwritten by
> kf5-applications.menu.
>
> In the XDG menu spec v1.1-draft (same in v1.0) it said,
>
> <XDG_MENU_SPEC>
> $XDG_CONFIG_DIRS/menus/${XDG_MENU_PREFIX}applications.menu
>
> This file contains the XML definition of the main application menu layout.
> The first file found in the search path should be used; other files are
> ignored. This implies that if the user has their own
> ${XDG_MENU_PREFIX}applications.menu, it replaces the system wide one.
> (Though the user's menu may explicitly merge the system wide one.)
>
> Systems that offer multiple desktop environments and that want to use
> distinct menu layouts in the different environments can use differently
> prefixed .menu files. In this case the$XDG_MENU_PREFIX environment variable
> must be set by the system to reflect the .menu file that is being used.
>
> For example if a system contains both the GNOME and the KDE desktop
> environments it can decide to use gnome-applications.menu as the menu layout
> in GNOME sessions and kde-applications.menu as the menu layout in KDE
> sessions. To correctly reflect this, it should set the $XDG_MENU_PREFIX
> environment variable to "gnome-" respectively "kde-".
> </XDG_MENU_SPEC>
>
> Any idea about the XDG menu spec implementation in kf5 or plasma5?  Any help
> will be very appreciated.
>
>
> Thanks,
> Franklin
>
>
>
>>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe
>>> <<
>

>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic