Layout Manager Question
I'm having a little difficulty in grasping layout managers as they apply to containers. I understand what layout managers do and are for but I've been hashing over one particular instance involving a JFrame and a tabbed pane inside the JFrame.
What I've got is a JFrame with FlowLayout() assigned. Inside the JFrame, I've placed a tabbed pane with six tabs. Within each tab I would like to assign a grid layout for some JRadio buttons I've designed. My question is this:
Can I assign one layout manager to the JFrame while assigning a different one to the individual panes of the tabbed pane? By the way, is an individual tab of a tabbed pane considered a container? If the answers to my questions are yes, would someone please provide me with an example of something similar to what I've described?
Thank you for your advice.
Adding panels within panels are limitless, you don't necessarily have to use difficult layout managers, if you keeping adding panels within panels, you can usualy get what you want. For example the following:
public class YourCrap extends JFrame
JTextField someTextField = new JTextField(10);
JTextArea someTextArea = new JTextArea(5,4);
JButton button1 = new JButton("Button1");
JButton button2 = new JButton("Button2");
JButton button3 = new JButton("Button3");
YourCrap() // default constructor
JPanel yourPanel = new JPanel();
JPanel yourDadPanel = new JPanel();
JPanel yourMomPanel = new JPanel();
public static void main(String args)
YourCrap yc = new YourCrap();
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL