Gephi Toolkit Javadoc

org.gephi.preview
Class SVGRenderTargetBuilder.SVGRenderTargetImpl

java.lang.Object
  extended by org.gephi.preview.AbstractRenderTarget
      extended by org.gephi.preview.SVGRenderTargetBuilder.SVGRenderTargetImpl
All Implemented Interfaces:
RenderTarget, SVGTarget, LongTask
Enclosing class:
SVGRenderTargetBuilder

public static class SVGRenderTargetBuilder.SVGRenderTargetImpl
extends AbstractRenderTarget
implements SVGTarget


Field Summary
 
Fields inherited from class org.gephi.preview.AbstractRenderTarget
cancel, progressTicket
 
Fields inherited from interface org.gephi.preview.api.SVGTarget
SCALE_STROKES, TOP_ARROWS, TOP_EDGE_LABELS, TOP_EDGE_LABELS_OUTLINE, TOP_EDGES, TOP_NODE_LABELS, TOP_NODE_LABELS_OUTLINE, TOP_NODES
 
Fields inherited from interface org.gephi.preview.api.RenderTarget
PDF_TARGET, PROCESSING_TARGET, SVG_TARGET
 
Constructor Summary
SVGRenderTargetBuilder.SVGRenderTargetImpl(int width, int height, int topLeftX, int topLeftY, boolean scaleStrokes)
           
 
Method Summary
 org.w3c.dom.Element createElement(java.lang.String qualifiedName)
          Create a new element qualifiedName in the document.
 org.w3c.dom.Text createTextNode(java.lang.String data)
          Create a new text node with data in it.
 org.w3c.dom.Document getDocument()
          Returns the SVG document
 float getScaleRatio()
          When SCALE_STROKES property is true returns the scale ratio to scale strokes with.
 org.w3c.dom.Element getTopElement(java.lang.String name)
          Returns the top element name in the document.
 java.lang.String toHexString(java.awt.Color color)
          Returns color in the hex format (e.g.
 
Methods inherited from class org.gephi.preview.AbstractRenderTarget
cancel, getProgressTicket, isCancelled, setProgressTicket
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SVGRenderTargetBuilder.SVGRenderTargetImpl

public SVGRenderTargetBuilder.SVGRenderTargetImpl(int width,
                                                  int height,
                                                  int topLeftX,
                                                  int topLeftY,
                                                  boolean scaleStrokes)
Method Detail

getTopElement

public org.w3c.dom.Element getTopElement(java.lang.String name)
Description copied from interface: SVGTarget
Returns the top element name in the document. Top elements are direct children of the root node and help to organize the SVG document (e.g. all edges in the same parent DOM node). Create the top element if it missing.

Specified by:
getTopElement in interface SVGTarget
Parameters:
name - the top element name to lookup
Returns:
the top element

getDocument

public org.w3c.dom.Document getDocument()
Description copied from interface: SVGTarget
Returns the SVG document

Specified by:
getDocument in interface SVGTarget
Returns:
the SVG document

getScaleRatio

public float getScaleRatio()
Description copied from interface: SVGTarget
When SCALE_STROKES property is true returns the scale ratio to scale strokes with.

Specified by:
getScaleRatio in interface SVGTarget
Returns:
the current scale ratio

createElement

public org.w3c.dom.Element createElement(java.lang.String qualifiedName)
Description copied from interface: SVGTarget
Create a new element qualifiedName in the document.

Specified by:
createElement in interface SVGTarget
Parameters:
qualifiedName - the name of the element
Returns:
the newly created element

createTextNode

public org.w3c.dom.Text createTextNode(java.lang.String data)
Description copied from interface: SVGTarget
Create a new text node with data in it.

Specified by:
createTextNode in interface SVGTarget
Parameters:
data - the text data
Returns:
the newly created text node

toHexString

public java.lang.String toHexString(java.awt.Color color)
Description copied from interface: SVGTarget
Returns color in the hex format (e.g. #ff0000).

Specified by:
toHexString in interface SVGTarget
Parameters:
color - the color to convert
Returns:
the color in a hex format

Gephi Toolkit Javadoc