Misplaced Pages

TextEdit (API)

Article snapshot taken from[REDACTED] with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.
For the text editor, see TextEdit.
This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these messages)
This article does not cite any sources. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed.
Find sources: "TextEdit" API – news · newspapers · books · scholar · JSTOR (February 2014) (Learn how and when to remove this message)
This article may be confusing or unclear to readers. Please help clarify the article. There might be a discussion about this on the talk page. (February 2014) (Learn how and when to remove this message)
(Learn how and when to remove this message)

TextEdit was the name of a collection of application programming interfaces (APIs) in the classic Mac OS for performing text editing.

These APIs were originally designed to provide a common text handling system to support text entry fields in dialog boxes and other simple text editing within the Macintosh GUI. Over time, they were extended to provide more advanced text editing features, but its limited original scope led to fundamental limitations. Apple repeatedly stated that TextEdit was not a word processor, and therefore providing rich text editing was always left to third-party developers.

Basic limitations of TextEdit include:

  • only provides support for 8-bit character sets
  • 16-bit internal indexing limits text to a maximum length of about 32,000 characters
  • use of QuickDraw for glyph rendering limited the maximum height of a text block to 32,767 pixels - this could be encountered well before the character limit was hit with larger font sizes.

The first incarnation of TextEdit provided support for only a single style of text, which was applied to all text in the block. This was more than adequate for its intended use, supporting text entry fields. Later, support was added for styled text so that TextEdit could be used for more complex text editing tasks, such as text editing areas in web browsers, etc.

TextEdit remains part of the Carbon API on macOS, but has been superseded by numerous other solutions including ATSUI in Carbon, the third party WASTE text engine, as well as NSText and related classes within Cocoa.

Categories:
TextEdit (API) Add topic