Floating Window

Is it possible to create and always on top floating window that behaves the same as a native OS floating window? I know I can get close to the same behaviour by using Component::setAlwaysOnTop() but I’d like to know if there’s a way to make a Juce window who’s underlying OS window is a floating window.

If you want to know why I’m trying to do this I can explain but it’s a long story!..

Well, if you stick a juce component on the desktop, it is an OS window…! (How else could it get onto the screen!?)

I think I should have emphasized the word “floating”. For example, in a Cocoa apps floating auxilliary windows tend to be utility panels (i.e. an NSPanel created with the NSUtilityWindowMask style mask). There must be an equivalent sort of thing on Windows. So my question was, is there any way for my Juce window to be one of those rather than a plain NSWindow?

So what you really mean is that you want a native title bar on it? The only native title bars that I’ve added support for are the normal ones, I’ve not looked into the thinner toolbar styles.

There are a couple of other differences too between NSPanel and NSWindow, the main one being that a NSPanel can be the key window without becoming the main (active) window. It’s not a big problem that it’s not there though. To be honest I can’t immediately see a brilliant way to add this sort of thing.

Thanks for the prompt response :slight_smile:

in a Cocoa apps floating auxilliary windows tend to be utility panels (i.e. an NSPanel created with the NSUtilityWindowMask style mask). There must be an equivalent sort of thing on Windows.


Want to get-on Google’s first page and loads of traffic to your website? Hire a SEO specialist from Ocean Groups seo specialist

I would also like to request floating window support. This would be very helpful for developing media editor apps with ‘floating’ tool palettes, audio transport windows, etc.

Looks like it’s also been asked about here: http://www.rawmaterialsoftware.com/viewtopic.php?f=2&t=2664

Thx, b