By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,782 Members | 1,154 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,782 IT Pros & Developers. It's quick & easy.

SpringLayout problem

P: n/a
Hello, all !!!

Could somebody explain, why my JDialog with SpringLayout doesn't work:

public class OptionsDialog extends JDialog
JLabel label;

public OptionsDialog()
Container pane = getContentPane();

SpringLayout layout = new SpringLayout();

label = new JLabel("Select plugins directory: ");


layout.putConstraint(SpringLayout.WEST, label, 20, SpringLayout.WEST,
layout.putConstraint(SpringLayout.NORTH, label, 20,
SpringLayout.NORTH, pane);


public static void main(String args[])
OptionsDialog dlg = new OptionsDialog();

Dialog has only title and no even space for label.

Jul 17 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.