本文整理汇总了Java中javafx.scene.Node.opacityProperty方法的典型用法代码示例。如果您正苦于以下问题:Java Node.opacityProperty方法的具体用法?Java Node.opacityProperty怎么用?Java Node.opacityProperty使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类javafx.scene.Node
的用法示例。
在下文中一共展示了Node.opacityProperty方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: FadeOutDownTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeOutDownTransition
*
* @param node The node to affect
*/
public FadeOutDownTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateYProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateYProperty(), 20, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例2: FlipInXTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FlipInXTransition
*
* @param node The node to affect
*/
public FlipInXTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.rotateProperty(), -90, WEB_EASE),
new KeyValue(node.opacityProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(400),
new KeyValue(node.rotateProperty(), 10, WEB_EASE)
),
new KeyFrame(Duration.millis(700),
new KeyValue(node.rotateProperty(), -10, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.rotateProperty(), 0, WEB_EASE),
new KeyValue(node.opacityProperty(), 1, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例3: FlipOutXTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FlipOutXTransition
*
* @param node The node to affect
*/
public FlipOutXTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.rotateProperty(), 0, WEB_EASE),
new KeyValue(node.opacityProperty(), 1, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.rotateProperty(), -90, WEB_EASE),
new KeyValue(node.opacityProperty(), 0, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例4: FadeInUpTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeInUpTransition
*
* @param node The node to affect
*/
public FadeInUpTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateYProperty(), 20, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateYProperty(), 0, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例5: FadeOutUpTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeOutUpTransition
*
* @param node The node to affect
*/
public FadeOutUpTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateYProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateYProperty(), -20, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例6: FadeOutLeftTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeOutLeftTransition
*
* @param node The node to affect
*/
public FadeOutLeftTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateXProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateXProperty(), -20, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例7: FlipOutYTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FlipOutYTransition
*
* @param node The node to affect
*/
public FlipOutYTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.rotateProperty(), 0, WEB_EASE),
new KeyValue(node.opacityProperty(), 1, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.rotateProperty(), -90, WEB_EASE),
new KeyValue(node.opacityProperty(), 0, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例8: FadeOutRightTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeOutRightTransition
*
* @param node The node to affect
*/
public FadeOutRightTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateXProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateXProperty(), 20, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例9: FadeInRightTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeInUpTransition
*
* @param node The node to affect
*/
public FadeInRightTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateXProperty(), 20, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateXProperty(), 0, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例10: RotateInTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new RotateInTransition
*
* @param node The node to affect
*/
public RotateInTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.rotateProperty(), -200, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.rotateProperty(), 0, WEB_EASE)
)
));
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例11: FlipInYTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FlipInYTransition
*
* @param node The node to affect
*/
public FlipInYTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.rotateProperty(), -90, WEB_EASE),
new KeyValue(node.opacityProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(400),
new KeyValue(node.rotateProperty(), 10, WEB_EASE)
),
new KeyFrame(Duration.millis(700),
new KeyValue(node.rotateProperty(), -10, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.rotateProperty(), 0, WEB_EASE),
new KeyValue(node.opacityProperty(), 1, WEB_EASE)
)
)
);
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例12: createBlinker
import javafx.scene.Node; //导入方法依赖的package包/类
private Timeline createBlinker(Node node) {
Timeline blink = new Timeline(
new KeyFrame(
Duration.seconds(0),
new KeyValue(
node.opacityProperty(),
1,
Interpolator.DISCRETE
)
),
new KeyFrame(
Duration.seconds(0.35),
new KeyValue(
node.opacityProperty(),
0,
Interpolator.DISCRETE
)
),
new KeyFrame(
Duration.seconds(0.7),
new KeyValue(
node.opacityProperty(),
1,
Interpolator.DISCRETE
)
)
);
blink.setCycleCount(Animation.INDEFINITE);
return blink;
}
示例13: RotateOutTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new RotateOutTransition
*
* @param node The node to affect
*/
public RotateOutTransition(final Node node) {
super(node,new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.rotateProperty(), 0, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.rotateProperty(), 200, WEB_EASE)
)));
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例14: BounceOutTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new BounceOutTransition
*
* @param node The node to affect
*/
public BounceOutTransition(final Node node) {
super(
node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.scaleXProperty(), 1, WEB_EASE),
new KeyValue(node.scaleYProperty(), 1, WEB_EASE)
),
new KeyFrame(Duration.millis(250),
new KeyValue(node.scaleXProperty(), 0.95, WEB_EASE),
new KeyValue(node.scaleYProperty(), 0.95, WEB_EASE)
),
new KeyFrame(Duration.millis(500),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.scaleXProperty(), 1.1, WEB_EASE),
new KeyValue(node.scaleYProperty(), 1.1, WEB_EASE)
),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.scaleXProperty(), 0.3, WEB_EASE),
new KeyValue(node.scaleYProperty(), 0.3, WEB_EASE)
)
));
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}
示例15: FadeInLeftTransition
import javafx.scene.Node; //导入方法依赖的package包/类
/**
* Create new FadeInLeftTransition
*
* @param node The node to affect
*/
public FadeInLeftTransition(final Node node) {
super(node,
new Timeline(
new KeyFrame(Duration.millis(0),
new KeyValue(node.opacityProperty(), 0, WEB_EASE),
new KeyValue(node.translateXProperty(), -20, WEB_EASE)),
new KeyFrame(Duration.millis(1000),
new KeyValue(node.opacityProperty(), 1, WEB_EASE),
new KeyValue(node.translateXProperty(), 0, WEB_EASE))));
setCycleDuration(Duration.seconds(1));
setDelay(Duration.seconds(0.2));
}