How keep NSWindow always on top other windows?

Is there any way to keep an NSWindow always on top of other windows (inside an app)?

I want to create a "preview" window for pictures and videos with it not taking up space in the main window.

Answered by Claude31 in 783630022

Did you consider using hud (head up display) window ?

    @IBOutlet fileprivate weak var hud  : NSPanel! 
Accepted Answer

Did you consider using hud (head up display) window ?

    @IBOutlet fileprivate weak var hud  : NSPanel! 

Again, I found it myself.

override func windowDidLoad() {
        super.windowDidLoad()

        window?.level = .floating
    }
How keep NSWindow always on top other windows?
 
 
Q