0a5d176a47bfa874fe6a8f963eaa148cde2b49e2
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
Description
No description provided
54 MiB
Languages
Java
97.4%
CSS
1.5%
Python
0.9%
JavaScript
0.2%