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

StyleClassedTextArea consumes too much memory #119

Closed
hrzafer opened this issue Feb 24, 2015 · 3 comments
Closed

StyleClassedTextArea consumes too much memory #119

hrzafer opened this issue Feb 24, 2015 · 3 comments

Comments

@hrzafer
Copy link

hrzafer commented Feb 24, 2015

I read a 3 MB text file put its content to my StyleClassedTextArea object with the following code:

byte[] bytes = Files.readAllBytes(file.toPath());
String str = new String(bytes, "UTF-8");
area.setStyleClass(0, area.getLength(), UNKNOWN);
area.replaceText(0, area.getLength(), str);

My program stucks and on the tast manager memory usage starts to increase from 180 MB to something around 4GB.

Am I doing something wrong?

@TomasMikula
Copy link
Member

I am unable to reproduce this problem. What version of RichTextFX are you using? There was a performance issue fixed in version 0.6.2 that could have fixed this.

@TomasMikula
Copy link
Member

If you experience this problem in 0.6.2, please re-open this issue and include a minimal reproducible example.

@hrzafer
Copy link
Author

hrzafer commented Feb 25, 2015

I was using version 0.6. Now I updated my pom.xml and it works OK.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants