use of edu.uci.ics.jung.visualization.VisualizationModel in project tdq-studio-se by Talend.
the class JungGraphGenerator method generate.
public Composite generate(Composite parent, boolean isWithHelp) {
Composite frameComp = createAWTSWTComposite(parent);
frame = SWT_AWT.new_Frame(frameComp);
// $NON-NLS-1$
frame.setTitle(DefaultMessagesImpl.getString("JungGraphGenerator.NominalAnalysis"));
pr = new LineRender(graphbuilder);
sr = new LineRender(graphbuilder);
PersistentLayout layout = new PersistentLayoutImpl(new ISOMLayout(graph));
VisualizationModel vm = new DefaultVisualizationModel(layout);
vv = new VisualizationViewer(vm, pr);
sv = new SatelliteVisualizationViewer(vv, vm, sr, new Dimension(200, 200));
configureVViewer(vv);
// create contollers
JPanel controllers = createToolControllers(vv);
// MOD yyi 2009-09-09 feature 8834
if (this.isPreview)
controllers.setVisible(false);
JPanel panel = new GraphZoomScrollPane(vv);
if (isWithHelp) {
helpDialog = createSatelliteDialog(vv, sv);
controllers.add(createShowSatelliteCheck(helpDialog));
}
frame.add(panel);
frame.add(controllers, BorderLayout.SOUTH);
frame.validate();
addListeners();
return frameComp;
}
Aggregations