---
title: NSWindow.Level
framework: appkit
role: symbol
role_heading: Structure
path: appkit/nswindow/level-swift.struct
---

# NSWindow.Level

The standard window levels in macOS.

## Declaration

```swift
struct Level
```

## Discussion

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

### Constants

- [dock](appkit/nswindow/level-swift.struct/dock.md)
- [floating](appkit/nswindow/level-swift.struct/floating.md)
- [mainMenu](appkit/nswindow/level-swift.struct/mainmenu.md)
- [modalPanel](appkit/nswindow/level-swift.struct/modalpanel.md)
- [normal](appkit/nswindow/level-swift.struct/normal.md)
- [popUpMenu](appkit/nswindow/level-swift.struct/popupmenu.md)
- [screenSaver](appkit/nswindow/level-swift.struct/screensaver.md)
- [statusBar](appkit/nswindow/level-swift.struct/statusbar.md)
- [submenu](appkit/nswindow/level-swift.struct/submenu.md)
- [tornOffMenu](appkit/nswindow/level-swift.struct/tornoffmenu.md)

### Creating a Window Level

- [init(_:)](appkit/nswindow/level-swift.struct/init(_:).md)
- [init(rawValue:)](appkit/nswindow/level-swift.struct/init(rawvalue:).md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Comparable](swift/comparable.md)
- [Copyable](swift/copyable.md)
- [Equatable](swift/equatable.md)
- [Escapable](swift/escapable.md)
- [Hashable](swift/hashable.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Managing Window Layers

- [orderOut(_:)](appkit/nswindow/orderout(_:).md)
- [orderBack(_:)](appkit/nswindow/orderback(_:).md)
- [orderFront(_:)](appkit/nswindow/orderfront(_:).md)
- [orderFrontRegardless()](appkit/nswindow/orderfrontregardless().md)
- [order(_:relativeTo:)](appkit/nswindow/order(_:relativeto:).md)
- [level](appkit/nswindow/level-swift.property.md)
