Change Default Text Color
See original GitHub issuefirst this looks like a cool control, thanks for the hard work.
I’m trying to implement a personal editor based on pandoc markdown. I want to implement syntax hi-lighting for it and stumbled across your project. I ran the java keyword demo included with the source. It looked nice, however when I spend long stretches at the computer I prefer an editor with a black background, think darcula in Intellij or Norway Today in Netbeans. So I proceeded to change the background colour to black, which was easy enough to achieve, I just added the following to the css file:
.styled-text-area{
-fx-background-color:black;
}
With a little googling I found that I had to set the fill for the text as follows:
.styled-text-area .text{
-fx-fill:yellow;
}
However when I set the fill as above there is no longer any syntax hi-lighting everything is yellow. So I was wondering if this is a bug or if there is some other way to change the default text colour.
Anyway to replicate just add the above to the java-keywords.css file.
Issue Analytics
- State:
- Created 8 years ago
- Comments:8 (4 by maintainers)
Top GitHub Comments
It is actually not public API, but it so happens that the caret is a Path with zero area and stroke of width 1px and has the class
caret
, so you can customize its color like this:Is it possible to change the caret color? When changing fill on a TextArea the caret changes to the same color as the fill, however when setting the fill in the StyledTextArea the caret does not change and remains black. Is there a way to change the caret color?
-Jordan
On 08/31/2015 02:18 PM, Tomas Mikula wrote: