JavaFX Text in TextFlow ignores StyleClass? -
i try use javafx textflow
view styled text. following code not text styling.
public node createtext(string t,string cls){ text ret = new text(t); ret.getstyleclass().add(cls); return ret; }
when replace text
label
works properly, things \n
not work anymore. how can use text
class css classes?
edit: requested short example of default.css
.defaultelementattr{ -fx-text-fill:#48a711; }
-fx-text-fill
css property of label
not css property of text
.
if want change color of text
object css, use -fx-fill
property:
.defaultelementattr { -fx-fill:#48a711; }
Comments
Post a Comment