Platforms to show: All Mac Windows Linux Cross-Platform
NSTextListMBS class
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
class | Cocoa Text | MBS MacBase Plugin | 18.1 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
The visible elements of the list, including list markers, appear in the text as they do for lists created by hand. The list object, however, allows the list to be recognized as such by the text system. This enables automatic creation of markers and spacing. Text lists are used in HTML import and export.
Text lists appear as attributes on paragraphs, as part of the paragraph style. An NSParagraphStyle may have an array of text lists, representing the nested lists containing the paragraph, in order from outermost to innermost. For example, if list1 contains four paragraphs, the middle two of which are also in the inner list2, then the text lists array for the first and fourth paragraphs is (list1), while the text lists array for the second and third paragraphs is (list1, list2).
The methods implementing this are textLists on NSParagraphStyle, and textLists on NSMutableParagraphStyle.
In addition, NSAttributedString has convenience methods for lists, such as rangeOfTextList, which determines the range covered by a list, and itemNumberInTextList, which determines the ordinal position within a list of a particular item.
- 4 properties
- property Handle as Integer
- property listOptions as Integer
- property markerFormat as String
- property startingItemNumber as Integer
- 3 methods
- method Constructor(format as String, OptionsMask as Integer = 0)
- method copy as NSTextListMBS
- method markerForItemNumber(ItemNum as Integer) as String
- 17 shared methods
- shared method NSTextListMarkerBox as String
- shared method NSTextListMarkerCheck as String
- shared method NSTextListMarkerCircle as String
- shared method NSTextListMarkerDecimal as String
- shared method NSTextListMarkerDiamond as String
- shared method NSTextListMarkerDisc as String
- shared method NSTextListMarkerHyphen as String
- shared method NSTextListMarkerLowercaseAlpha as String
- shared method NSTextListMarkerLowercaseHexadecimal as String
- shared method NSTextListMarkerLowercaseLatin as String
- shared method NSTextListMarkerLowercaseRoman as String
- shared method NSTextListMarkerOctal as String
- shared method NSTextListMarkerSquare as String
- shared method NSTextListMarkerUppercaseAlpha as String
- shared method NSTextListMarkerUppercaseHexadecimal as String
- shared method NSTextListMarkerUppercaseLatin as String
- shared method NSTextListMarkerUppercaseRoman as String
Constants
Constant | Value | Description |
---|---|---|
NSTextListPrependEnclosingMarker | 1 |
One of the constants for options.
Specifies that a nested list should include the marker for its enclosing superlist before its own marker. |
This class has no sub classes.
Some methods using this class:
- NSAttributedStringMBS.itemNumberInTextList(list as NSTextListMBS, location as Integer) as Integer
- NSAttributedStringMBS.rangeOfTextList(list as NSTextListMBS, location as Integer) as NSRangeMBS
- NSMutableParagraphStyleMBS.setTextLists(TextLists() as NSTextListMBS)
- NSParagraphStyleMBS.textLists as NSTextListMBS()
Some properties using for this class:
- NSParagraphStyleMBS.firstTextList as NSTextListMBS
Some examples using this class:
Blog Entries
- MonkeyBread Software Releases the MBS Xojo Plugins in version 23.4
- MBS Xojo Plugins, version 23.4pr3
- MonkeyBread Software Releases the MBS Xojo Plugins in version 18.1
- MBS Xojo Plugins, version 18.1pr3
Xojo Developer Magazine
Release notes
- Version 23.4
- Enabled NSTextListMBS class for iOS.
- Version 18.1
- Added NSTextListMBS class and related methods for NSMutableParagraphStyleMBS, NSParagraphStyleMBS and NSAttributedStringMBS class.
The items on this page are in the following plugins: MBS MacBase Plugin.