Nerdy internals of an Apple text editor
(papereditor.app)
from tedu@azorius.net to programming@azorius.net on 06 Mar 2024 00:28
https://azorius.net/g/programming/p/dwKvgQ35pLLFxK3847-Nerdy-internals-of-an-Apple-text-editor
from tedu@azorius.net to programming@azorius.net on 06 Mar 2024 00:28
https://azorius.net/g/programming/p/dwKvgQ35pLLFxK3847-Nerdy-internals-of-an-Apple-text-editor
To understand how text editing works in native Apple text editors, we first need to discuss the centerpiece of the whole system β the TextView class. Technically, NSTextView and UITextView have their differences, but the API is similar enough that we can treat them as a single TextView class. I will highlight the differences where necessary.
TextView is a massive component that only grows in complexity with each release of respective operating systems. The TextEdit app consists almost entirely of a single TextView. When a single class can be used to build an entire app β you know itβs a beast.
#programming
threaded - newest