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

CSS selection color from 0.7 to 0.9 #736

Closed
wesosdqueso opened this issue Apr 24, 2018 · 2 comments
Closed

CSS selection color from 0.7 to 0.9 #736

wesosdqueso opened this issue Apr 24, 2018 · 2 comments

Comments

@wesosdqueso
Copy link

I just upgraded from 0.7 to 0.9 and noticed two things. getParagraphLenth is now getParagraphLength. And selected text is now covered by boxes instead of a plain background color. I can post my CSS file if necesary. How do i paint those boxes?

zero7

zero9

@JordanMartinez
Copy link
Contributor

I'm not sure what your CSS looks like and that might help if you post it. However, the selection is now styleable, so if you want to style it, use .selection { /* CSS */ } to do so.

See the CSS Reference Guide for full details.

@wesosdqueso
Copy link
Author

That solved it. Heres my final stylesheet. Keywords is saved in another file.

`
.styled-text-area{
-fx-font-size: 14px;
-fx-cursor: text;
-fx-font-family: 'consolas';
/-fx-highlight-text-fill: white; JDK BUG/
}

.selection{
-fx-fill: #e5e5e5;
-fx-stroke: #e5e5e5;
-fx-stroke-width: 2;
}

.styled-text-area .lineno {
-fx-font-size: 14px;
-fx-cursor: default;
-fx-background-color: white;
}

.styled-text-area .lineno .text{
-fx-highlight-fill: #eee;
-fx-font-family: 'consolas';
-fx-fill: #aaa;
}

.virtualized-scroll-pane .styled-text-area .paragraph-box {
-fx-pref-height: 22;
}

.styled-text-area .paragraph-box:first-paragraph .paragraph-text {
-fx-pref-height: 22;
}`

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