setAlwaysOnTop() is ignored when using native title bar?



I tried the code like

CMyWindow() : DialogWindow (T("TheName"), Colours::lightgrey, false) { setAlwaysOnTop(true); setUsingNativeTitleBar(true);But the window is not shown as always on top. It works fine if I remove setUsingNativeTitleBar().

I confirmed that on Mac OS X, haven’t tried yet on windows. JUCE version is 1.38.

Best regards,


Yes, it’s tricky on the mac, because to get a window to be on top, it needs to be a different style of window, which can’t have a title bar. Not sure if there’s a way around this, but one of the things I’m going to look into soon is a way of maintaining the z-order of a set of windows, so that might help with what you’re trying to do.


This is still not working. Jules, could you have a look at this?


TBH I’m not even sure if it’s possible on the mac. Will take a look when I get chance…