public class BasicVertexRenderer<V,E> extends Object implements Renderer.Vertex<V,E>
Renderer.Vertex.NOOP
Constructor and Description |
---|
BasicVertexRenderer() |
Modifier and Type | Method and Description |
---|---|
protected void |
paintIconForVertex(RenderContext<V,E> rc,
V v,
Layout<V,E> layout)
Paint
v 's icon on g at (x,y) . |
protected void |
paintShapeForVertex(RenderContext<V,E> rc,
V v,
Shape shape) |
void |
paintVertex(RenderContext<V,E> rc,
Layout<V,E> layout,
V v) |
protected Shape |
prepareFinalVertexShape(RenderContext<V,E> rc,
V v,
Layout<V,E> layout,
int[] coords)
Returns the vertex shape in view coordinates.
|
protected boolean |
vertexHit(RenderContext<V,E> rc,
Shape s) |
public void paintVertex(RenderContext<V,E> rc, Layout<V,E> layout, V v)
paintVertex
in interface Renderer.Vertex<V,E>
protected Shape prepareFinalVertexShape(RenderContext<V,E> rc, V v, Layout<V,E> layout, int[] coords)
rc
- the render context used for rendering the vertexv
- the vertex whose shape is to be returnedlayout
- the layout algorithm that provides coordinates for the vertexcoords
- the x and y view coordinatesprotected void paintIconForVertex(RenderContext<V,E> rc, V v, Layout<V,E> layout)
v
's icon on g
at (x,y)
.rc
- the render context used for rendering the vertexv
- the vertex to be paintedlayout
- the layout algorithm that provides coordinates for the vertexprotected boolean vertexHit(RenderContext<V,E> rc, Shape s)
protected void paintShapeForVertex(RenderContext<V,E> rc, V v, Shape shape)
Copyright © 2015. All rights reserved.