Merge branch 'worktree-agent-a1681d54b6f75fd9a'

This commit is contained in:
2026-11-22 18:24:33 +00:00
4 changed files with 179 additions and 1 deletions
+8
View File
@@ -50,6 +50,14 @@ timeline) in the self-time lists are measurement overhead.
out for its max width, its min width and then its real width. Caching per
cell text, or skipping the min pass when the max widths already fit, cuts
it.
Change (2026-11-22): the min pass was already free (RenderParagraph
answers min and max from one infinite-width layout of its intrinsics
painter), so skipping it saves nothing. `chat_table_cell_measure.dart`
now caches each cell's min/max width across render objects, keyed by the
cell's markdown and its paragraph's style, scaler, direction and locale,
cleared on font changes. A table that scrolls back in or a chat opened
again lays each cell out once (its real width) instead of twice; a first
view still measures. Not yet re-benchmarked.
4. **Per-delta transcript rebuild**: `transcriptRows` 41 ms,
`withChatShownItems` 28 ms (`_rowTime` 15 ms), `ChatRowKeys.forRows`
16 ms, `sliver_animated_extent` layout 250 ms inclusive over the stream.