add(new JLabel(java.util.ResourceBundle.getBundle("global").getString("maxWordLen"), SwingConstants.CENTER), BorderLayout.CENTER);
add(new JLabel("word length:", SwingConstants.CENTER), BorderLayout.CENTER);
    public void run() {        int max = 0;                SpinnerNumberModel spinModel;        getContentPane().setLayout(new BorderLayout());                JPanel lowerPan = new JPanel();        lowerPan.setLayout(new GridLayout(1,3));                add(new JLabel(java.util.ResourceBundle.getBundle("global").getString("maxWordLen"), SwingConstants.CENTER), BorderLayout.CENTER);                // hier wird die Wortlnge begrenzt, bei mehr als 500k Wrter wird es kritisch mit dem Heap :/        for (int k = 0 ; k < 50 ; k++) {            ++max;            if (Math.pow((double)alphaSize, (double)max) >= 400000) {                --max;                break;            }                      }                spinModel = new SpinnerNumberModel(1,1,max,1);        spin = new JSpinner(spinModel);                        JButton start = new JButton(java.util.ResourceBundle.getBundle("global").getString("OK"));        JButton cancel = new JButton(java.util.ResourceBundle.getBundle("global").getString("cancel"));                lowerPan.add(spin);        lowerPan.add(start);        lowerPan.add(cancel);                start.addActionListener(new ActionListener() {            public void actionPerformed(ActionEvent ev) {                dispose();            }        });                cancel.addActionListener(new ActionListener() {            public void actionPerformed(ActionEvent ev) {                wLen = -1;                dispose();            }        });                spin.addChangeListener(new ChangeListener() {            public void stateChanged(ChangeEvent ev) {                wLen = (int)((Integer)spin.getValue());            }        });                getContentPane().add(lowerPan, BorderLayout.SOUTH);                setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);        setLocation(90,90);        pack();        setVisible(true);    }