On Tue, 1 Sep 2026 00:16:18 GMT, Jose Pereda <[email protected]> wrote:
>> Andy Goryachev has updated the pull request incrementally with one
>> additional commit since the last revision:
>>
>> review comments
>
> Changes look good, tests pass with them. I've left some comments.
Thank you @jperedadnr , your review and comments helped a lot!
> modules/jfx.incubator.richtext/src/main/java/com/sun/jfx/incubator/scene/control/richtext/RangeInfo.java
> line 96:
>
>> 94:
>> 95: public double findHitMidpoint(double y) {
>> 96: if (lines != null) {
>
> if y < lines[0], y is above the first line, i.e. the top padding space, or
> if y > lines[lines.length - 1], y is below the last line, the bottom padding
> space,
> then this method will return the midpoint of the entire paragraph, instead of
> a valid value, close to the y position (mid first line, or mid last line).
> This issue can be appreciated in the demos if you have a paragraph of several
> lines and wrap text set: moving down from one paragraph to the other not
> always leads you to the beginning of the next one, unexpectedly.
good catch!
-------------
PR Comment: https://git.openjdk.org/jfx/pull/2280#issuecomment-5499877650
PR Review Comment: https://git.openjdk.org/jfx/pull/2280#discussion_r3908062762