private void createContentPane() {

		if (contentPane != null)
			return;

		contentPane = new JPanel(new BorderLayout());

		ActionListener okListener = new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				cancel = !confirm();
				dialog.dispose();
			}
		};

		JPanel p = new JPanel(new FlowLayout(FlowLayout.RIGHT));
		contentPane.add(p, BorderLayout.SOUTH);

		String s = Modeler.getInternationalText("OKButton");
		okButton = new JButton(s != null ? s : "OK");
		okButton.addActionListener(okListener);
		p.add(okButton);

		s = Modeler.getInternationalText("CancelButton");
		JButton button = new JButton(s != null ? s : "Cancel");
		button.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				dialog.setVisible(false);
				cancel = true;
			}
		});
		p.add(button);

		p = new JPanel(new BorderLayout(10, 10));
		p.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));
		contentPane.add(p, BorderLayout.CENTER);

		JPanel p1 = new JPanel(new GridLayout(4, 1, 3, 3));
		s = Modeler.getInternationalText("SelectModelLabel");
		p1.add(new JLabel(s != null ? s : "Select a model", SwingConstants.LEFT));
		s = Modeler.getInternationalText("SelectTechnique");
		p1.add(new JLabel(s != null ? s : "Select a technique", SwingConstants.LEFT));
		s = Modeler.getInternationalText("SelectLevelOfDetails");
		p1.add(new JLabel(s != null ? s : "Select level of details", SwingConstants.LEFT));
		s = Modeler.getInternationalText("BorderLabel");
		p1.add(new JLabel(s != null ? s : "Border", SwingConstants.LEFT));
		p.add(p1, BorderLayout.WEST);

		p1 = new JPanel(new GridLayout(4, 1, 3, 3));

		modelComboBox = new JComboBox();
		modelComboBox.setPreferredSize(new Dimension(200, 18));
		modelComboBox
				.setToolTipText("If there are multiple models on the page, select the one this diffraction instrument will work with.");
		p1.add(modelComboBox);

		methodComboBox = new JComboBox(new Object[] { "X-ray", "Neutron" });
		methodComboBox.setToolTipText("Select a diffraction technique");
		p1.add(methodComboBox);

		scalingComboBox = new JComboBox(new Object[] { "Linear", "Logarithmic" });
		scalingComboBox
				.setToolTipText("<html>Select a scaling method to show different levels of details.<br>The logrithmic mode will show more details than the linear one.</html>");
		p1.add(scalingComboBox);

		borderComboBox = new JComboBox(BorderManager.BORDER_TYPE);
		borderComboBox.setRenderer(new ComboBoxRenderer.BorderCell());
		borderComboBox.setBackground(p1.getBackground());
		borderComboBox.setToolTipText("Select the border type for this instrument.");
		p1.add(borderComboBox);

		p.add(p1, BorderLayout.CENTER);

		p1 = new JPanel(new FlowLayout(FlowLayout.LEFT, 5, 5));
		p1.setBorder(BorderFactory.createEtchedBorder());
		p.add(p1, BorderLayout.SOUTH);

		s = Modeler.getInternationalText("ScanAfterLoading");
		loadScanCheckBox = new JCheckBox(s != null ? s : "Scan after loading");
		loadScanCheckBox.setSelected(false);
		loadScanCheckBox
				.setToolTipText("<html>Select if you wish an X-ray image be generated immediately after the model is loaded.</html>");
		p1.add(loadScanCheckBox);

		s = Modeler.getInternationalText("ScanAfterScriptExecution");
		scriptScanCheckBox = new JCheckBox(s != null ? s : "Scan after script execution");
		scriptScanCheckBox.setSelected(false);
		scriptScanCheckBox
				.setToolTipText("<html>Select if you wish an X-ray image be generated immediately after scripts have been executed.</html>");
		p1.add(scriptScanCheckBox);

	}