更新时间:2023-09-20 14:03:16
A CardLayout
非常适合这种用法.有关详细信息和工作示例,请参见如何使用CardLayout .
其他组合数据的策略可以在以下链接中看到/链接:..
Other strategies for combining data can be seen in/linked from this answer to "The Use of Multiple JFrames, Good/Bad Practice?".
充实这个想法.
GridLayout
或BorderLayout
(任何不受限制地添加到其中的单个组件,将被拉伸到可用的宽度和高度).CardLayout
卡中.GridLayout
or BorderLayout
(any single component added to either with no constraint, will be stretched to the available width & height).CardLayout
in the main (and only) frame.