Wxwidget as backend and encountered some strange behavior on macOS

Hello,

I’m just exploring haxe and haxeUI, and I’m still quite new to it.

I wanted to use wxwidget as backend and encountered some strange behavior on macOS.

I used HaxeUI command line tools to create a simple project with haxelib run haxeui-core create hxwidgets and then created the application haxe hxwidgets.hxml.

So far all okay.

If I run the app Main in the /build/hxwidgets folder, the window with the three buttons also appears (see pic).

Bildschirmfoto 2024-01-24 um 15.41.20

  1. when I click on a button, the message changes to ‘Thanks!’ However, this only works once for one of the three buttons. But it should work for every button until all buttons have been clicked. If I create the app as html5 and open it in the browser, the function is okay.

  2. I have noticed that the usual macOS application menu is not displayed at the top of the menu bar. Otherwise, when I use wxwidget with Python or c++, the menu was always displayed, as is usual on Mac.

  3. the window menu does not work correctly. If the minimize icon is selected, the window is minimized and cannot be restored. If the window is maximized (full screen), it is enlarged as expected, but it can no longer be made smaller. It is also no longer possible to access the window menu.

  4. if I close the window via the window menu, I receive a wxWidget debug alert (see pic).

If I try openfl as backend, I get a seemingly empty window without a button. The buttons are not rendered, but I can trigger an event. When creating with openfl test macOS, I get the message: Link: ApplicationMain
Could not create SDL renderer: Couldn’t find a matching render driver.

haxe 4.3.3
haxeui-core version 1.6.0
wxWidgets 3.2.4
macOS Sonoma 14.2.1 (Intel)

  • Istvan

Hi,

Can you try with git versions of haxeui-core, haxeui-hxwidgets, hxWidgets… the 1.6.0 release is crazy out of date at this point…

Cheers,
Ian

I have done the following:

haxelib git haxeui-core GitHub - haxeui/haxeui-core: The core library of the HaxeUI framework
haxelib git haxeui-hxwidgets GitHub - haxeui/haxeui-hxwidgets: The hxWidgets backend of the HaxeUI framework -
haxelib git hxWidgets GitHub - haxeui/hxWidgets: Haxe externs (and wrappers) for wxWidgets

and created a new app with haxe hxwidgets.hxml.

Result: the buttons work as they should be. The other “errors” are still present: no application menu, the window can no longer be displayed after minimizing, and the system menu to minimize the window is again missing at full screen.