我可以JOptionPane.showConfirmDialog
用来展示JInternalFrame
吗?
我尝试了以下代码:
OPD.Registration opdRegister = new OPD.Registration();
//OPD.Registration is extending JInternalFrame
int ns=JOptionPane.showConfirmDialog(null, opdRegister, "Billing", JOptionPane.OK_CANCEL_OPTION,JOptionPane.PLAIN_MESSAGE);
// i am trying to call opdregister in this Confirm Dialog Box.
通过使用上面的代码可以显示对话框,JInternalFrame
但显示不正确。它仅显示标题栏。其他数据是从中删除的JInternalFrame
。
如何增加此对话框的大小?
是的,尽管JInternalFrame
旨在用于中JDesktopPane
。如果你只看到标题栏,确认您的内容具有最佳尺寸和pack()
内部框架,如图所示这里。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句