com.mxgraph.canvas
public abstract class mxBasicCanvas extends Object implements mxICanvas
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_IMAGEBASEPATH
Defines the default value for the imageBasePath in all GDI canvases.
|
protected boolean |
drawLabels
Specifies whether labels should be painted.
|
protected String |
imageBasePath
Defines the base path for images with relative paths.
|
protected double |
scale
Specifies the current scale.
|
protected Point |
translate
Specifies the current translation.
|
Constructor and Description |
---|
mxBasicCanvas() |
Modifier and Type | Method and Description |
---|---|
String |
getImageBasePath() |
String |
getImageForStyle(Map<String,Object> style)
Gets the image path from the given style.
|
double |
getScale()
Returns the scale.
|
Point |
getTranslate()
Returns the current translation.
|
boolean |
isDrawLabels() |
void |
setDrawLabels(boolean drawLabels) |
void |
setImageBasePath(String imageBasePath) |
void |
setScale(double scale)
Sets the scale for the following drawing requests.
|
void |
setTranslate(int dx,
int dy)
Sets the translation for the following drawing requests.
|
public static String DEFAULT_IMAGEBASEPATH
protected String imageBasePath
protected Point translate
protected double scale
protected boolean drawLabels
public void setTranslate(int dx, int dy)
mxICanvas
setTranslate
in interface mxICanvas
public Point getTranslate()
mxICanvas
getTranslate
in interface mxICanvas
public void setScale(double scale)
mxICanvas
public double getScale()
mxICanvas
public void setDrawLabels(boolean drawLabels)
public String getImageBasePath()
public void setImageBasePath(String imageBasePath)
public boolean isDrawLabels()
Copyright (c) 2010 Gaudenz Alder. All rights reserved.