prefuse.Visualization.run()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(5.2k)|赞(0)|评价(0)|浏览(169)

本文整理了Java中prefuse.Visualization.run()方法的一些代码示例,展示了Visualization.run()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Visualization.run()方法的具体详情如下:
包路径:prefuse.Visualization
类名称:Visualization
方法名:run

Visualization.run介绍

[英]Schedule the Action with the given name to run immediately. The running of all Actions is managed by the prefuse.activity.ActivityManager, which runs in a dedicated thread.
[中]计划立即运行具有给定名称的操作。所有操作的运行都由prefuse管理。活动ActivityManager,在专用线程中运行。

代码示例

代码示例来源:origin: org.netbeans.modules/org-netbeans-modules-xml-nbprefuse

protected void runActivity(Visualization vis) {
  if ( activity != null ) {
    vis.run(activity);
  }
}

代码示例来源:origin: de.sciss/prefuse-core

private void runActivity(Visualization vis) {
  if ( activity != null ) {
    vis.run(activity);
  }
}

代码示例来源:origin: neueda/jetbrains-plugin-graph-database-support

public void startLayout() {
  m_vis.run(LAYOUT);
  m_vis.run(REPAINT);
}

代码示例来源:origin: org.qi4j.tool/org.qi4j.tool.envisage

@Override
public void run()
{
  m_vis.run( FILTER_ACTION );
}

代码示例来源:origin: nz.ac.waikato.cms.weka/prefuseTree

public void tupleSetChanged(TupleSet t, Tuple[] add, Tuple[] rem) {
 m_vis.cancel("animatePaint");
 m_vis.run("fullPaint");
 m_vis.run("animatePaint");
}
 });

代码示例来源:origin: es.ucm.fdi.gaia/jCOLIBRI

/**
 * Changes the expansion Distance.
 */
public void setDistance(int dist){
 filter.setDistance(dist);
 vis.run("draw");
}

代码示例来源:origin: de.sciss/prefuse-core

/**
 * Runs an optional action upon anchor update.
 * @param e MouseEvent
 */
private void runAction(MouseEvent e) {
  if ( m_action != null ) {
    Display d = (Display)e.getSource();
    d.getVisualization().run(m_action);
  }
}

代码示例来源:origin: es.ucm.fdi.gaia/jCOLIBRI

public void actionPerformed(ActionEvent e) {
  if (e.getActionCommand().equals("Stop")){
   stop.setText("Run");
   vis.cancel("layout");
  }else{
   stop.setText("Stop");
   vis.run("layout");
  }
 }
});

代码示例来源:origin: de.sciss/prefuse-core

/**
 * @see prefuse.controls.Control#itemEntered(prefuse.visual.VisualItem, java.awt.event.MouseEvent)
 */
public void itemEntered(VisualItem item, MouseEvent e) {
  item.getVisualization().run(m_action);
}

代码示例来源:origin: de.sciss/prefuse-core

/**
 * @see prefuse.controls.Control#itemExited(prefuse.visual.VisualItem, java.awt.event.MouseEvent)
 */
public void itemExited(VisualItem item, MouseEvent e) {
  item.getVisualization().run(m_action);
}

代码示例来源:origin: es.ucm.fdi.gaia/jCOLIBRI

public void tupleSetChanged(TupleSet t, Tuple[] add, Tuple[] rem) {
   vis.run("draw");
   vis.repaint();
 }
});

代码示例来源:origin: nz.ac.waikato.cms.weka/prefuseGraph

public void stateChanged(ChangeEvent e) {
    filter.setDistance(slider.getValue().intValue());
    m_vis.run(DRAW);
  }
});

代码示例来源:origin: org.qi4j.tool/org.qi4j.tool.envisage

@Override
public void run()
{
  if( isInProgress() )
  {
    return;
  }
  // perform layout
  m_vis.invalidate( GRAPH_NODES );
  activity = m_vis.run( LAYOUT_ACTION );
}

代码示例来源:origin: es.ucm.fdi.gaia/jCOLIBRI

/**
 * Changes the default Spring distance force.
 */
public void setSpringForce(float val){
 Force force = fsim.getForces()[2];
 force.setParameter (SpringForce.SPRING_LENGTH,val);
 vis.run("draw");
}

代码示例来源:origin: org.netbeans.modules/org-netbeans-modules-xml-nbprefuse

/**
 * @see prefuse.controls.Control#itemDragged(prefuse.visual.VisualItem, java.awt.event.MouseEvent)
 */
public void itemDragged(VisualItem item, MouseEvent e) {
  if (!SwingUtilities.isLeftMouseButton(e)) return;
  dragged = true;
  Display d = (Display)e.getComponent();
  d.getAbsoluteCoordinate(e.getPoint(), temp);
  double dx = temp.getX()-down.getX();
  double dy = temp.getY()-down.getY();
  
  move(item, dx, dy);
  
  down.setLocation(temp);
  item.getVisualization().run(AnalysisConstants.ACTION_UPDATE_AGGREGATE_LAYOUT_REPAINT);
}

代码示例来源:origin: nz.ac.waikato.cms.weka/prefuseTree

public void actionPerformed(ActionEvent evt) {
setOrientation(orientation);
getVisualization().cancel("orient");
getVisualization().run("treeLayout");
getVisualization().run("orient");
 }
}

代码示例来源:origin: org.netbeans.modules/org-netbeans-modules-xml-nbprefuse

/**
 * @see prefuse.controls.Control#itemReleased(prefuse.visual.VisualItem, java.awt.event.MouseEvent)
 */
public void itemReleased(VisualItem item, MouseEvent e) {
  if (!SwingUtilities.isLeftMouseButton(e)) return;
  if ( dragged ) {
    activeItem = null;
    setFixed(item, false);
    dragged = false;
    item.getVisualization().run(AnalysisConstants.ACTION_UPDATE_AGGREGATE_LAYOUT_REPAINT);
  }            
}

代码示例来源:origin: org.qi4j.tool/org.qi4j.tool.envisage

@Override
public void run( Graph graph )
{
  m_vis.add( GRAPH, graph );
  run();
  m_vis.run( AUTO_ZOOM_ACTION );
  // disable edges interactive
  m_vis.setInteractive( GRAPH_EDGES, null, false );
}

代码示例来源:origin: nz.ac.waikato.cms.weka/prefuseGraph

public void tupleSetChanged(TupleSet ts, Tuple[] add, Tuple[] rem)
 {
for ( int i=0; i<rem.length; ++i )
 ((VisualItem)rem[i]).setFixed(false);
for ( int i=0; i<add.length; ++i ) {
 ((VisualItem)add[i]).setFixed(false);
 ((VisualItem)add[i]).setFixed(true);
}
if ( ts.getTupleCount() == 0 ) {
 ts.addTuple(rem[0]);
 ((VisualItem)rem[0]).setFixed(false);
}
m_vis.run(DRAW);
 }
});

代码示例来源:origin: es.ucm.fdi.gaia/jCOLIBRI

public void tupleSetChanged(TupleSet ts, Tuple[] add, Tuple[] rem)
  {
    for ( int i=0; i<rem.length; ++i )
      ((VisualItem)rem[i]).setFixed(false);
    for ( int i=0; i<add.length; ++i ) {
      ((VisualItem)add[i]).setFixed(false);
      ((VisualItem)add[i]).setFixed(true);
    }
    if ( ts.getTupleCount() == 0 ) {
      ts.addTuple(rem[0]);
      ((VisualItem)rem[0]).setFixed(false);
    }
    vis.run("draw");
  }
});

相关文章