Apple Rich Text Fundamentals (paper.pro)

The article explains how Apple’s NSAttributedString represents rich text as a plain string plus per-range attribute key–value pairs. It outlines the API areas for reading, updating, converting, and drawing attributed strings, then drills into styling attributes—starting with color options (foreground, background, stroke, underline, strike), and how they map to NSColor/UIColor. It also covers font-related attributes such as font name/size and typography controls like kern, baseline offset, superscript, and ligatures.

April 05, 2026 13:30 Source: Hacker News