TextKit Overview

TextKit goes back to the NeXT era, before Mac OS X was a thing. After the relatively new Cocoa frameworks for Mac app programming were introduced and introduced the “Cocoa Text System” title, iOS and UIKit stuck with “TextKit”, and in 2021 TextKit 2 returned.

This revolves around everything related to accepting textual user input on the Mac:

Even NSTextFields are just reusing a shared NSTextView, called the window’s field editor. It’s everywhere.

Dec 4 2022

ChatGPT: Publish NSTextView Changes to ReSwift, but Also Use a Lamport Clock

Conversation log with ChatGPT.

Sep 23 2022

NSTextView (Plain Text) and the Pasteboard: PasteboardType.string Is Not Handled

Sep 21 2022

Overview of Attribute Fixing in NSTextStorage

Sep 13 2022

How to Fix When Some Text Changes Don't Come with Automatic Undo?

May 9 2022

PSA: TextKit 2 Has Bugs

May 9 2022

STTextView: A TextKit 2 Text Editor without NSTextView

May 2 2022

TextKit 2 Example App from the Apple Docs

Mar 9 2022

More Swifty NSAttributedString Attribute Query Methods

Nov 24 2021

What Do You Get When You Drag and Drop a PNG File From Finder Into an NSTextView?

Sep 21 2021

NSTextView Performance May Degrade for Large Plain Text Documents When usesFontPanel Is Active

Aug 26 2021

Retry Imperative Conditions with RxSwift Using a Delay

Jun 23 2021

TextKit 2 Introduces Block-Based Layout

Feb 10 2021

Disable NSTextAttachment Action and Sharing Services Menu Drop-Down

Nov 18 2020

Decorate NSGlyphStorage to Replace Glyphs On-the-Fly

Oct 19 2020

Follow Link at Insertion Point in NSTextView

Oct 19 2019

Fix Missing Font Fallbacks for NSTextView

Jun 23 2018

NSTextField usesSingleLineMode Stops Working When You Implement NSTextViewDelegate Methods

Apr 24 2018

RxSwift: Typing/Idle Event Stream for NSTextView

Mar 7 2018

NSTextView's Default Insertion Point and Selected Text Colors

Feb 6 2018

NSTextView: When Did the Find Bar Disappear?

Nov 29 2017

Why the Selection Changes When You Do Syntax Highlighting in a NSTextView and What You Can Do About It

Aug 9 2017

Show a fat iOS-Style Insertion Point in NSTextView

Jul 15 2017

Setting the NSTextView Line Height in a Beautiful Way

Jul 11 2017

Typewriter Mode: Adding Overscrolling to the Text View

Mar 3 2017

Setting the Line Height of a NSTextView