Search in sources :

Example 1 with JFXColorPicker

use of com.jfoenix.controls.JFXColorPicker in project JFoenix by jfoenixadmin.

the class ColorPickerDemo method start.

@Override
public void start(Stage stage) {
    FlowPane main = new FlowPane();
    main.setVgap(20);
    main.setHgap(20);
    javafx.scene.control.ColorPicker picker = new javafx.scene.control.ColorPicker(Color.RED);
    picker.getStyleClass().add("button");
    //		picker.getStyleClass().add("split-button");		 
    main.getChildren().add(picker);
    main.getChildren().add(new JFXColorPicker());
    StackPane pane = new StackPane();
    pane.getChildren().add(main);
    StackPane.setMargin(main, new Insets(100));
    pane.setStyle("-fx-background-color:WHITE");
    final Scene scene = new Scene(pane, 800, 200);
    //		scene.getStylesheets().add(ButtonDemo.class.getResource("/resources/css/jfoenix-components.css").toExternalForm());
    stage.setTitle("JFX Button Demo");
    stage.setScene(scene);
    stage.show();
}
Also used : JFXColorPicker(com.jfoenix.controls.JFXColorPicker) Insets(javafx.geometry.Insets) JFXColorPicker(com.jfoenix.controls.JFXColorPicker) FlowPane(javafx.scene.layout.FlowPane) Scene(javafx.scene.Scene) StackPane(javafx.scene.layout.StackPane)

Aggregations

JFXColorPicker (com.jfoenix.controls.JFXColorPicker)1 Insets (javafx.geometry.Insets)1 Scene (javafx.scene.Scene)1 FlowPane (javafx.scene.layout.FlowPane)1 StackPane (javafx.scene.layout.StackPane)1