Platforms to show: All Mac Windows Linux Cross-Platform
Back to NSTabViewMBS class.
NSTabViewMBS.addTabViewItem(tabViewItem as NSTabViewItemMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
tabViewItem: The tab view item to be added.
The item is added at the end of the array of tab items, so the new tab appears on the right side of the view.
NSTabViewMBS.allowsTruncatedLabels as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Value is true if the receiver allows truncating for labels that don't fit on a tab, otherwise false.
The default is true.
When truncating is allowed, the tab view inserts an ellipsis, if necessary, to fit a label in the tab.
(Read and Write computed property)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
On success the handle property is not zero.
See also:
NSTabViewMBS.Constructor(Handle as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.3 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
The handle is casted to a NSTabView and the plugin retains this handle.
See also:
NSTabViewMBS.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 MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
On success the handle property is not zero.
See also:
NSTabViewMBS.contentRect as NSRectMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
This area does not include the space required for the receiver's tabs or borders (if any).
NSTabViewMBS.controlSize as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Use NSRegularControlSize, NSSmallControlSize or NSMiniControlSize.
(Read and Write computed property)
NSTabViewMBS.controlTint as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Use NSDefaultControlTint, NSBlueControlTint, NSGraphiteControlTint or NSClearControlTint.
(Read and Write computed property)
NSTabViewMBS.drawsBackground as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
True if the receiver draws a background color when the tab view type is NSNoTabsNoBorder, otherwise false.
If the receiver uses bezeled edges or a line border, the appropriate background color for that border is used.
(Read and Write computed property)
NSTabViewMBS.font as NSFontMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Tab height is adjusted automatically to accommodate a new font size. If the view allows truncating, tab labels are truncated as needed.
(Read and Write computed property)
NSTabViewMBS.indexOfTabViewItem(tabViewItem as NSTabViewItemMBS) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
The zero-based index of tabViewItem, or [NSNotFound] if the item is not found.
NSTabViewMBS.indexOfTabViewItemWithIdentifier(identifier as Variant) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Returns nil on any error.
NSTabViewMBS.insertTabViewItem(tabViewItem as NSTabViewItemMBS, atIndex as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
tabViewItem: The tab view item to be added.
index: The index at which to insert the tab view item. The index parameter is zero-based.
NSTabViewMBS.minimumSize as NSSizeMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
You can use the value returned by this method to limit how much a user can resize a tab view.
NSTabViewMBS.numberOfTabViewItems as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSTabViewMBS.removeTabViewItem(tabViewItem as NSTabViewItemMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSTabViewMBS.selectedTabViewItem as NSTabViewItemMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSTabViewMBS.selectFirstTabViewItem
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSTabViewMBS.selectLastTabViewItem
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSTabViewMBS.selectNextTabViewItem
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
If the currently visible item is the last item in the sequence, this method does nothing, and the last page remains displayed.
NSTabViewMBS.selectPreviousTabViewItem
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
If the currently visible item is the first item in the sequence, this method does nothing, and the first page remains displayed.
NSTabViewMBS.selectTabViewItem(tabViewItem as NSTabViewItemMBS)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Returns the currently selected tab view item, or nil if no item is selected.
NSTabViewMBS.selectTabViewItemAtIndex(index as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
The index parameter is base 0.
NSTabViewMBS.selectTabViewItemWithIdentifier(identifier as Variant)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
NSTabViewMBS.tabViewItemAtIndex(index as Integer) as NSTabViewItemMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
index: The index at which to insert the tab view item. The index parameter is zero-based.
Returns the tab view item at the specified index.
Some examples using this method:
NSTabViewMBS.tabViewItemAtPoint(x as Double, y as Double) as NSTabViewItemMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Returns the tab view item under the hit point, or nil if no tab view item is under that location.
You can use this method to find a tab view item based on a user's mouse click.
NSTabViewMBS.tabViewItems as NSTabViewItemMBS()
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
A tab view keeps an array containing one tab view item for each tab in the view.
NSTabViewMBS.tabViewType as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Cocoa Controls | MBS MacCocoa Plugin | 10.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
Use constants: NSTopTabsBezelBorder, NSLeftTabsBezelBorder, NSBottomTabsBezelBorder, NSRightTabsBezelBorder, NSNoTabsBezelBorder, NSNoTabsLineBorder or NSNoTabsNoBorder.
(Read and Write computed property)
Some examples using this property:
The items on this page are in the following plugins: MBS MacCocoa Plugin.