Platforms to show: All Mac Windows Linux Cross-Platform

Back to NSControlMBS class.

NSControlMBS.ActionSelector as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 13.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The name of the selector.

The new action-message selector to associate with the receiver's cell. Specify NULL to prevent action messages from being sent to the receiver's target.
(Read and Write property)

NSControlMBS.alignment as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The alignment mode of the text in the view's cell.
Example
dim n as NSControlMBS // your control
n.alignment=3

One of the following constants: NSLeftTextAlignment, NSRightTextAlignment,NSCenterTextAlignment, NSJustifiedTextAlignment, or NSNaturalTextAlignment. The default value is NSNaturalTextAlignment.

Constants:

NSLeftTextAlignment = 0
Text is visually left aligned.

NSRightTextAlignment = 1
Text is visually right aligned.

NSCenterTextAlignment = 2
Text is visually center aligned.

NSJustifiedTextAlignment = 3
Text is justified.

NSNaturalTextAlignment = 4
Use the natural alignment of the text's script.
(Read and Write property)

NSControlMBS.attributedStringValue as NSAttributedStringMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The value of the view's cell as an attributed string.

The value of the cell interpreted as an attributed string, or an empty attributed string if the receiver has no cell.

If the control contains many cells (for example, NSMatrix), then the value of the currently selected cell is returned. If the control is in the process of editing the affected cell, then it invokes the validateEditing method before extracting and returning the value.
(Read and Write property)

NSControlMBS.baseWritingDirection as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The initial writing direction used to determine the actual writing direction for text.

One of the following values: NSWritingDirectionNatural, NSWritingDirectionLeftToRight, or NSWritingDirectionRightToLeft. The default value is NSWritingDirectionNatural.

The Text system uses this value as a hint for calculating the actual direction for displaying Unicode characters. You should not need to call this method directly.
(Read and Write property)

NSControlMBS.cell as Variant

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 11.1 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The receiver's cell object.

Cocoa controls often have a frame control and inside a Cell which implements the raw functionality. This way you can for example have a table which embeds such cell controls inside the table cells.

Use this method with great care as it can irrevocably damage the affected control; specifically, you should only use this method in initializers for subclasses of NSControl.
(Read and Write property)

NSControlMBS.controlSize as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 22.1 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The size of the cell.

Use this property to change the rendered size of the cell and its control.

Changing the cell’s control size does not change the font used by the cell. Use the systemFontSize class method of NSFontMBS to obtain an appropriate font based on the new control size.

If you set this property for Xojo's controls, you may need to set it again in Resized events as it may reset to the default.

Use constants:
ControlSizeRegular0Regular
ControlSizeSmall1Small size
ControlSizeMini2Mini size
ControlSizeLarge3Large size
(Read and Write property)

NSControlMBS.currentEditor as NSTextMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Returns the current field editor for the control.

Returns the field editor for the current control, or nil if the receiver does not have a field editor.

When the receiver is a control displaying editable text (for example, a text field) and it is the first responder, it has a field editor, which is returned by this method. The field editor is a single NSTextView object that is shared among all the controls in a window for light text-editing needs. It is automatically instantiated when needed.
(Read only property)

NSControlMBS.doubleValue as Double

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The double value of the control.

(Read and Write property)

NSControlMBS.font as NSFontMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 10.3 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The font used to draw text in the receiver's cell.

f the cell is being edited, the text in the cell is redrawn in the new font, and the cell's editor (the NSText object used globally for editing) is updated with the new font object.
(Read and Write property)

NSControlMBS.ignoresMultiClick as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
A Boolean value indicating whether the receiver ignores multiple clicks made in rapid succession.
Example
dim n as NSControlMBS // your control
n.ignoresMultiClick=True

True if the view ignores multiple clicks; otherwise, false.
(Read and Write property)

NSControlMBS.integerValue as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The value of the receiver's cell as an Integer value.

If the control contains many cells (for example, NSMatrix), then the value of the currently selected cell is returned. If the control is in the process of editing the affected cell, then it invokes the validateEditing method before extracting and returning the value.

Available in OS X v10.5 and later.
(Read and Write property)

NSControlMBS.intValue as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The integer value of the control.
Example
dim n as new nsbuttonMBS(0,0,100,100)

n.intValue=1
MsgBox str(n.intValue) // shows 1
n.intValue=0
MsgBox str(n.intValue) // shows 0

(Read and Write property)

NSControlMBS.isContinuous as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether the receiver's cell sends its action message continuously to its target during mouse tracking.

True if the action message should be sent continuously; otherwise, false.
(Read and Write property)

NSControlMBS.isEnabled as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether the receiver reacts to mouse events.

True if the view responds to mouse events; otherwise, false.
(Read and Write property)

NSControlMBS.refusesFirstResponder as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether the receiver refuses the first responder role.

By default, the user can advance the focus of keyboard events between controls by pressing the Tab key; when this focus—or first responder status—is indicated for a control (by the insertion point or, for nontext controls, a faint rectangle), the user can activate the control by pressing the Space bar.
(Read and Write property)

NSControlMBS.selectedCell as NSCellMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Returns the receiver's selected cell.

The default implementation of this method simply returns the control's associated cell (or nil if no cell has been set). Subclasses of NSControl that manage multiple cells (such as NSMatrix and NSForm) must override this method to return the cell selected by the user.
(Read only property)

NSControlMBS.selectedTag as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The tag of the views's selected cell.

(Read only property)

NSControlMBS.stringValue as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The string value of the control.

(Read and Write property)

NSControlMBS.tag as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Cocoa Controls MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The tag identifying the object.

You can set this property to the value you need.
(Read and Write property)

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


The biggest plugin in space...