What problem does it solve? Text edits, container resizes, and attribute changes can leave stale or missing layout in AppKit/UIKit text views, and it is hard to know which API actually triggers recomputation. This Skill provides the authoritative invalidation model for both TextKit 1 (NSLayoutManager) and TextKit 2 (NSTextLayoutManager) so you can reason about when layout is marked dirty, when it is recomputed lazily, and which manual invalidation call to use. ## Core Features & Use Cases - Dual-stack invalidation model: Documents what triggers glyph and layout invalidation in TextKit 1 versus element regeneration and fragment invalidation in TextKit 2, including the load-bearing performEditingTransaction wrapper. - Forcing and scoping layout: Covers ensureLayout variants scoped by container, character range, glyph range, and bounding rect, plus invalidateGlyphs, invalidateLayout, and invalidateDisplay. - Debugging sidecar: A references file with a stale-layout symptom decision tree, symbolic breakpoints, os_signpost profiling patterns, and viewport controller fragment-recycling guidance. - Use Case: After a programmatic text edit your TextKit 2 view shows stale fragments. The Skill explains that the mutation must run inside contentStorage.performEditingTransaction so elements regenerate and the viewport controller re-runs layout. ## Quick Start Ask the AI to explain why your TextKit 2 text view shows stale layout after a programmatic edit and which invalidation call fixes it.