Page 1 of 1

The "Hello World" Program

Posted: Mon Nov 11, 2019 10:55 am
by mybofy
Bonjour

macOS 10.14 - wxWidgets 3.1.2

The "Hello World" Program (https://docs.wxwidgets.org/3.1.2/overvi ... world.html) works well. But it is not conform the recommandation from Apple.

I am searching the same program specifically coded for macOS. All examples I find content a wxFrame, which is specific to Windows. In MacOS such a wxFrame is not needed : much applications launch with the menus of application in the menu bar and no one window need to be open.

Could someone give me an exemple of a very good well formed code to initiate an application macOS ? More precisely without a wxFrame, but with MacSetCommonMenuBar, and may be wxTopLevelWindowMac.

Merci

Re: The "Hello World" Program

Posted: Tue Nov 12, 2019 6:26 am
by doublemax
much applications launch with the menus of application in the menu bar and no one window need to be open
I don't work under OSX, but AFAIK the menu bar of a frame is moved to the menu bar on the screen under OSX. And you need a place to handle the events, so i think you need a frame. What if you just set the frame size to 0,0? Doesn't that give the result you're looking for?

Re: The "Hello World" Program

Posted: Tue Nov 12, 2019 3:21 pm
by ONEEYEMAN
Hi,
mybofy wrote: Mon Nov 11, 2019 10:55 am Bonjour

macOS 10.14 - wxWidgets 3.1.2

The "Hello World" Program (https://docs.wxwidgets.org/3.1.2/overvi ... world.html) works well. But it is not conform the recommandation from Apple.

I am searching the same program specifically coded for macOS. All examples I find content a wxFrame, which is specific to Windows. In MacOS such a wxFrame is not needed : much applications launch with the menus of application in the menu bar and no one window need to be open.
I don't think Apple UI guidelines tells this - any Mac application upon launch will have a window.
Can you give an example of such application where window will not show upon launch?
Thank you.