| Inherits from | |
| Conforms to | |
| Framework | /System/Library/Frameworks/AppKit.framework |
| Availability | Available in Mac OS X v10.0 and later.
|
| Companion guide | |
| Declared in | NSDrawer.h NSGraphics.h NSWindow.h |
The NSWindow class defines objects (known as windows) that manage and coordinate the windows an application displays on the screen. A single NSWindow object corresponds to at most one onscreen window. The two principal functions of a window are to provide an area in which views can be placed and to accept and distribute, to the appropriate views, events the user instigates through actions with the mouse and keyboard.
Note: Although the NSWindow class inherits the NSCoding protocol from NSResponder, the class does not support coding. Legacy support for archivers exists but its use is deprecated and may not work. Any attempt to archive or unarchive an NSWindow object using a keyed coding object raises an NSInvalidArgumentException exception.
– initWithContentRect:styleMask:backing:defer:
– initWithContentRect:styleMask:backing:defer:screen:
– styleMask
– worksWhenModal
– alphaValue
– setAlphaValue:
– backgroundColor
– setBackgroundColor:
– contentView
– setContentView:
– canHide
– setCanHide:
– hidesOnDeactivate
– setHidesOnDeactivate:
– collectionBehavior
– setCollectionBehavior:
– isOpaque
– setOpaque:
– hasShadow
– setHasShadow:
– invalidateShadow
– autorecalculatesContentBorderThicknessForEdge:
– setAutorecalculatesContentBorderThickness:forEdge:
– contentBorderThicknessForEdge:
– setContentBorderThickness:forEdge:
– delegate
– setDelegate:
+ defaultDepthLimit
– windowNumber
– gState
– canStoreColor
– deviceDescription
– canBecomeVisibleWithoutLogin
– setCanBecomeVisibleWithoutLogin:
– sharingType
– setSharingType:
– backingType
– setBackingType:
– backingLocation
– preferredBackingLocation
– setPreferredBackingLocation:
– isOneShot
– setOneShot:
– depthLimit
– setDepthLimit:
– hasDynamicDepthLimit
– setDynamicDepthLimit:
+ contentRectForFrameRect:styleMask:
+ frameRectForContentRect:styleMask:
+ minFrameWidthWithTitle:styleMask:
– contentRectForFrameRect:
– frameRectForContentRect:
– attachedSheet
– isSheet
– window:willPositionSheet:usingRect: delegate method
– windowWillBeginSheet: delegate method
– windowDidEndSheet: delegate method
– frame
– setFrameOrigin:
– setFrameTopLeftPoint:
– constrainFrameRect:toScreen:
– cascadeTopLeftFromPoint:
– setFrame:display:
– setFrame:display:animate:
– animationResizeTime:
– windowWillUseStandardFrame:defaultFrame: delegate method
– aspectRatio
– setAspectRatio:
– minSize
– setMinSize:
– maxSize
– setMaxSize:
– isZoomed
– performZoom:
– zoom:
– windowShouldZoom:toFrame: delegate method
– resizeFlags
– showsResizeIndicator
– setShowsResizeIndicator:
– resizeIncrements
– setResizeIncrements:
– preservesContentDuringLiveResize
– setPreservesContentDuringLiveResize:
– windowWillResize:toSize: delegate method
– windowDidResize: delegate method
– contentAspectRatio
– setContentAspectRatio:
– contentMinSize
– setContentMinSize:
– setContentSize:
– contentMaxSize
– setContentMaxSize:
– contentResizeIncrements
– setContentResizeIncrements:
– isVisible
– orderOut:
– orderBack:
– orderFront:
– orderFrontRegardless
– orderWindow:relativeTo:
– level
– setLevel:
+ removeFrameUsingName:
– setFrameUsingName:
– setFrameUsingName:force:
– saveFrameUsingName:
– frameAutosaveName
– setFrameAutosaveName:
– stringWithSavedFrame
– setFrameFromString:
– isKeyWindow
– canBecomeKeyWindow
– makeKeyWindow
– makeKeyAndOrderFront:
– becomeKeyWindow
– windowDidBecomeKey: delegate method
– resignKeyWindow
– windowDidResignKey: delegate method
– isMainWindow
– canBecomeMainWindow
– makeMainWindow
– becomeMainWindow
– windowDidBecomeMain: delegate method
– resignMainWindow
– windowDidResignMain: delegate method
– isFlushWindowDisabled
– enableFlushWindow
– disableFlushWindow
– flushWindow
– flushWindowIfNeeded
– defaultButtonCell
– setDefaultButtonCell:
– enableKeyEquivalentForDefaultButtonCell
– disableKeyEquivalentForDefaultButtonCell
– areCursorRectsEnabled
– enableCursorRects
– disableCursorRects
– discardCursorRects
– invalidateCursorRectsForView:
– resetCursorRects
+ standardWindowButton:forStyleMask:
– standardWindowButton:
– showsToolbarButton
– setShowsToolbarButton:
+ menuChanged:
– currentEvent
– nextEventMatchingMask:
– nextEventMatchingMask:untilDate:inMode:dequeue:
– discardEventsMatchingMask:beforeEvent:
– postEvent:atStart:
– sendEvent:
– tryToPerform:with:
– selectKeyViewPrecedingView:
– selectKeyViewFollowingView:
– selectPreviousKeyView:
– selectNextKeyView:
– keyViewSelectionDirection
– autorecalculatesKeyViewLoop
– recalculateKeyViewLoop
– setAutorecalculatesKeyViewLoop: