I've wrote some small cocoa app and it's main window has HUD style. The problem is - when I set HUD style Interface Builder automatically also sets Utility style - which make the main window topmost (always visible over every other windows). Is there a way to get HUD style panel/window but without making it topmost?
+1
A:
If you can't do it in IB, you'll have to do it programmatically. In this case, that means creating the window programmatically. (You'll want to move the window's views into a separate top-level view in the nib, and set that view as the programmatically-created window's content view.)
You should also file a bug report, as it doesn't seem from the NSPanel documentation that the HUD style necessarily implies the utility-window nature.
Peter Hosey
2009-12-19 03:47:30
I read a little bit more documentation about NSPanel from your link - I would call this HUD + Utility checkboxes a bug (but I bet they did it on purpose) and I can create HUD window programmatically but it's square (without rounded corners) and it seems that you can't set HUD window that has close button and window title.I did custom HUD-like button already so probably I will have to make custom window subclass that looks like HUD panel..
shw
2009-12-19 16:22:17
You should be able to add the style masks for a title and close button.
Peter Hosey
2009-12-19 20:39:08
+1
A:
As it turns out - there's a pretty simple solution for my topmost problem:
[hudPanel setLevel: NSNormalWindowLevel];
Makes it act like normal window that aren't topmost anymore.
shw
2009-12-19 16:39:18