}
}
private void initMainPanel() throws Exception {
// create an editor for the main model
DataViewer editor = getFactory().createViewer(mainModel, true);
// access the Swing JComponents
JComponent editorComponent = editor.getJComponent();
// insert generated JComponents into the application window
getMainPanel().setLayout(new BorderLayout());
getMainPanel().add(editorComponent, BorderLayout.CENTER);
SwingUtilities.invokeLater(new Repainter());