RFR: 8341670: [Text, TextFlow] Public API for Text Layout Info [v23]
Kevin Rushforth
kcr at openjdk.org
Thu May 1 18:56:01 UTC 2025
On Mon, 7 Apr 2025 19:14:40 GMT, Michael Strauß <mstrauss at openjdk.org> wrote:
>> `TextLineInfo` is a record, I don't want to add duplicate getXXX() aliases there.
>>
>> The other (in `LayoutInfo`) are modeled after `Text`/`TextFlow` (e.g. `underlineShape()`), I have no problem with any of these. I don't think we have strict rules regarding naming, and these are not java beans to utilize some sort of naming pattern in accessors, but I could be missing something.
>>
>> Could you be more specific?
>
> I understand the argument for `TextLineInfo`, I guess I'm looking more at `LayoutInfo` here. My question is whether it is really the best choice to sacrifice local consistency within a single class just to have it look more similar to equally inconsistently named methods in another class? Anyway, I just wanted to point this out, that's not a hill for me to die on.
Is the "thickness" of the returned `Rectangle2D` significant? Typically this is a line, meaning that width would be 0 for horizontal text. I presume that the width can be > 0 and that it would do what you expect?
-------------
PR Review Comment: https://git.openjdk.org/jfx/pull/1596#discussion_r2070422202
More information about the openjfx-dev
mailing list