Instance Method


Draws or erases the insertion point.


func drawInsertionPoint(in rect: NSRect, color: NSColor, turnedOn flag: Bool)



The rectangle in which to draw the insertion point.


The color with which to draw the insertion point.


true to draw the insertion point, false to erase it.


The focus must be locked on the receiver when this method is invoked. You should not need to invoke this method directly.

See Also

Controlling Display

func setNeedsDisplay(NSRect, avoidAdditionalLayout: Bool)

Marks the receiver as requiring display.

var shouldDrawInsertionPoint: Bool

A Boolean value that determines whether the receiver should draw its insertion point.

func drawBackground(in: NSRect)

Draws the background of the text view.

func setConstrainedFrameSize(NSSize)

Attempts to set the frame size as if by user action.

func cleanUpAfterDragOperation()

Releases the drag information still existing after the dragging session has completed.

func showFindIndicator(for: NSRange)

Causes a temporary highlighting effect to appear around the visible portion (or portions) of the specified range.