An NSForm
object is a vertical matrix of NSForm
objects to implement the fields.
SDK
- macOS 10.0–10.10Deprecated
Framework
- App
Kit
Declaration
class NSForm : NSMatrix
An NSForm
object is a vertical matrix of NSForm
objects to implement the fields.
SDK
Framework
class NSForm : NSMatrix
func add Entry(String) -> NSForm Cell
Adds a new entry to the end of the receiver and gives it the specified title.
func insert Entry(String, at: Int) -> NSForm Cell!
Inserts an entry with the specified title into the receiver.
func remove Entry(at: Int)
Removes and releases the entry at the specified index.
func set Bezeled(Bool)
Sets whether the receiver's entries should display a bezel around their editable text.
func set Bordered(Bool)
Sets whether the receiver's entries should display a border around their editable text fields.
func set Entry Width(CGFloat)
Sets the width of all the entries in the receiver.
func set Frame Size(NSSize)
Sets the size of the receiver’s frame size to the specified value.
func set Interline Spacing(CGFloat)
Sets the spacing between entries
func set Title Alignment(NSText Alignment)
Sets the alignment for all of the entry titles.
func set Title Base Writing Direction(NSWriting Direction)
Sets the writing direction for the title of every control embedded in the form.
func set Text Alignment(NSText Alignment)
Sets the alignment for all of the receiver’s editable text.
func set Text Base Writing Direction(NSWriting Direction)
Sets the writing direction for the text content of every control embedded in the form.
func set Title Font(NSFont)
Sets the font for all of the entry titles.
func set Text Font(NSFont)
Sets the font for all of the receiver’s editable text fields
func index Of Cell(with Tag: Int) -> Int
Returns the index of the entry whose tag is tag
.
func index Of Selected Item() -> Int
Returns the index of the selected entry.
func cell(at: Int) -> Any!
Returns the entry at the specified index.
func draw Cell(at: Int)
Displays the entry at the specified index.
func preferred Text Field Width() -> CGFloat
The preferred width of the form’s cells when using Auto Layout.
func set Preferred Text Field Width(CGFloat)
Sets the preferred text field width used by Auto Layout.
func select Text(at: Int)
Selects the entry at the specified index.
class NSForm Cell
The NSForm
class is used to implement text entry fields in a form. The left part of an NSForm
object contains a title. The right part contains an editable text entry field.
class NSMenu Item Cell
An object that handles the measurement and display of a single menu item in its encompassing frame.