Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Empty CodeArea #660

Closed
senges opened this issue Dec 15, 2017 · 5 comments
Closed

Empty CodeArea #660

senges opened this issue Dec 15, 2017 · 5 comments

Comments

@senges
Copy link

senges commented Dec 15, 2017

Hi !
As soon as my CodeArea gets empty, the application throws :

Exception in thread "JavaFX Application Thread" java.lang.IllegalStateException: Cannot get the type of a change that neither inserts nor deletes anything.

Any alternaive to that has been released ?
text.richChanges() .filter(ch -> !ch.getInserted().equals(ch.getRemoved())) // XXX .subscribe(change -> { text.setStyleSpans(0, computeHighlighting(text.getText())); });

I just need Syntaxe Higlighting.

@JordanMartinez
Copy link
Contributor

Upgrade to 0.8.1

@senges
Copy link
Author

senges commented Dec 15, 2017

Indeed, works like a charm.
Thanks !

@senges senges closed this as completed Dec 15, 2017
@senges senges reopened this Dec 15, 2017
@senges
Copy link
Author

senges commented Dec 15, 2017

EDIT : No more Exception Thrown but it still removes all my EventHandler

@JordanMartinez
Copy link
Contributor

If you're referring to event handlers, I'm guessing you are trying to override the behavior, correct? If so, see the OverrideBehaviorDemo for how to do that properly.

@senges
Copy link
Author

senges commented Dec 15, 2017

Ok I see.
Thanks for your work !

@senges senges closed this as completed Dec 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants