Whisker-menu struggles with wine vs. MenuLibre

On actual Manjaro XFCE (stable) I installed wine and winetricks (didn’t even touch the latter yet), then installed some Windows 32-bit sw (7-zip, eac, mp3directcut, winamp2, vlc).
For some reason eac was not shown under wine in the whisker-menu, but 7-zip was. (xfce4-panel 4.16.4)

In the menu editor I see sub-folders under “wine”, so I created identic entries directly under “wine” for eac, mp3directcut, vlc - leaving the original for not messing with wine. So far so good. A copy-paste function woud have made the task easier.

  • One issue here: Wenever I press “save” for a wine application menu item, e.g. after changing the icon or adding a hint text, the whisker-menu editor doubles all backslashes in the commandline, even when this line was not touched.
    My workaround is to copy the commandline from here to mousepad, delete half of the backslashes, and copy the result back to the commandline before “save”.

When I installed the next wine application (winamp, vlc) almost all entries from the submenus in the menu editor under “wine” also appeared in the whisker-menu under “wine”.
After editing one of them (changed title of “Documentation” to “VideoLAN Documentation”) almost all items from sub-folders disappeared again, 7-zip and eac remained twice - so I removed those menu items that I had created formerly.

I can work it (almost) all out manually by trial-and-error, but it’s a little inconvenient to once create additional items manually if they happen to stay invisible, then again delete them if they show up twice. To me it seems that wine just duplicates the “start menu” structure, but XFCE’s whisker-menu does not handle it correctly - it seems not to support sub-folders in the list view (old Knoppix on lxde had a tree view similiar to a WinXP-startMenu), but on the other hand I’d not want a veeery long list like that in recent W10, but just those Starters that I really use. Plus the worrysome backslash handling, if I’d have to edit some more commandlines than just my handful.

Please, advise, to whom this should be addressed. I’d also appreciate some advise for alternate methods to edit the menu, e.g. directly working on a config file (which?). Will updates to that file become active after a new login, or would I have to log out while editing it?

Thank you,

P.S. - Wow, just changed to tree view, and in the menu there’s no VideoLAN and no Winamp folder, only 7zip and eac (under “Programs”), but all tey’re equally present in the editor…

Do you mean menulibre?

I believe you need to use normal slashes here.

See :point_down: on how menu entries for Wine applications are managed.

Yes, I’m using MenuLibre that the xfce4-panel offers in the context menu for editing the whisker-menu.

One commandline as I found it here after running the 7-zip installer e.g.:

env WINEPREFIX="/home/user/.wine" wine C:\\\\ProgramData\\\\Microsoft\\\\Windows\\\\Start\\ Menu\\\\Programs\\\\7-Zip\\\\7-Zip\\ File\\ Manager.lnk

After altering the hint, saving, closing and re-opening MenuLibre it looks like this (and doesn’t start anything, of course):

env WINEPREFIX="/home/user/.wine" wine C:\\\\\\\\ProgramData\\\\\\\\Microsoft\\\\\\\\Windows\\\\\\\\Start\\\\ Menu\\\\\\\\Programs\\\\\\\\7-Zip\\\\\\\\7-Zip\\\\ File\\\\ Manager.lnk

This can be fixed by re-entering the commandline in this form, then save again:

env WINEPREFIX="/home/user/.wine" wine C:\\ProgramData\\Microsoft\\Windows\\Start\ Menu\\Programs\\7-Zip\\7-Zip\ File\ Manager.lnk

Yes, I remember to have read that wine accepts slashes as well, but the above is what was automatically created. But, perhaps, I may spare a lot of time if I once change the backslash-escapes to slashes and enclose the blanks into a quotation. Still have to treat every menu entry…

This seems a very good place for me to read on. Many thanks.

Maybe that helps:

env WINEPREFIX="/home/user/.wine" bash -c 'wine  $(winepath --windows  '/home/<user>/.wine/drive_c/ProgramData/Microsoft/Windows/Start Menu/Programs/7-Zip/7-Zip/File Manager.lnk')'

winepath should convert the unix to a windows path:

$ winepath --windows '/home/user/.wine/drive_c/ProgramData/Microsoft/Windows/Start Menu/Programs/7-Zip/7-Zip/File Manager.lnk'
C:\ProgramData\Microsoft\Windows\Start Menu\Programs\7-Zip\7-Zip\File Manager.lnk

Working around the backslashes seems even not to require using winepath - wine also accepts the whole path in unix/linux style with slashes. So if I manually touch any starter I may change the program entry from

env WINEPREFIX="/home/user/.wine" wine C:\\ProgramData\\Microsoft\\Windows\\Start\ Menu\\Programs\\7-Zip\\7-Zip\ File\ Manager.lnk


env WINEPREFIX="/home/user/.wine" wine "/home/user/.wine/dosdevices/c:/ProgramData/Microsoft/Windows/Start Menu/Programs/7-Zip/7-Zip File Manager.lnk"

but I’d have to do this by hand for each and every starter if I just intend to change something rather unimportant like the descriptive hint or the icon.

What puzzles me much more is that I cannot understand how the menu changes the selection which program starters and which folders to display. From the MenuLibre site I came to the FreeDesktop menu specification - File locations - I see my .desktop files in

~/.local/share/applications/wine/Programs/Exact Audio Copy/

Apparently wine created the latter four directories when the eqivaltents were created during program installation in

~/.wine/dosdevices/c:/ProgramData/Microsoft/Windows/Start Menu/Programs/7-Zip/
~/.wine/dosdevices/c:/ProgramData/Microsoft/Windows/Start Menu/Programs/Exact Audio Copy/
~/.wine/dosdevices/c:/ProgramData/Microsoft/Windows/Start Menu/Programs/VideoLAN/
~/.wine/dosdevices/c:/users/<user>/AppData/Roaming/Microsoft/Windows/Start Menu/Programs/Winamp/

When one of the installers created a Windows desktop shortcut .lnk, I had it even doubled by wine in a .desktop file - I deleted the .lnk and can happily use the .desktop starter.

Further I found all the folders not only under …/wine/Programs/ as listed above and in MenuLibre under “Wine” but also (note EAC missing in applications-merged) specified in

~/.config/menus/gnome-applications-merged -> applications-merged
~/.local/share/desktop-directories/wine-Programs-Exact Audio Copy.directory

Here is the behaviour that really puzzles me:
After the Winamp installation I saw all the .desktop starters in my Whisker-menu listed under “Wine”. (Unfortunately I did not guess to take a screenshot then.)
Next I used MenuLibre to edit the name of “Documentation” and change it to “VideoLAN Documentation” just to make clear where it belongs to (I had to remove all doubled backslashes in the commandline before saving).

After that only 7-zip FM, 7-zip Help and EAC remained visible in the Whisker-Menu - meanwhile I created manually other starters - and the tree view shows only the 7-zip and EAC folders - where are the settings that
a) prevent all the other starters from showing in the Whisker-menu and
b) hide the other two menus/folders?


When I changed the Whisker-menu config to tree view, it was showing also only these two folders.

Why are the starters not shown for all the other entries (“Documentation”, “Uninstaller” e.t.c.) that crowded this list after the last Windows (Winamp) installer ran? Right after my renaming the “Documentation” to “VideoLAN Documentation” they disappeared - except 7zFM and EAC. I created the other entries visible here manually and only set “hide” on 7-zip Help:


Is it possible that the one missing menu/directory/folder under applications-merged breaks the processing and stops the others from being recognized? I’ll try to re-create it and see what happens…

Created a file ~/.config/menus/applications-merged/user-wine-wine-wine-Programs-wine-Programs-Exact Audio Copy.menu - the selection of items shown in menu did not change after re-login.

Further the handling of blanks in ~/.config/menus/applications-merged/user-wine-wine-wine-Programs-wine-Programs-7-Zip.menu looks really strange to me

<!DOCTYPE Menu PUBLIC "-//freedesktop//DTD Menu 1.0//EN"
<!-- Do not edit manually - generated and managed by xdg-desktop-menu -->

apparently referring to

~/.local/share/applications/wine/Programs/7-Zip/7-Zip File Manager.desktop
~/.local/share/applications/wine/Programs/7-Zip/7-Zip Help.desktop

Is that something worth communicating to the MenuLibre developers?