What is the correct way to use JPanels in Netbeans?

耗尽温柔 提交于 2019-12-02 05:27:44
Andrew Thompson

I want to know whether it's correct or not to add 4 JPanels on a main JPanel?

Sure. Most of the Java GUIs you see that are any more than trivial put panels inside other panels.

Sometimes a different panel is used to group common controls or output components and possibly give them a titled border. More commonly different panels are used in order to use different layout managers in separate parts of the GUI. Here is a well known example that puts the details of the layout in a titled border for the panel..

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!