Platforms to show: All Mac Windows Linux Cross-Platform

Back to NSWindowMBS class.

NSWindowMBS.dataWithEPSInsideRect(r as NSRectMBS) as Memoryblock

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Returns EPS data that draws the region of the window within a given rectangle.

This data can be placed on a pasteboard, written to a file, or used to create an NSImage object.

NSWindowMBS.dataWithPDFInsideRect(r as NSRectMBS) as Memoryblock

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Returns PDF data that draws the region of the window within a given rectangle.

This data can be placed on a pasteboard, written to a file, or used to create an NSImage object.

NSWindowMBS.deminiaturize

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 8.4 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
This action method deminimizes the receiver.

Invoke this method to programmatically deminimize a minimized window in the Dock.

NSWindowMBS.disableCursorRects

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Disables all cursor rectangle management within the window.

Use this method when you need to do some special cursor manipulation and you don't want the Application Kit interfering.

NSWindowMBS.disableFlushWindow

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Disables the flushWindow method for the window.

If the window is buffered, disabling flushWindow prevents drawing from being automatically flushed by the NSView display... methods from the window's backing store to the screen. This method permits several views to be drawn before the results are shown to the user.

Flushing should be disabled only temporarily, while the window's display is being updated. Each disableFlushWindow message must be paired with a subsequent enableFlushWindow message. Invocations of these methods can be nested; flushing isn't reenabled until the last (unnested) enableFlushWindow message is sent.

NSWindowMBS.disableScreenUpdatesUntilFlush

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Disables the window's screen updates until the window is flushed.

This method can be invoked to synchronize hardware surface flushes with the window's flushes. The window immediately disables screen updates using the NSDisableScreenUpdates function and reenables screen updates when the window flushes. Sending this message multiple times during a window update cycle has no effect.

Available in Mac OS X v10.4 and later.

NSWindowMBS.disableSnapshotRestoration

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 13.2 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Disable snapshot restoration.

While snapshot restoration is disabled, the window will not be snapshotted for restorable state.
Available in OS X v10.7 and later.

NSWindowMBS.discardCachedImage

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Discards all of the window's cached image rectangles.

An NSWindow object automatically discards its cached image rectangles when it displays.

NSWindowMBS.discardCursorRects

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Invalidates all cursor rectangles in the window.

This method is invoked by resetCursorRects to clear out existing cursor rectangles before resetting them. You shouldn't invoke it in the code you write, but you might want to override it to change its behavior.

NSWindowMBS.display

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Passes a display message down the window's view hierarchy, thus redrawing all views within the window, including the frame view that draws the border, title bar, and other peripheral elements.

You rarely need to invoke this method. NSWindow objects normally record which of their views need display and display them automatically on each pass through the event loop.

NSWindowMBS.displayIfNeeded

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Passes a displayIfNeeded message down the window's view hierarchy, thus redrawing all views that need to be displayed, including the frame view that draws the border, title bar, and other peripheral elements.

This method is useful when you want to modify some number of views and then display only the ones that were modified.

You rarely need to invoke this method. NSWindow objects normally record which of their views need display and display them automatically on each pass through the event loop.

NSWindowMBS.dockTile as Variant

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 11.1 ✅ Yes ❌ No ❌ No ✅ Yes Desktop & iOS
Provides the application's Dock tile.

Available in Mac OS X v10.5 and later.

Returns NSDockTileMBS object for the dock tile.

NSWindowMBS.dragImage(image as NSImageMBS, viewLocation as NSPointMBS, offset as NSSizeMBS, NSEvent as NSEventMBS, pboard as NSPasteboardMBS, source as NSViewMBS, slideFlag as boolean)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacBase Plugin 13.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Begins a dragging session.

image: The object to be dragged.
imageLocation: Location of the image's bottom-left corner in the window's coordinate system. It determines the placement of the dragged image under the pointer.
offset: The pointer's location relative to the mouse-down location. Not used in OS X v10.4 and later.
NSEvent: The left-mouse down event that triggered the dragging operation.
pasteboard: The pasteboard that holds the data to be transferred to the destination.
source: The object serving as the controller of the dragging operation. It must conform to the NSDraggingSource protocol.
slideBack: Specifies whether the drag image should slide back to imageLocation if it's rejected by the drag destination. Pass true to specify slide back behavior or false to specify that it should not.

This method should be invoked only from within a view's implementation of the mouseDown or mouseDragged methods (which overrides the version defined in NSResponder class). Essentially the same as the NSView method of the same name, except that imageLocation is given in the NSWindow object's base coordinate system.

The items on this page are in the following plugins: MBS MacBase Plugin.


The biggest plugin in space...