Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do i get JavaFX 8 Date Picker CSS Properties

I want to style default javaFX date picker to our custom theme, but i cant see any Documentation/Guide to change CSS proprties.

any help would be appricated

Default javaFX Calender style

enter image description here

I want to customize its color to match below guideline

enter image description here

like image 801
Anjum.... Avatar asked Sep 16 '25 14:09

Anjum....


1 Answers

The best documentation, in this case, can be default CSS file called modena.css. This style sheet is applied for every JavaFX components.

You can find this file in the JavaFX jar file jfxrt.jar (should be located /jdk1.8.x/jre/lib/ext/jfxrt.jar). After unzipping that jar file you should find the modena.css under com/sun/javafx/scene/control/skin/modena/

Find in the file a commented section DatePicker (in my file it's line# 2999) and you get all style properties that you are looking for.

Hope it helps.

like image 127
iliak Avatar answered Sep 18 '25 05:09

iliak