Type Alias

NSWindowLevel

The standard window levels in macOS.

Declaration

typedef NSInteger NSWindowLevel;

Discussion

The stacking of levels takes precedence over the stacking of windows within each level. That is, even the bottom window in a level will obscure the top window of the next level down. Levels are listed in order from lowest to highest. These constants are mapped (using #define statements) to corresponding elements in CGWindowLevelKey.

Topics

Type Properties

NSDockWindowLevel

The level for the dock.

Deprecated
NSFloatingWindowLevel

Useful for floating palettes.

NSMainMenuWindowLevel

Reserved for the application’s main menu.

NSModalPanelWindowLevel

The level for a modal panel.

NSNormalWindowLevel

The default level for NSWindow objects.

NSPopUpMenuWindowLevel

The level for a pop-up menu.

NSScreenSaverWindowLevel

The level for a screen saver.

NSStatusWindowLevel

The level for a status window.

NSSubmenuWindowLevel

Reserved for submenus. Synonymous with NSTornOffMenuWindowLevel, which is preferred.

NSTornOffMenuWindowLevel

The level for a torn-off menu. Synonymous with NSSubmenuWindowLevel.

See Also

Managing Window Layers

- orderOut:

Removes the window from the screen list, which hides the window.

- orderBack:

Moves the window to the back of its level in the screen list, without changing either the key window or the main window.

- orderFront:

Moves the window to the front of its level in the screen list, without changing either the key window or the main window.

- orderFrontRegardless

Moves the window to the front of its level, even if its application isn’t active, without changing either the key window or the main window.

- orderWindow:relativeTo:

Repositions the window’s window device in the window server’s screen list.

level

The window level of the window.