RFR: 8372438: SimpleViewOnlyStyledModel: non-text paragraphs [v2]
Andy Goryachev
angorya at openjdk.org
Thu Dec 4 16:28:08 UTC 2025
On Tue, 2 Dec 2025 17:10:00 GMT, Andy Goryachev <angorya at openjdk.org> wrote:
>> Fixing a bug in `SimpleViewOnlyStyledModel.lastParagraph()` which breaks adding text segments after a `Region`-based paragraph.
>>
>> Test cases:
>>
>> @Test
>> public void addTextAfterRegion() {
>> SimpleViewOnlyStyledModel m = new SimpleViewOnlyStyledModel();
>> m.addParagraph(() -> new Region());
>> m.addNodeSegment(() -> new Region());
>> assertEquals(2, m.size());
>> }
>>
>> @Test
>> public void addTextAfterRegionAfterText() {
>> SimpleViewOnlyStyledModel m = new SimpleViewOnlyStyledModel();
>> m.addNodeSegment(() -> new Region());
>> m.addParagraph(() -> new Region());
>> m.addSegment("text");
>> assertEquals(3, m.size());
>> }
>
> Andy Goryachev has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains two additional commits since the last revision:
>
> - Merge branch 'master' into 8372438.non.text.paragraphs
> - fix
@Ziad-Mid could you please review this PR?
-------------
PR Comment: https://git.openjdk.org/jfx/pull/1983#issuecomment-3613081352
More information about the openjfx-dev
mailing list