Platforms to show: All Mac Windows Linux Cross-Platform

NSTextContainerMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class Cocoa Text MBS MacCocoa Plugin 12.4 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The NSTextContainer class defines a region where text is laid out.

An NSLayoutManager uses NSTextContainer to determine where to break lines, lay out portions of text, and so on. NSTextContainer defines rectangular regions, but you can create subclasses that define regions of other shapes, such as circular regions, regions with holes in them, or regions that flow alongside graphics.

Line Movement Constants

Constant Value Description
NSLineDoesntMove 0 Line has no movement.
NSLineMovesDown 3 Lines move from top to bottom.
NSLineMovesLeft 1 Lines move from right to left.
NSLineMovesRight 2 Lines move from left to right.
NSLineMovesUp 4 Lines move from bottom to top.

Line Sweep Direction Constants

Constant Value Description
NSLineSweepDown 2 Characters move from top to bottom.
NSLineSweepLeft 0 Characters move from right to left.
NSLineSweepRight 1 Characters move from left to right.
NSLineSweepUp 3 Characters move from bottom to top.

This class has no sub classes.

Some methods using this class:

Some properties using for this class:

Some examples using this class:

Blog Entries

Release notes


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


NSTextCheckingResultMBS   -   NSTextFieldCellMBS


The biggest plugin in space...