chris.giteaandClaude Sonnet 5 0a5d176a47 fix(gallery): fix hashRow's SelectableTextFlow reporting a 0 preferred width
Found the real cause behind MediaInfoPane's vertical scrollbar: not a
phantom estimate at all, a genuinely too-tall row. SelectableTextFlow's
own constructor sets prefWidth to Region.USE_PREF_SIZE — a sentinel
Region's own doc says applies to minWidth/maxWidth only ("this bound
equals whatever prefWidth computes to"); Region.prefWidth(height) has
no special case for it, so it falls through its own "negative override
-> 0" branch (confirmed against javafx-graphics' own Region source).
Every layout pass reading this flow's preferred width then sees a flat
0, and the 64-character hash wraps one/two characters per line instead
of the 2-3 lines the row was actually designed around.

hashRow now resets it to the ordinary USE_COMPUTED_SIZE right after
construction, restoring real natural-width computation; the existing
minWidth(0) + HGrow.ALWAYS on the same node is what then shrinks it
back down to fit, same as originally intended.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016okXfGz39FtQawFWDYpQ5C
2026-09-22 23:03:28 -04:00
2026-08-22 17:52:02 -04:00
2026-08-22 11:54:20 -04:00
2026-08-22 11:54:20 -04:00
2026-08-22 11:54:20 -04:00
2026-08-08 23:21:21 -04:00
2026-07-26 18:49:07 -04:00
2026-07-26 18:49:07 -04:00
S
Description
No description provided
54 MiB
Languages
Java 97.4%
CSS 1.5%
Python 0.9%
JavaScript 0.2%