You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you delete the text of a simple document, save, and then get the document, the document's decoration list is empty. Then an attempt to open the document results in an exception,
Exception in thread "JavaFX Application Thread" java.lang.NullPointerException: Cannot invoke "com.gluonhq.richtextarea.model.ParagraphDecoration.hasTableDecoration()" because "prevDecoration" is null
at com.gluonhq.richtextarea.model.PieceTable.getParagraphDecorationAtCaret(PieceTable.java:359)
at com.gluonhq.richtextarea.RichTextAreaSkin.setup(RichTextAreaSkin.java:740)
at com.gluonhq.richtextarea.RichTextAreaSkin.lambda$new$24(RichTextAreaSkin.java:418)
at javafx.base@22/com.sun.javafx.binding.ExpressionHelper$SingleChange.fireValueChangedEvent(ExpressionHelper.java:192)
at javafx.base@22/com.sun.javafx.binding.ExpressionHelper.fireValueChangedEvent(ExpressionHelper.java:91)
at javafx.base@22/javafx.beans.property.ObjectPropertyBase.fireValueChangedEvent(ObjectPropertyBase.java:106)
at javafx.base@22/javafx.beans.property.ObjectPropertyBase.markInvalid(ObjectPropertyBase.java:113)
at javafx.base@22/javafx.beans.property.ObjectPropertyBase.set(ObjectPropertyBase.java:147)
at com.gluonhq.richtextarea.viewmodel.RichTextAreaViewModel.setDocument(RichTextAreaViewModel.java:286)
at com.gluonhq.richtextarea.viewmodel.RichTextAreaViewModel.lambda$open$8(RichTextAreaViewModel.java:777)
at javafx.graphics@22/com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:456)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
at javafx.graphics@22/com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:455)
at javafx.graphics@22/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
which originates from PieceTable.jave:359. I have attached a minimal file to exhibit the problem: Start the program; use the editor to delete the short text; press the buttons in order: save, get doc, open doc. The exception occurs at the last stage.
I believe this issue first arose after changes #322. This issue restates my #333, now as applied to the Rich Text Area as of 6/22/24, and ideally in a form that will be more useful to you!
If you delete the text of a simple document, save, and then get the document, the document's decoration list is empty. Then an attempt to open the document results in an exception,
which originates from PieceTable.jave:359. I have attached a minimal file to exhibit the problem: Start the program; use the editor to delete the short text; press the buttons in order: save, get doc, open doc. The exception occurs at the last stage.
I believe this issue first arose after changes #322. This issue restates my #333, now as applied to the Rich Text Area as of 6/22/24, and ideally in a form that will be more useful to you!
NullDecorationTest.zip
The text was updated successfully, but these errors were encountered: