Skip to content

Unable to use print functionality with StyledText #492

@Github-Satya-BMC

Description

@Github-Satya-BMC

We are overriding org.eclipse.jface.action.Action for a PrintAction to print my custom editor text in the detailed style manner(margin, line numbering, text coloring and styling etc).
This was working perfectly with earlier versions(Version: Photon release (4.8.0)) of eclipse, however in later version(Version: 2020-09 (4.17.0)) we are getting an exception shared below:
Caused by: java.lang.IllegalArgumentException: Argument not valid
at org.eclipse.swt.SWT.error(SWT.java:4704)
at org.eclipse.swt.SWT.error(SWT.java:4638)
at org.eclipse.swt.SWT.error(SWT.java:4609)
at org.eclipse.swt.custom.StyledText.setStyleRanges(StyledText.java:10229)
at org.eclipse.swt.custom.StyledText.setStyleRanges(StyledText.java:10444)

My question here is:
Is there any changes to Version: 2020-09 (4.17.0) with regards to
setStyleRanges(StyleRange[] ranges) method ?

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