Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Gui - Best way to navigate between windows?

I try to build a gui (Swing) for a simple java application. The application should have a start window like a menu. From there I would like to navigate to several other windows.

My question is what is the best-practice to achieve such a navigation? Should I build several JFrames and switch the visibility of them on/off when navigating OR should I better have one JFrame and add/remove JPanels in this single frame to navigate between the windows?

Thanks.

like image 740
flash Avatar asked Dec 17 '25 16:12

flash


1 Answers

I recommend

  • Do not do a MDI application with sub-frames like those found in the old Windows days. They suck as they make the matter confusing.
  • Do design a tabbed interface. The welcome page/menu will be displayed on a first tab that is always created on the start.

All cool kids do that nowadays:

  • Visual Studio
  • Eclipse
  • Firefox
like image 154
Johannes Schaub - litb Avatar answered Dec 20 '25 07:12

Johannes Schaub - litb



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!