My GUI interface is displaying the JTextFields
beside the JLabels
. I want them to go under.
Username [Jtextfield]
I want the JTextField
to go under the username
, which is the same as on the east side of the panel.
您可以使用BoxLayout的用于panelWest
,它允许你放在彼此的顶部组件:
panelWest.setLayout(new BoxLayout(panelWest, BoxLayout.PAGE_AXIS));
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.