Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Terrible Ubuntu Unity Menu problem. Qt menu bug or a show-stopping Unity bug?
edreamleo last edited by
I am the author of Leo, a sophisticated Qt app: http://webpages.charter.net/edreamleo/front.html
The problem I am about to discuss happens only on Ubuntu Unity. All works well on Windows and Ubuntu Classic.
This problem is a show-stopper for Unity. As discussed below, there is a workaround, but it is wretched and I won't go there.
My question is this: is this a known problem, either with Qt or Unity? BTW, the "search feature" is not working for me.
Leo can show multiple outlines in a QTabWidget. In that case, Leo creates a separate QMenuBar for each tab, and carefully binds each menu item to a separate Leo commander that represents all the data in an outline.
All works well on Windows and Ubuntu Classic. When the user selects a new tab, the menu bar changes so that each menu item now is bound to the proper commander.
Alas, things go horribly (and weirdly) wrong on Ubuntu Unity. What happens is this:
When the user selects a new tab, Unity shows the correct menu title.
However, the actual menu items do not change. In fact, the last-created menu items remain in effect.
This causes chaos. Users think they are working on one outline, when in fact they are working on another.
There is a workaround, but it is so bad that I would rather declare that Leo is not supported on Unity. Leo could detect tab-changed events, and set a global current_commander var. Each menu item could use this commander, rather than the commander that Leo so carefully binds to each menu item. But this is asking for trouble: event-created bindings are far less secure than proper static bindings. Once can envisage race conditions that break bindings. Such intermittent problems would be catastrophic.
To repeat my question. Is anyone aware of such problem? Does anyone have a suggestion?
stirfoo last edited by
I just experienced a puzzling problem with my Qt app and Unity. Your post is the first related post I found. Doesn't seem to be a lot of discussion about this (else I just haven't searched enough).
I've created a small pyqt app "here":http://pastebin.com/AFan6td4 to demonstrate my problem. I posted to let you know, it's not just you. ;)
If this works fine everywhere but in Ubuntu, then it is most likely a ubuntu bug. Try filing a bug report with their bug tracker at http://lauchpad.net/ .
stirfoo last edited by
Thanks for the reply Tobias.
I really should start checking post dates. Edward's comment was a year old!
strifoo: It is still true:-)