On Fri, 30 Oct 2026 02:58:31 GMT, Prasanta Sadhukhan <[email protected]>
wrote:
>> src/java.desktop/share/classes/javax/swing/text/html/FrameSetView.java line
>> 320:
>>
>>> 318: char ch = mixedStr.charAt(i);
>>> 319: if (Character.isDigit(ch)) {
>>> 320: int digit = Character.digit(ch, 10);
>>
>> This code is only used for percentages. So surely we just bail when it hits
>> 100 and return that ..
>
> It will fix the overflow but the capping will cause a behaviour change in
> frame scaling.
> FrameSetView adds the percentages together. If their total exceeds 100, it
> scales each value using:
> normalized = value * 100 / total; as seen in l150
>
> Suppose frame has 2 columns with 200%,50% ratio then we will have
> First frame: 200 × 100 / 250 = 80%
> Second frame: 50 × 100 / 250 = 20%
> This preserves their original 4:1 ratio.
>
> With the new cap, the parser returns 100 and 50, giving a total of 150
> First frame: 100 × 100 / 150 = 66%
> Second frame: 50 × 100 / 150 = 33%
> so capping each percentage changes the proportions
>
> With current PR fix, this ratio is maintained..
As in, "the team gave 1000% effort today" ? Seems a bit dubious, but OK.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/33623#discussion_r4426516635