Qt4 to Qt5 on macOS: lost window list in mac toolbar icon - macos

When I open multiple windows in my Qt4 app on mac, the toolbar lists them:
When I do the same in Qt5, the toolbar doesn't list any windows my application has:
I've looked around but couldn't find an option. How can I fix this?

It's a bug in Qt, confirmed in other applications as well: https://bugreports.qt.io/browse/QTBUG-59433.

Related

WSLg QtCreator broken menus and no autocompletion

I'm using WSlg with Ubuntu 18.04 on windows 11 and I've installed on it the Qt Creator IDE. Via the WSLg I can easily launch it through the start menu of windows 11.
The issue is that while coding with it I have no autocompletion (ctrl + space shows no menu). Also the right click menu after a while goes nuts and start showing in weird places of the screen until it disappears completely; same for the menus on the top bar.
I attach a picture where I show how the right click menu shows up out of the boundaries.
Anyone encountered this issue and has a solution?
So for now I have found a workaround even if it's not a proper solution.
I was using QtCreator installed via the online installer that Qt Provides. I tried using the version that comes with apt-get and I do not have those issues. Also the windowing is different because is showing the usual gray boxing of the WSLg apps; so might be related to the XWayland server architecture or something similar.
Cons of this are that the QtCreator version that comes this way is not up to date with the latest and will rely on the qt libs you have installed on your wsl (being ubuntu 18 will be qt5 and not qt6, meaning you'll not have QtCreator 8).
Also right not I'm having issue on the ClangCodeModel but I think it's a different issue.

Create custom right-click menu for OS X app, developed on Linux

I am creating an app for Mac OS, but it is being built on Linux. Because of this, I am not able to use tools such as Xcode, and I am not developing in swift. Rather, the .app directory is being put together according to Apple's documentation, and the entrypoint/executable of my app is a shell script.
I need to customize the menu which appears when you right click on the app (either on the dock icon or in Finder). Is there a way to do this, without using cocoa, etc.?
The menu I believe you are referring to is called "Services".
In order to add a menu item there for your application you would create a script to enable including it there. Xcode isn't needed or required, however, you'll need to know at the very least some basic AppleScript or Javascript to accomplish what you want. (see examples from the link)
↳ Mac Automation Scripting Guide

Mac OS Siera PyQt5 QTabWidget Issue

I usually program on windows (at work) or linux (free time).
Now im doing a project for my wife, and she uses a mac.
In this project there is a QTabWidget with closeable tabs.
On windows the close icon appears properly, and as excepted, however on MAC there is no close icon.
When you click far left on the tab title it just closes unexpectedly, because you cant see a close icon, and im not 100% sure why that is.
Anyone seen this before and know of a fix?
Mac is latest Siera os (just updated)
Python 3
PyQt5 (installed with pip3)
Thanks very much in advance
This is caused by a bug which has been fixed in Qt-5.9.2 (see QTBUG-61092).
In the meantime, it should be possible to work around the issue by setting your own icon using a stylesheet. To do this, you would need to use the QTabBar::close-button selector, which is documented in the Qt Style Sheets Reference.

How to hide Mac OSX menu bar while running an Adobe AIR app?

I need to run an Adobe AIR app across 2 monitors, which cannot be done with fullscreen mode. I am wondering if there is a way to hide the the OSX (Mountain Lion) menu bar. I can span a chromeless AIR window across 2 monitors, but the OSX menu bar is always on top.
Someone posted that they were able to hide the OSX menu bar by using another app (in this post), but so far I have not found a solution.
Sounds like they were using a Native application to remove the UI elements.
I'd suggest you look into doing this through an ANE. If you find the native code for this I'd be happy to wrap it into an ANE for you.
I found an app that can hide the OSX menu bar on Mountain Lion, for AIR apps and pretty much any other apps.
The app is MenuAndDockless
Instructions:
Download the app, install SIMBL loader first (comes with the app download), then install MenuAndDockless app.
Start up the AIR app, or any other kind of app (you will need to restart it if it's already running). Go to the MenuAndDockless Settings (Menu > Window > Settings > Settings…)
Set the desired settings and restart your app.
Here's a detailed manual for the MenuAndDockless app: http://myownapp.com/manuals/mad_manual/

Missing QMenuBar in Qt4 apps on OSX

My Qt4 apps with a QMenuBar show up fine under Linux and Windows, but will not display under OSX. I have a Xeon 64bit Mac Pro with OSX 10.5.7. I'm using Qt 4.5.2. I've tried building my apps with qmake -spec macx-g++ and using an xcode project. Neither seem to work. Any help is much appreciated.
Thanks,
Regis
Your menu should be displayed in the top-level Mac menu. A full desktop screenshot and a code sample would help.
QMenuBar on Mac OS X
QMenuBar on Mac OS X is a wrapper for using the system-wide menu bar. If you have multiple menu bars in one dialog the outermost menu bar (normally inside a widget with widget flag Qt::Window) will be used for the system-wide menu bar.
QMenuBar documentation

Resources