Xojo Conferences
XDCMay2019MiamiUSA

Platforms to show: All Mac Windows Linux Cross-Platform

Previous items

NSTextMBS.minSizeHeight as Double
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Returns the receiver's minimum height.

Feedback, Comments & Corrections

NSTextMBS.minSizeWidth as Double
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Returns the receiver's maximum width.

Feedback, Comments & Corrections

NSTextMBS.paste
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method pastes text from the general pasteboard at the insertion point or over the selection.

Feedback, Comments & Corrections

NSTextMBS.pasteFont
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method pastes font information from the font pasteboard onto the selected text or insertion point of a rich text object, or over all text of a plain text object.

Feedback, Comments & Corrections

NSTextMBS.pasteRuler
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method pastes paragraph style information from the ruler pasteboard onto the selected paragraphs of a rich text object.

Feedback, Comments & Corrections

NSTextMBS.readRTFDFromFile(file as folderitem) as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Attempts to read the RTFD file, returning true if successful and false if not.
Notes: file should be the path for an .rtf file or an .rtfd file wrapper, not for the RTF file within an .rtfd file wrapper.

Feedback, Comments & Corrections

NSTextMBS.replaceCharactersInRangeWithRTF(start as Integer, length as Integer, rtfData as MemoryBlock)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Replaces the characters in the given range with RTF text interpreted from the given RTF data.
Notes:
This method applies only to rich text objects.

This method does not include undo support by default. Clients must invoke shouldChangeTextInRange to include this method in an undoable action.

This method is designed for transferring text from out-of-process sources such as the pasteboard. In most cases, programmatic modification of the text is best done by operating on the text storage directly, using the general methods of NSMutableAttributedString.

Feedback, Comments & Corrections

NSTextMBS.replaceCharactersInRangeWithRTFD(start as Integer, length as Integer, rtfdData as MemoryBlock)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Replaces the characters in the given range with RTFD text interpreted from the given RTFD data.
Notes:
This method applies only to rich text objects.

This method does not include undo support by default. Clients must invoke shouldChangeTextInRange to include this method in an undoable action.

This method is designed for transferring text from out-of-process sources such as the pasteboard. In most cases, programmatic modification of the text is best done by operating on the text storage directly, using the general methods of NSMutableAttributedString.

Feedback, Comments & Corrections

NSTextMBS.replaceCharactersInRangeWithString(start as Integer, length as Integer, text as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Replaces the characters in the given range with those in the given string.
Notes:
For a rich text object, the text is assigned the formatting attributes of the first character of the text it replaces, or of the character immediately before aRange if the range's length is 0. If the range's location is 0, the formatting attributes of the first character in the receiver are used.

This method does not include undo support by default. Clients must invoke shouldChangeTextInRange to include this method in an undoable action.

In most cases, programmatic modification of the text is best done by operating on the text storage directly, using the general methods of NSMutableAttributedString.

Feedback, Comments & Corrections

NSTextMBS.RTFDFromRange(start as Integer, length as Integer) as MemoryBlock
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Returns a string that contains an RTFD stream corresponding to the characters and attributes within aRange.
Notes:
Raises an NSRangeException if any part of aRange lies beyond the end of the receiver's characters.

When writing data to the pasteboard, you can use the memoryblock object as the first argument to NSPasteboard's setDataForType method, with a second argument of NSRTFDPboardType.

Feedback, Comments & Corrections

NSTextMBS.RTFFromRange(start as Integer, length as Integer) as MemoryBlock
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: eturns a string object that contains an RTF stream corresponding to the characters and attributes within aRange, omitting any attachment characters and attributes.
Notes:
Raises an NSRangeException if any part of aRange lies beyond the end of the receiver's characters.

When writing data to the pasteboard, you can use the memoryblock as the first argument to NSPasteboard's setDataForType method, with a second argument of NSRTFPboardType.

Feedback, Comments & Corrections

NSTextMBS.scrollRangeToVisible(start as Integer, length as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Scrolls the receiver in its enclosing scroll view so the first characters of aRange are visible.

Feedback, Comments & Corrections

NSTextMBS.selectAll
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method selects all of the receiver's text.

Feedback, Comments & Corrections

NSTextMBS.selectedRange as NSRangeMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Cocoa MBS MacCocoa Plugin 9.6 Yes No No Yes, macOS only No
Function: The range of selected characters.
Example:
dim t as NSTextViewMBS = TextArea1.NSTextViewMBS
dim s as NSTextStorageMBS = t.textStorage

const NSUnderlineStyleSingle = 1

dim r as NSRangeMBS = t.selectedRange
s.addAttribute NSAttributedStringMBS.NSStrikethroughStyleAttributeName, NSUnderlineStyleSingle, r
Notes: (Read and Write computed property)

Feedback, Comments & Corrections

NSTextMBS.setFontForRange(font as NSFontMBS, start as Integer, length as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Sets the font of characters within the given range to font.
Notes:
This method applies only to a rich text object.

This method does not include undo support by default. Clients must invoke shouldChangeTextInRanges to include this method in an undoable action.

Feedback, Comments & Corrections

NSTextMBS.setMaxSize(width as Double, height as Double)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Sets the receiver's maximum size.

Feedback, Comments & Corrections

NSTextMBS.setMinSize(width as Double, height as Double)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Sets the receiver's minimum size.

Feedback, Comments & Corrections

NSTextMBS.setTextColorForRange(colorValue as NSColorMBS, start as Integer, length as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Sets the text color of characters within the given range to colorValue.
Notes:
Removes the text color attribute if colorValue is nil. This method applies only to rich text objects.

This method does not include undo support by default. Clients must invoke shouldChangeTextInRange to include this method in an undoable action.

Feedback, Comments & Corrections

NSTextMBS.showGuessPanel
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 7.8 Yes No No Yes, macOS only No
Function: This action method opens the Spelling panel, allowing the user to make a correction during spell checking.

Feedback, Comments & Corrections

NSTextMBS.sizeToFit
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Resizes the receiver to fit its text.
Notes: The text view will not be sized any smaller than its minimum size, however.

Feedback, Comments & Corrections

NSTextMBS.subscript
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method applies a subscript attribute to selected text (or all text if the receiver is a plain text object), lowering its baseline offset by a predefined amount.

Feedback, Comments & Corrections

NSTextMBS.superscript
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method applies a superscript attribute to selected text (or all text if the receiver is a plain text object), raising its baseline offset by a predefined amount.

Feedback, Comments & Corrections

NSTextMBS.text as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Cocoa MBS MacCocoa Plugin 7.8 Yes No No Yes, macOS only No
Function: The characters of the text.
Notes:
For performance reasons, this method returns the current backing store of the text object. If you want to maintain a snapshot of this as you manipulate the text storage, you should make a copy of the appropriate substring.
(Read and Write computed property)

Feedback, Comments & Corrections

NSTextMBS.textColor as NSColorMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: The text color.
Notes: (Read and Write computed property)

Feedback, Comments & Corrections

NSTextMBS.textLength as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 12.5 Yes No No Yes, macOS only No
Function: Returns the length of the text in unicode chars.

Feedback, Comments & Corrections

NSTextMBS.toggleRuler
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method shows or hides the ruler, if the receiver is enclosed in a scroll view.

Feedback, Comments & Corrections

NSTextMBS.underline
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Adds the underline attribute to the selected text attributes if absent; removes the attribute if present.
Notes:
If there is a selection and the first character of the selected range has any form of underline on it, or if there is no selection and the typing attributes have any form of underline, then underline is removed; otherwise a single simple underline is added.

Operates on the selected range if the receiver contains rich text. For plain text the range is the entire contents of the receiver.

Feedback, Comments & Corrections

NSTextMBS.unscript
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: This action method removes any superscripting or subscripting from selected text (or all text if the receiver is a plain text object).

Feedback, Comments & Corrections

NSTextMBS.usesFontPanel as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Cocoa MBS MacCocoa Plugin 7.8 Yes No No Yes, macOS only No
Function: A Boolean value that indicates whether the receiver uses the Font panel.
Notes: (Read and Write computed property)

Feedback, Comments & Corrections

NSTextMBS.writeRTFDToFile(file as folderitem, atomically as boolean) as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method Cocoa MBS MacCocoa Plugin 8.4 Yes No No Yes, macOS only No
Function: Writes the receiver's text as RTF with attachments to a file or directory at file.
Notes: Returns true on success and false on failure. If atomically is true, attempts to write the file safely so that an existing file at path is not overwritten, nor does a new file at path actually get created, unless the write is successful.

Feedback, Comments & Corrections

Previous items

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




Links
MBS FileMaker blog