D
Daniel Pitts
Say I have the following code:
JPanel myPanel = new JPanel(new GridBagLayout());
GridBagConstraints constaints = getConstraints();
myPanel.add(new JLabel("Hello world"), constaints);
And then later (as a result of an Event), I do something like
constraints.gridx = 3;
myPanel.revalidate();
Will this have the expected effect, or do I need to remove the old
label, and re-add it with the new constraints?
JPanel myPanel = new JPanel(new GridBagLayout());
GridBagConstraints constaints = getConstraints();
myPanel.add(new JLabel("Hello world"), constaints);
And then later (as a result of an Event), I do something like
constraints.gridx = 3;
myPanel.revalidate();
Will this have the expected effect, or do I need to remove the old
label, and re-add it with the new constraints?