Java GUI Swing programming -


i beginner . can have multiple layouts in single jframe? want make tic-tac-toe project in java , add gui it, apart 3x3 grid, want jlabel , jbutton. how can build grid add menus , radio buttons? layout should use?

you must deal containers , layouts. in containers can add many children want , layouts associated containers provide way graphically arrange children.

containers provide logical aggregation. layouts provide graphical appearance aggregation.

you need have container (main) in there toolbar containing labels , buttons , container (secondary) grid inside. in such case, there 3 containers : 2 panels , toolbar. toolbar has own layout, have specify layouts panels. in main 1 border layout seems appropriate (on north toolbar, in center panel/grid). in secondary panel grid layout should trick buttons inside.


Comments

Popular posts from this blog

How has firefox/gecko HTML+CSS rendering changed in version 38? -

javascript - Complex json ng-repeat -

jquery - Cloning of rows and columns from the old table into the new with colSpan and rowSpan -