public class TransformContext extends Object
Constructor and Description |
---|
TransformContext(CanvasComponent component)
Create a transform context associated with the
given display component.
|
Modifier and Type | Method and Description |
---|---|
void |
checkCacheValid(TransformContext ancestor)
Check transform cache validity.
|
void |
concatenate(AffineTransform at)
Concatenate this transform context with the given tranform.
|
CanvasComponent |
getComponent()
Get the component that this context is associated with.
|
AffineTransform |
getInverseTransform()
Get the transform from parent coordinates into
local coordinates.
|
TransformContext |
getParent()
Get the parent transform context of this one, or null
if this context is at the root of the transform tree.
|
AffineTransform |
getScreenTransform()
Get the transform from local coordinates into screen coordinates.
|
AffineTransform |
getTransform()
Get the transform of this context.
|
AffineTransform |
getTransform(TransformContext context)
Get the transform of this context, relative to the given context.
|
int |
getVersion()
Get the version number of the transfom context.
|
void |
invalidateCache()
Notify that cached data based on the transform is now invalid.
|
boolean |
isCacheValid()
Test if the cache is valid.
|
void |
pop(Graphics2D g)
Pop this transform off the graphics stack.
|
void |
preConcatenate(AffineTransform at)
Pre-concatenate this transform context with the given tranform.
|
void |
push(Graphics2D g)
Push this transform onto the graphics stack.
|
void |
setTransform(AffineTransform at)
Set the transform that maps local coordinates into the
parent's coordinates.
|
void |
translate(double x,
double y)
Translate this context the given distance.
|
public TransformContext(CanvasComponent component)
public void checkCacheValid(TransformContext ancestor)
public void concatenate(AffineTransform at)
public CanvasComponent getComponent()
public AffineTransform getInverseTransform()
public TransformContext getParent()
public AffineTransform getScreenTransform()
public AffineTransform getTransform()
public AffineTransform getTransform(TransformContext context)
public int getVersion()
public void invalidateCache()
public boolean isCacheValid()
public void push(Graphics2D g)
public void pop(Graphics2D g)
public void preConcatenate(AffineTransform at)
public void setTransform(AffineTransform at)
public void translate(double x, double y)
Copyright © 2025 Central Laboratory of the Research Councils. All Rights Reserved.