【发布时间】:2018-11-26 23:49:22
【问题描述】:
所以我有这行代码显示一个对话框:
public void showInfoDialog(String header,String message) {
JFXDialogLayout content = new JFXDialogLayout();
content.setHeading(new Text(header));
content.setBody(new Text(message));
JFXDialog dialog = new JFXDialog(mySP,content, JFXDialog.DialogTransition.CENTER);
dialog.setMinHeight(mySP.getPrefHeight());
dialog.setMinWidth(mySP.getPrefWidth());
JFXButton button = new JFXButton("OK");
button.setOnAction((ActionEvent event) -> {
dialog.close();
});
content.setActions(button);
dialog.show();
}
如何调整对话框的高度和宽度,使我看不到堆栈窗格的灰色背景
【问题讨论】: