Skip to content

Error: When I set style to the second line, I get IndexOutOfBoundsException #741

@saifalmutory

Description

@saifalmutory

seText is InlineCssTextArea
Here I try to set the style by selecting the first line :
seText.setStyle(seText.getCurrentParagraph(),seText.getSelection().getStart(),seText.getSelection().getEnd(),ControlColorPane.getSelectedColor());
System.out.println(seText.getSelection());
I get good results
capture

Output : 0, 5
But when I select the second line ans try changing the color
capture2
Get Caused by: java.lang.IndexOutOfBoundsException: [6, 11) is not a valid range within [0, 5)
Output : 6, 11
and the style does not change either

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions