本文整理了Java中edu.uci.ics.jung.visualization.renderers.Renderer.getEdgeRenderer
方法的一些代码示例,展示了Renderer.getEdgeRenderer
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Renderer.getEdgeRenderer
方法的具体详情如下:
包路径:edu.uci.ics.jung.visualization.renderers.Renderer
类名称:Renderer
方法名:getEdgeRenderer
暂无
代码示例来源:origin: jrtom/jung
public ViewLensSupport(
VisualizationViewer<N, E> vv,
LensTransformer lensTransformer,
ModalGraphMouse lensGraphMouse) {
super(vv, lensGraphMouse);
this.renderContext = vv.getRenderContext();
this.pickSupport = renderContext.getPickSupport();
this.savedGraphicsDecorator = renderContext.getGraphicsContext();
this.lensTransformer = lensTransformer;
LayoutModel layoutModel = vv.getModel().getLayoutModel();
Dimension d = new Dimension(layoutModel.getWidth(), layoutModel.getHeight());
lensTransformer.getLens().setSize(d);
this.lensGraphicsDecorator = new TransformingFlatnessGraphics(lensTransformer);
this.savedEdgeRenderer = vv.getRenderer().getEdgeRenderer();
}
代码示例来源:origin: net.sf.jung/jung-visualization
public ViewLensSupport(VisualizationViewer<V,E> vv,
LensTransformer lensTransformer,
ModalGraphMouse lensGraphMouse) {
super(vv, lensGraphMouse);
this.renderContext = vv.getRenderContext();
this.pickSupport = renderContext.getPickSupport();
this.savedGraphicsDecorator = renderContext.getGraphicsContext();
this.lensTransformer = lensTransformer;
Dimension d = vv.getSize();
lensTransformer.setViewRadius(d.width/5);
this.lensGraphicsDecorator = new TransformingFlatnessGraphics(lensTransformer);
this.savedEdgeRenderer = vv.getRenderer().getEdgeRenderer();
this.reshapingEdgeRenderer = new ReshapingEdgeRenderer<V,E>();
this.reshapingEdgeRenderer.setEdgeArrowRenderingSupport(savedEdgeRenderer.getEdgeArrowRenderingSupport());
}
public void activate() {
代码示例来源:origin: net.sf.jung/jung-visualization
public MagnifyImageLensSupport(VisualizationViewer<V,E> vv, LensTransformer lensTransformer,
ModalGraphMouse lensGraphMouse) {
super(vv, lensGraphMouse);
this.renderContext = vv.getRenderContext();
this.pickSupport = renderContext.getPickSupport();
this.renderer = vv.getRenderer();
this.transformingRenderer = new BasicRenderer<V,E>();
this.savedGraphicsDecorator = renderContext.getGraphicsContext();
this.lensTransformer = lensTransformer;
this.savedEdgeRenderer = vv.getRenderer().getEdgeRenderer();
this.reshapingEdgeRenderer = new ReshapingEdgeRenderer<V,E>();
this.reshapingEdgeRenderer.setEdgeArrowRenderingSupport(savedEdgeRenderer.getEdgeArrowRenderingSupport());
Dimension d = vv.getSize();
if(d.width == 0 || d.height == 0) {
d = vv.getPreferredSize();
}
lensTransformer.setViewRadius(d.width/5);
this.lensGraphicsDecorator = new MagnifyIconGraphics(lensTransformer);
}
代码示例来源:origin: net.sf.jung/jung-jai
/**
* create the base class, setting common members and creating
* a custom GraphMouse
* @param vv the VisualizationViewer to work on
*/
public HyperbolicImageLensSupport(VisualizationViewer<V,E> vv, LensTransformer lensTransformer,
ModalGraphMouse lensGraphMouse) {
super(vv, lensGraphMouse);
this.renderContext = vv.getRenderContext();
this.pickSupport = renderContext.getPickSupport();
this.renderer = vv.getRenderer();
this.transformingRenderer = new BasicRenderer<V,E>();
this.transformingRenderer.setVertexRenderer(new TransformingImageVertexIconRenderer<V,E>());
this.savedGraphicsDecorator = renderContext.getGraphicsContext();
this.lensTransformer = lensTransformer;
this.savedEdgeRenderer = vv.getRenderer().getEdgeRenderer();
this.reshapingEdgeRenderer = new ReshapingEdgeRenderer<V,E>();
this.reshapingEdgeRenderer.setEdgeArrowRenderingSupport(savedEdgeRenderer.getEdgeArrowRenderingSupport());
Dimension d = vv.getSize();
// if(d.width == 0 || d.height == 0) {
// d = vv.getPreferredSize();
// }
lensTransformer.setViewRadius(d.width/5);
this.lensGraphicsDecorator = new TransformingFlatnessGraphics(lensTransformer);
}
代码示例来源:origin: jrtom/jung
if (source.isSelected()) {
vv.getRenderer()
.getEdgeRenderer()
.setEdgeArrowRenderingSupport(new CenterEdgeArrowRenderingSupport<>());
} else {
vv.getRenderer()
.getEdgeRenderer()
.setEdgeArrowRenderingSupport(new BasicEdgeArrowRenderingSupport<>());
代码示例来源:origin: net.sf.jung/jung-samples
vv.getRenderer().getEdgeRenderer().setEdgeArrowRenderingSupport(
new CenterEdgeArrowRenderingSupport<Integer, Number>());
vv.getRenderer().getEdgeRenderer().setEdgeArrowRenderingSupport(
new BasicEdgeArrowRenderingSupport<Integer, Number>());
内容来源于网络,如有侵权,请联系作者删除!