本文整理了Java中javafx.scene.Node.toFront()
方法的一些代码示例,展示了Node.toFront()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Node.toFront()
方法的具体详情如下:
包路径:javafx.scene.Node
类名称:Node
方法名:toFront
暂无
代码示例来源:origin: jfoenixadmin/JFoenix
private void updateDisclosureNode() {
Node disclosureNode = ((JFXTreeTableCell<S, T>) getSkinnable()).getDisclosureNode();
if (disclosureNode != null) {
TreeItem<S> item = getSkinnable().getTreeTableRow().getTreeItem();
final S value = item == null ? null : item.getValue();
boolean disclosureVisible = value != null
&& !item.isLeaf()
&& value instanceof RecursiveTreeObject
&& ((RecursiveTreeObject) value).getGroupedColumn() == getSkinnable().getTableColumn();
disclosureNode.setVisible(disclosureVisible);
if (!disclosureVisible) {
getChildren().remove(disclosureNode);
} else if (disclosureNode.getParent() == null) {
getChildren().add(disclosureNode);
disclosureNode.toFront();
} else {
disclosureNode.toBack();
}
if (disclosureNode.getScene() != null) {
disclosureNode.applyCss();
}
}
}
代码示例来源:origin: at.bestsolution.efxclipse.rt/org.eclipse.fx.ui.controls
@Override
public void layoutChildren() {
double caretOffset = getCharLocation(this.insertionIndex);
this.insertionMarker.setLayoutX(caretOffset);
this.insertionMarker.setLayoutY(0);
this.insertionMarker.toFront();
}
}
代码示例来源:origin: com.guigarage/animations
private void init() {
stage.getChildren().add(currentScene.getSceneNode());
stage.getChildren().add(nextScene().getSceneNode());
currentScene.getSceneNode().toFront();
configureTransitions();
}
代码示例来源:origin: nl.cloudfarming.client/calendar-api
@Override
protected void dataItemAdded(Series<DateTime, CalendarNode> series, int itemIndex, Data<DateTime, CalendarNode> item) {
Node bar = getBar(getData().indexOf(series), item, itemIndex);
getPlotChildren().add(bar);
if (series.getNode() != null) {
series.getNode().toFront();
}
}
代码示例来源:origin: eu.mihosoft.vrl.workflow/vworkflows-fx
private void connectorsToFront() {
// move connectors to front
FXFlowNodeSkin skin = nodeSkinProperty().get();
for (List<ConnectorShape> shapeList : skin.shapeLists) {
for (ConnectorShape cs : shapeList) {
cs.getNode().toFront();
}
}
List<Connection> connections = new ArrayList<>();
for (Connector connector : skin.connectors.keySet()) {
for (Connections connectionsI : skin.controller.getAllConnections().values()) {
connections.addAll(connectionsI.getAllWith(connector));
}
}
for (Connection conn : connections) {
ConnectionSkin skinI = skin.controller.getNodeSkinLookup().
getById(skin.getSkinFactory(), conn);
if (skinI instanceof FXConnectionSkin) {
FXConnectionSkin fxSkin = (FXConnectionSkin) skinI;
fxSkin.receiverToFront();
}
}
}
代码示例来源:origin: com.guigarage/animations
public void toNextScene() {
currentScene.stop();
stage.getChildren().remove(currentScene.getSceneNode());
onSceneSwitch(currentScene.getSceneNode(), nextScene().getSceneNode());
currentScene = nextScene();
stage.getChildren().add(nextScene().getSceneNode());
currentScene.getSceneNode().toFront();
configureTransitions();
}
代码示例来源:origin: com.guigarage/animations
private void configureTransitions() {
sceneOnScreenTimer = new TimerTransition(currentScene.getOnScreen());
sceneOnScreenTimer.setOnFinished(e -> {
nextScene().play();
transitionToNextScene = new DurationBasedTransition(transitionDuration) {
@Override
protected void interpolate(double frac) {
transition(frac, currentScene.getSceneNode(), nextScene().getSceneNode());
}
};
transitionToNextScene.setOnFinished(event -> toNextScene());
transitionToNextScene.play();
state = SlideshowState.PLAYING_IN_TRANSITION;
});
sceneOnScreenTimer.play();
currentScene.getSceneNode().toFront();
state = SlideshowState.PLAYING_IN_SCENE;
}
代码示例来源:origin: com.jfoenix/jfoenix
private void updateDisclosureNode() {
Node disclosureNode = ((JFXTreeTableCell<S, T>) getSkinnable()).getDisclosureNode();
if (disclosureNode != null) {
TreeItem<S> item = getSkinnable().getTreeTableRow().getTreeItem();
final S value = item == null ? null : item.getValue();
boolean disclosureVisible = value != null
&& !item.isLeaf()
&& value instanceof RecursiveTreeObject
&& ((RecursiveTreeObject) value).getGroupedColumn() == getSkinnable().getTableColumn();
disclosureNode.setVisible(disclosureVisible);
if (!disclosureVisible) {
getChildren().remove(disclosureNode);
} else if (disclosureNode.getParent() == null) {
getChildren().add(disclosureNode);
disclosureNode.toFront();
} else {
disclosureNode.toBack();
}
if (disclosureNode.getScene() != null) {
disclosureNode.applyCss();
}
}
}
代码示例来源:origin: eu.mihosoft.vrl.workflow/vworkflows-fx
public void performDragBegin(
Node n, MouseEvent event) {
final double parentScaleX = n.getParent().
localToSceneTransformProperty().getValue().getMxx();
final double parentScaleY = n.getParent().
localToSceneTransformProperty().getValue().getMyy();
// record the current mouse X and Y position on Node
mouseX = event.getSceneX();
mouseY = event.getSceneY();
if (centerNode) {
Point2D p2d = n.getParent().sceneToLocal(mouseX, mouseY);
nodeX = p2d.getX();
nodeY = p2d.getY();
} else {
nodeX = n.getLayoutX() * parentScaleX;
nodeY = n.getLayoutY() * parentScaleY;
}
n.toFront();
}
}
代码示例来源:origin: eu.mihosoft.vrl.workflow/vworkflows-fx
connectorNode.toFront();
});
代码示例来源:origin: eu.mihosoft.vrl.workflow/vworkflows-fx
n.toFront();
n.toFront();
代码示例来源:origin: eu.mihosoft.vrl.workflow/vworkflows-fx
n.toFront();
Connector receiver = selConnector.getConnector();
n.toFront();
Connector receiverConnector = selConnector.getConnector();
内容来源于网络,如有侵权,请联系作者删除!