According to the "JavaFX CSS Reference Guide" at http://download.oracle.com/docs/cd/E17802_01/javafx/javafx/1.3/docs/api/javafx.scene/doc-files/cssref.html, oneshould also be able to use CSS to set the image source of Labeled (Button, Label, etc.), e.g.:
#mylabel {
-fx-graphic: url("javafx-logo-154x64.png");
}
This doesn't seem to work for Button or Label.
BTW, the url value seems to be right, as it works with an ImageView, e.g.:
#myimageview {
-fx-image: url("javafx-logo-154x64.png");
}
#mylabel {
-fx-graphic: url("javafx-logo-154x64.png");
}
This doesn't seem to work for Button or Label.
BTW, the url value seems to be right, as it works with an ImageView, e.g.:
#myimageview {
-fx-image: url("javafx-logo-154x64.png");
}