JavaFX style by classname

后端 未结 2 728
[愿得一人]
[愿得一人] 2021-01-24 04:52

Perhaps a little basic question, but is it possible to style elements of a table by classname in JavaFX. So for example like this:

MyClassname .table-view .colum         


        
2条回答
  •  悲哀的现实
    2021-01-24 05:21

    Specify the full path to your class from root.

    .root MyClassname .table-view .column-header .label {
        -fx-text-fill:#F00;
    }
    

提交回复
热议问题