Platforms to show: All Mac Windows Linux Cross-Platform
Back to NSClipViewMBS class.
NSClipViewMBS.autoscroll(theEvent as NSEventMBS) as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
theEvent's location should be expressed in the window's base coordinate system (which it normally is), not the receiving NSClipView's. Returns true if any scrolling is performed; otherwise returns false.
Never invoke this method directly; instead, the NSClipView's document view should repeatedly send itself autoscroll: messages when the cursor is dragged outside the NSClipView's frame during a modal event loop initiated by a mouse-down event. The NSView class implements autoscroll to forward the message to the receiver's superview; thus the message is ultimately forwarded to the NSClipView.
NSClipViewMBS.backgroundColor as NSColorMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
(Read and Write computed property)
NSClipViewMBS.constrainScrollPoint(newOrigin as NSPointMBS) as NSPointMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
For example, if proposedNewOrigin's y coordinate lies to the left of the document view's origin, then the y coordinate returned is set to that of the document view's origin.
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
On success the handle property is not zero.
See also:
NSClipViewMBS.Constructor(Handle as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
The handle is casted to a NSClipView and the plugin retains this handle.
See also:
NSClipViewMBS.Constructor(left as Double, top as Double, width as Double, height as Double)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
On success the handle property is not zero.
See also:
NSClipViewMBS.copiesOnScroll as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
If true, the receiver copies the existing rendered image to its new location while scrolling and only draws exposed portions of its document view. If false, the receiver always forces its document view to draw itself on scrolling.
(Read and Write computed property)
NSClipViewMBS.documentCursor as Variant
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Value is an NSCursorMBS object.
(Read and Write computed property)
NSClipViewMBS.documentRect as NSRectMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
In other words, this rectangle is always at least as large as the receiver itself.
The document rectangle is used in conjunction with an NSClipView's bounds rectangle to determine values for the indicators of relative position and size between the NSClipView and its document view. For example, NSScrollView uses these rectangles to set the size and position of the knobs in its scrollers. When the document view is much larger than the NSClipView, the knob is small; when the document view is near the same size, the knob is large; and when the document view is the same size or smaller, there is no knob.
NSClipViewMBS.documentView as NSViewMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Gets or sets the receiver's document view. On set removes any previous document view, and sets the origin of the receiver's bounds rectangle to the origin of the new view's frame rectangle.
If the receiver is contained in an NSScrollView, you should set the NSScrollView DocumentView instead, so it can perform whatever updating it needs.
In the process of setting the document view, this method registers the receiver for the notifications NSViewFrameDidChangeNotification and NSViewBoundsDidChangeNotification, adjusts the key view loop to include the new document view, and updates a parent NSScrollView's display if needed using reflectScrolledClipView.
(Read and Write computed property)
NSClipViewMBS.documentVisibleRect as NSRectMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Note that this rectangle doesn't reflect the effects of any clipping that may occur above the NSClipView itself. To get the portion of the document view that's guaranteed to be visible, send it a visibleRect message.
NSClipViewMBS.drawsBackground as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
If your NSClipView is enclosed in an NSScrollView, you should set the DrawsBackground on the NSScrollView.
(Read and Write computed property)
NSClipViewMBS.reflectScrolledClipView(clipView as NSClipViewMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSClipViewMBS.scrollClipView(clipview as NSClipViewMBS, toPoint as NSPointMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSClipViewMBS.scrollToPoint(newOrigin as NSPointMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSClipViewMBS.viewBoundsChanged(notification as NSNotificationMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSClipViewMBS.viewFrameChanged(notification as NSNotificationMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacControls Plugin | 11.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
This event notifies you, that the control changed it's bounding frame, which is position and/or size.
The items on this page are in the following plugins: MBS MacControls Plugin.