本文整理了Java中javafx.scene.control.Label.setOnMouseClicked()
方法的一些代码示例,展示了Label.setOnMouseClicked()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Label.setOnMouseClicked()
方法的具体详情如下:
包路径:javafx.scene.control.Label
类名称:Label
方法名:setOnMouseClicked
暂无
代码示例来源:origin: jfoenixadmin/JFoenix
selectedHourLabel.setTextFill(Color.WHITE);
selectedHourLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 42));
selectedHourLabel.setOnMouseClicked((click) -> unit.set(TimeUnit.HOURS));
selectedHourLabel.setMinWidth(49);
selectedHourLabel.setAlignment(Pos.CENTER_RIGHT);
selectedMinLabel.setTextFill(fadedColor);
selectedMinLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 42));
selectedMinLabel.setOnMouseClicked((click) -> unit.set(TimeUnit.MINUTES));
periodPMLabel.setTextFill(fadedColor);
periodPMLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 14));
periodPMLabel.setOnMouseClicked((click) -> period.set("PM"));
periodAMLabel.setTextFill(fadedColor);
periodAMLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 14));
periodAMLabel.setOnMouseClicked((click) -> period.set("AM"));
代码示例来源:origin: nl.cloudfarming.client/calendar-api
listViewHeaderPane.getChildren().add(labelHide);
labelHide.setOnMouseClicked(new EventHandler<MouseEvent>() {
@Override
public void handle(MouseEvent mouseEvent) {
labelShow.setOnMouseClicked(new EventHandler<MouseEvent>() {
代码示例来源:origin: com.jfoenix/jfoenix
selectedHourLabel.setTextFill(Color.WHITE);
selectedHourLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 42));
selectedHourLabel.setOnMouseClicked((click) -> unit.set(TimeUnit.HOURS));
selectedHourLabel.setMinWidth(49);
selectedHourLabel.setAlignment(Pos.CENTER_RIGHT);
selectedMinLabel.setTextFill(fadedColor);
selectedMinLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 42));
selectedMinLabel.setOnMouseClicked((click) -> unit.set(TimeUnit.MINUTES));
periodPMLabel.setTextFill(fadedColor);
periodPMLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 14));
periodPMLabel.setOnMouseClicked((click) -> period.set("PM"));
periodAMLabel.setTextFill(fadedColor);
periodAMLabel.setFont(Font.font(ROBOTO, FontWeight.BOLD, 14));
periodAMLabel.setOnMouseClicked((click) -> period.set("AM"));
代码示例来源:origin: ch.sahits.game/OpenPatricianJavaFX
control.getNextButtonNode().hoverProperty().addListener(changeListenerNext);
} else {
nextLbl.setOnMouseClicked(nextButtonEventHandler);
backLbl.setOnMouseClicked(backButtonEventHandler);
backLbl.hoverProperty().addListener(changeListenerBack);
nextLbl.hoverProperty().addListener(changeListenerNext);
内容来源于网络,如有侵权,请联系作者删除!