public abstract class IltBaseRenderer extends Object
A base renderer has many accessors to get and set the appropriate resources
it needs to draw. For example getForeground
is one of these.
Here is an array describing different properties usages, depending on the
base style.
These base styles are used with OSI and Bellcore object states.
CT | NT | OOS | NI | |
foreground | foreground color | foreground color | foreground color | foreground color |
background | null | null | null | background color |
borderColor | bright color | foreground color | background color | background color |
borderColor2 | dark color | null | foreground color | foreground color |
reliefBorders | true | false | false | false |
pattern | null | null | null | Thin Hatching |
borderPattern | null | null | Thin Hatching | Thin Hatching |
lineStyle | solid | solid | solid | alternating (1,7) |
borderLineStyle | solid | solid | alternating (5,3) | alternating (5,3) |
detailLevel | maximum details | few details | no detail | no detail |
To choose how to draw depending on these properties, JTGO uses the following policies.
For borders,
reliefBorders
is true, borderColor
and borderColor2
are used to draw the border in relief (see the NT model above).borderPattern
is not null, borderColor
and borderColor2
are used to draw the
border with this pattern (only for rectangle borders).borderLineStyle
is not null, borderColor
and borderColor2
are used to draw the
border with this line style.borderColor
.
For bases,
pattern
is not null, foreground
and background
are used to draw the
base with this pattern (only for rectangle bases).lineStyle
is not null, foreground
and background
are used to draw the
base with this pattern (only for linear bases).foreground
.
Modifier | Constructor and Description |
---|---|
protected |
IltBaseRenderer()
Default constructor
|
protected |
IltBaseRenderer(ilog.tgo.graphic.renderer.internal.IltBaseRendererState state)
Creates a new base renderer with the given state information
For compatibility purposes, internal use only !
|
Modifier and Type | Method and Description |
---|---|
boolean |
__isDottedBorderVisible()
Deprecated.
|
void |
attach(IlvGraphic g)
This method is invoked to indicate to the base renderer which
IlvGraphic
it is used by. |
IlvRect |
boundingBox(IlvTransformer t,
IlvRect rect,
boolean withSelection)
Returns the bounding box of the area that
draw(g,t,rect) draws into. |
protected IlvRect |
boundingBoxWithTransformer(IlvTransformer t,
IlvRect rect,
boolean withSelection)
Computes the bounding box considering also the transformer applied to the graphic.
|
boolean |
contains(IlvPoint p,
IlvPoint tp,
IlvTransformer t,
IlvRect rect)
Tests whether a point lies within the outline of the object.
|
protected boolean |
containsExtraBorders(IlvPoint p,
IlvPoint tp,
IlvTransformer t,
IlvRect rect)
Tests whether a point lies within the borders of this object.
|
protected boolean |
containsMain(IlvPoint p,
IlvPoint tp,
IlvTransformer t,
IlvRect rect)
Tests whether a point lies within the main part of the base of this object.
|
protected ilog.tgo.graphic.renderer.internal.IltBaseRendererState |
createBaseRendererState()
Creates the instance that stores all the base renderer
configuration.
|
void |
draw(Graphics g,
IlvTransformer t,
IlvRect rect)
Draws the entire base, such that it fits into a given rectangle.
|
protected boolean |
drawAlarmBorder(Graphics g,
IlvTransformer t,
IlvRect rect,
int distance)
Draw the alarm border.
|
protected void |
drawExtraBorder(Graphics g,
IlvTransformer t,
IlvRect rect,
Color color,
int distance,
int width)
Draws an extra border inside or outside the base depending
on the value returned by
isExtraBorderOutside() . |
protected void |
drawExtraBorder(Graphics g,
IlvTransformer t,
IlvRect rect,
IltPalette palette,
int distance,
int width)
Draws an extra border inside or outside the base depending
on the value returned by
isExtraBorderOutside() . |
protected void |
drawExtraBorders(Graphics g,
IlvTransformer t,
IlvRect rect)
Draws the extra borders around the main part.
|
protected abstract void |
drawMain(Graphics g,
IlvTransformer t,
IlvRect rect)
Draws the main part of the base.
|
protected boolean |
drawSelectionBorder(Graphics g,
IlvTransformer t,
IlvRect rect,
int distance)
Draw the selection border.
|
void |
dropResources()
Drop resources.
|
Color |
getAlarmBorderColor()
Returns the color of the alarm border, or
null if no alarm
border is to be drawn. |
int |
getAlarmBorderWidth()
Returns the width of the alarm border.
|
int |
getAlarmColorLevel()
Returns the brightness level that should be mapped to the normal alarm color.
|
Color |
getBackground()
Returns the background color of the base.
|
IltBaseRenderer |
getBaseRenderer()
Returns the base renderer which is really responsible for
storing the properties and drawing the object base.
|
ilog.tgo.graphic.renderer.internal.IltBaseRendererState |
getBaseRendererState()
Returns the current base renderer state.
|
Color |
getBorderColor()
Returns the primary color of the base border.
|
Color |
getBorderColor2()
Returns the secondary color of the base border.
|
IltLineStyle |
getBorderLineStyle()
Returns the line style of the base border.
|
IltPalette |
getBorderPalette()
Returns the palette of the base border.
|
IltPattern |
getBorderPattern()
Returns the pattern of the base border.
|
float |
getBorderWidth()
Returns the width of the base border.
|
Ilt2DPalette |
getBrightPalette()
Returns the palette for the brighter parts of the border.
|
Ilt2DPalette |
getDarkPalette()
Returns the palette for the darker parts of the border.
|
int |
getDeprecatedBlinkingMode()
Deprecated.
|
IltDetailLevel |
getDetailLevel()
Returns the detail level.
|
Color |
getDottedBorderBackground()
Returns the background color of the dotted border, or
null if no dotted border is to be drawn. |
Color |
getDottedBorderForeground()
Returns the foreground color of the dotted border, or
null if no dotted border is to be drawn. |
IltLineStyle |
getDottedBorderLineStyle()
Returns the line style of the dotted border, or
null if no
dotted border is to be drawn. |
protected IltPalette |
getDottedBorderPalette()
Returns the palette for the dotted border.
|
protected IltPolygon[] |
getExtraBorders(IlvRect rect)
Returns the borders of the drawn part of the base.
|
float |
getFillAngle()
Returns the angle (in degrees) of the gradient, in case the
filling style is either linear or radial gradients.
|
float |
getFillEnd()
Returns the position where the gradient ends, in case the
filling style is either linear or radial gradients.
|
float |
getFillStart()
Returns the position where the gradient starts, in case the
filling style is either linear or radial gradients.
|
int |
getFillStyle()
Returns the fill style for the base.
|
Image |
getFillTexture()
Returns the texture used to fill the face of the object.
|
Color |
getForeground()
Returns the foreground color of the base.
|
Ilt2DPalette |
getPalette()
Returns the palette of the face part.
|
IltPattern |
getPattern()
Returns the pattern of the base.
|
IlpRepresentationObject |
getRepresentationObject()
Returns the representation object using this renderer.
|
Color |
getSelectionBorderBackground()
Returns the background color of the selection border, or
null if no
selection border is to be drawn. |
Color |
getSelectionBorderForeground()
Returns the foreground color of the selection border, or
null if no
selection border is to be drawn. |
IltLineStyle |
getSelectionBorderLineStyle()
Returns the line style of the selection border, or
null if no
selection border is to be drawn. |
int |
getSelectionBorderWidth()
Returns the width of the selection border.
|
Image |
getSourceImage()
Returns the image representing the object.
|
IlpGraphicView |
getView()
Returns the graphic view where this renderer is being
used.
|
protected void |
initBaseRenderer()
Initializes the properties of this base renderer.
|
void |
initResources()
Initializes resources using the property values defined in
this base renderer.
|
protected boolean |
isAlarmBorderVisible()
Returns the visibility status of the alarm border.
|
boolean |
isAlarmColorVisible()
Returns if alarm color must be visible.
|
protected boolean |
isBaseSelectionBorderVisible()
Returns the visibility status of the selection border for the base.
|
protected boolean |
isDottedBorderVisible()
Returns the visibility status of the dotted border.
|
protected abstract boolean |
isExtraBorderOutside()
Indicates whether the extra borders should be drawn inside or outside
the
rect used to call drawExtraBorders . |
protected boolean |
isPolygonalBorder()
Returns the boolean denoting if the borders are represented by a polygon
around the base.
|
protected boolean |
isReliefBorders()
Returns the boolean denoting the presence or not of relief borders on the base.
|
boolean |
isUsingBlinkingResources()
Computed in initBlinking
|
void |
setAlarmBorderColor(Color c)
Sets the color of the alarm border, or
null if no alarm
border is to be drawn. |
void |
setAlarmBorderVisible(boolean v)
Sets the visibility status of the alarm border.
|
void |
setAlarmBorderWidth(int width)
Sets the width of the alarm border.
|
void |
setAlarmColorLevel(int level)
Sets the brightness level that should be mapped to the normal alarm color.
|
void |
setAlarmColorVisible(boolean visible)
Sets if alarm color must be visible.
|
void |
setBackground(Color bg)
Sets the background color used to display the face part.
|
void |
setBaseRendererState(ilog.tgo.graphic.renderer.internal.IltBaseRendererState s)
Sets a new base renderer state, which may or may not have
already been initialized.
|
void |
setBaseSelectionBorderVisible(boolean v)
Sets the visibility status of the selection border for the base.
|
void |
setBorderColor(Color c)
Sets the primary color of the base border.
|
void |
setBorderColor2(Color c)
Sets the secondary color of the base border.
|
void |
setBorderLineStyle(IltLineStyle l)
Sets the line style of the base border.
|
void |
setBorderPattern(IltPattern p)
Sets the pattern of the base border.
|
void |
setBorderWidth(float w)
Sets the width of the base border.
|
void |
setDeprecatedBlinkingMode(int v)
Deprecated.
|
void |
setDetailLevel(IltDetailLevel level)
Sets the detail level.
|
void |
setDottedBorderBackground(Color c)
Sets the background color of the dotted border, or
null if no dotted border is to be drawn. |
void |
setDottedBorderForeground(Color c)
Sets the foreground color of the dotted border, or
null if no dotted border is to be drawn. |
void |
setDottedBorderLineStyle(IltLineStyle l)
Sets the line style of the dotted border, or
null if no
dotted border is to be drawn. |
void |
setDottedBorderVisible(boolean v)
Sets the visibility status of the dotted border.
|
void |
setFillAngle(float v)
Sets the angle (in degrees) of the gradient, in case the
filling style is either linear or radial gradients.
|
void |
setFillEnd(float v)
Sets the position where the gradient ends, in case the
filling style is either linear or radial gradients.
|
void |
setFillStart(float v)
Sets the position where the gradient starts, in case the
filling style is either linear or radial gradients.
|
void |
setFillStyle(int i)
Sets the fill style for the base.
|
void |
setFillTexture(Image v)
Sets the texture used to fill the face of the object.
|
void |
setForeground(Color fg)
Sets the foreground color used to display the face part.
|
void |
setPattern(IltPattern p)
Sets the pattern of the base.
|
void |
setPolygonalBorder(boolean b)
Sets the boolean denoting if the borders are represented by a polygon
around the base.
|
void |
setReliefBorders(boolean b)
Sets the boolean denoting the presence or not of relief borders on the base.
|
void |
setRepresentationObject(IlpRepresentationObject ro)
Sets the representation object where this renderer is being used.
|
void |
setSelectionBorderBackground(Color v)
Sets the background color of the selection border, or
null if no
selection border is to be drawn. |
void |
setSelectionBorderForeground(Color c)
Sets the foreground color of the selection border, or
null if no
selection border is to be drawn. |
void |
setSelectionBorderLineStyle(IltLineStyle l)
Sets the line style of the selection border, or
null if no
selection border is to be drawn. |
void |
setSelectionBorderWidth(int v)
Sets the width of the selection border.
|
void |
setSourceImage(Image sourceImage)
Sets the image representing the object.
|
void |
setView(IlpGraphicView v)
Returns the graphic view where this renderer is being
used.
|
protected IltBaseRenderer()
protected IltBaseRenderer(ilog.tgo.graphic.renderer.internal.IltBaseRendererState state)
For compatibility purposes, internal use only !
protected ilog.tgo.graphic.renderer.internal.IltBaseRendererState createBaseRendererState()
protected void initBaseRenderer()
public IltBaseRenderer getBaseRenderer()
public final void setBaseRendererState(ilog.tgo.graphic.renderer.internal.IltBaseRendererState s)
public final ilog.tgo.graphic.renderer.internal.IltBaseRendererState getBaseRendererState()
public final void setView(IlpGraphicView v)
v
- Graphic viewpublic final IlpGraphicView getView()
public final void setRepresentationObject(IlpRepresentationObject ro)
ro
- Representation objectpublic final IlpRepresentationObject getRepresentationObject()
public IltDetailLevel getDetailLevel()
The value depends on the semantic state of the object.
public void setDetailLevel(IltDetailLevel level)
The value depends on the semantic state of the object.
level
- Detail level used to draw the face part.public IltPattern getPattern()
null
, no pattern is used.
The value depends on the semantic state of the object.
public void setPattern(IltPattern p)
null
,
no pattern is used.p
- Patternpublic Color getForeground()
The value depends on the semantic state of the object.
This function is not meant to be overridden in subclasses.
public void setForeground(Color fg)
fg
- Foreground colorpublic Color getBackground()
The value depends on the semantic state of the object.
public void setBackground(Color bg)
bg
- background colorpublic int getFillStyle()
IlFillStyle
public void setFillStyle(int i)
IlFillStyle
public float getFillStart()
This property is used if the fill style is set to
IlFillStyle.LINEAR_GRADIENT
or
IlFillStyle.RADIAL_GRADIENT
.
public void setFillStart(float v)
This property is used if the fill style is set to
IlFillStyle.LINEAR_GRADIENT
or
IlFillStyle.RADIAL_GRADIENT
.
public float getFillEnd()
This property is used if the fill style is set to
IlFillStyle.LINEAR_GRADIENT
or
IlFillStyle.RADIAL_GRADIENT
.
public void setFillEnd(float v)
This property is used if the fill style is set to
IlFillStyle.LINEAR_GRADIENT
or
IlFillStyle.RADIAL_GRADIENT
.
public float getFillAngle()
For a linear gradient, an angle of 0
means that the gradient
goes from left to right (that is, the first color is on the left, and the
second color on the right); an angle of 45
means that the
gradient goes from the bottom to the top, and so on. For a radial gradient,
the angle specifies the position of the center of the gradient relative
to the center of the shape. Any angle between 0
and 360
can be used.
This property is used if the fill style is set to
IlFillStyle.LINEAR_GRADIENT
or
IlFillStyle.RADIAL_GRADIENT
.
public void setFillAngle(float v)
For a linear gradient, an angle of 0
means that the gradient
goes from left to right (that is, the first color is on the left, and the
second color on the right); an angle of 45
means that the
gradient goes from the bottom to the top, and so on. For a radial gradient,
the angle specifies the position of the center of the gradient relative
to the center of the shape. Any angle between 0
and 360
can be used.
This property is used if the fill style is set to
IlFillStyle.LINEAR_GRADIENT
or
IlFillStyle.RADIAL_GRADIENT
.
public Image getFillTexture()
The texture is used if the fill style is set to
IlFillStyle.TEXTURE
public void setFillTexture(Image v)
The texture is used if the fill style is set to
IlFillStyle.TEXTURE
public float getBorderWidth()
The value depends on the semantic state of the object.
public void setBorderWidth(float w)
The value depends on the semantic state of the object.
public Color getBorderColor()
The value depends on the semantic state of the object.
public void setBorderColor(Color c)
The value depends on the semantic state of the object.
public Color getBorderColor2()
The value depends on the semantic state of the object.
public void setBorderColor2(Color c)
The value depends on the semantic state of the object.
public IltLineStyle getBorderLineStyle()
The value depends on the semantic state of the object.
public void setBorderLineStyle(IltLineStyle l)
The value depends on the semantic state of the object.
public IltPattern getBorderPattern()
The value depends on the semantic state of the object.
public void setBorderPattern(IltPattern p)
The value depends on the semantic state of the object.
protected boolean isReliefBorders()
The value depends on the semantic state of the object.
public void setReliefBorders(boolean b)
The value depends on the semantic state of the object.
protected boolean isPolygonalBorder()
public void setPolygonalBorder(boolean b)
protected boolean isAlarmBorderVisible()
This function is not meant to be overridden in subclasses.
public void setAlarmBorderVisible(boolean v)
public Color getAlarmBorderColor()
null
if no alarm
border is to be drawn.
The value depends on the semantic state of the object.
public void setAlarmBorderColor(Color c)
null
if no alarm
border is to be drawn.
The value depends on the semantic state of the object.
public int getAlarmBorderWidth()
public void setAlarmBorderWidth(int width)
protected final boolean isBaseSelectionBorderVisible()
public final void setBaseSelectionBorderVisible(boolean v)
This function is not meant to be overridden in subclasses.
public int getSelectionBorderWidth()
public void setSelectionBorderWidth(int v)
public Color getSelectionBorderForeground()
null
if no
selection border is to be drawn.
The value depends on the graphic object environment.
public void setSelectionBorderForeground(Color c)
null
if no
selection border is to be drawn.
The value depends on the graphic object environment.
public Color getSelectionBorderBackground()
null
if no
selection border is to be drawn.
The value depends on the graphic object environment.
public void setSelectionBorderBackground(Color v)
null
if no
selection border is to be drawn.
The value depends on the graphic object environment.
public IltLineStyle getSelectionBorderLineStyle()
null
if no
selection border is to be drawn.
The value depends on the graphic object environment.
public void setSelectionBorderLineStyle(IltLineStyle l)
null
if no
selection border is to be drawn.
The value depends on the graphic object environment.
protected boolean isDottedBorderVisible()
true
, a dotted border with a
thickness of 1
pixel is drawn around the base.
Note that the dotted border is only drawn when this method returns
true
, and when no alarm border is drawn (that is,
isAlarmBorderVisible()
returns false
).
Some subclasses override this method to force a dotted border to be displayed or hidden.
@Deprecated public final boolean __isDottedBorderVisible()
public void setDottedBorderVisible(boolean v)
true
, a dotted border with a
thickness of 1
pixel is drawn around the base.public Color getDottedBorderForeground()
null
if no dotted border is to be drawn.
The value depends on the graphic object environment.
public void setDottedBorderForeground(Color c)
null
if no dotted border is to be drawn.
The value depends on the graphic object environment.
public Color getDottedBorderBackground()
null
if no dotted border is to be drawn.
The value depends on the graphic object environment.
public void setDottedBorderBackground(Color c)
null
if no dotted border is to be drawn.
The value depends on the graphic object environment.
public IltLineStyle getDottedBorderLineStyle()
null
if no
dotted border is to be drawn.
The value depends on the graphic object environment.
public void setDottedBorderLineStyle(IltLineStyle l)
null
if no
dotted border is to be drawn.
The value depends on the graphic object environment.
public Image getSourceImage()
public void setSourceImage(Image sourceImage)
public int getAlarmColorLevel()
public void setAlarmColorLevel(int level)
public boolean isAlarmColorVisible()
public void setAlarmColorVisible(boolean visible)
public final Ilt2DPalette getPalette()
The value depends on the semantic state of the object.
This palette is automatically built depending on the property values. See the description array at the beginning of this file, for more information on the policy used to build this palette.
This function is not meant to be overridden in subclasses.
public final IltPalette getBorderPalette()
The value depends on the semantic state of the object.
This palette is automatically built depending on the property values. See the description array at the beginning of this file, for more information on the policy used to build this palette.
This function is not meant to be overridden in subclasses.
public final Ilt2DPalette getBrightPalette()
The value depends on the semantic state of the object.
This function is not meant to be overridden in subclasses.
public final Ilt2DPalette getDarkPalette()
The value depends on the semantic state of the object.
This function is not meant to be overridden in subclasses.
protected final IltPalette getDottedBorderPalette()
public final boolean isUsingBlinkingResources()
@Deprecated public final int getDeprecatedBlinkingMode()
This method is used only for compatibility.
@Deprecated public final void setDeprecatedBlinkingMode(int v)
This method is used only for compatibility.
public void initResources()
This method can be overridden if you want to modify the value of the properties that have been automatically set by JTGO.
If this method is overridden, super.initResources()
should be called after setting your own values.
public void dropResources()
This function can be overridden in subclasses in order to drop additional colors, patterns, etc. If this method is overridden, super.dropResources() should be called.
public void attach(IlvGraphic g)
IlvGraphic
it is used by. The default implementation of this method does nothing.
Any subclass of the base renderer that needs the IlvGraphic
may use the one
given when this method is invoked.public void draw(Graphics g, IlvTransformer t, IlvRect rect)
g
- The graphics context to draw into.t
- The transformer that has been applied to rect
. (It is only
passed because drawing with an Ilt2DPalette
requires it.)rect
- The rectangle to draw into. This is a rectangle with
integer coordinates. Its corners have the following coordinates
x1 = rect.x,
x2 = rect.x + rect.width - 1,
y1 = rect.y,
y2 = rect.y + rect.height - 1.
The default implementation of this function calls drawMain
and
drawExtraBorders
.
protected abstract void drawMain(Graphics g, IlvTransformer t, IlvRect rect)
g
- As in draw
.t
- As in draw
.rect
- As in draw
.protected IltPolygon[] getExtraBorders(IlvRect rect)
This implementation returns null
, which means that it is
assumed that the base has no particular border. The
parameter rect
, used when draw
is invoked,
is then considered to be the border of the base.
This method should be overridden in subclasses if the borders should
have particular shapes. When this method returns one or more polygons,
the drawn border is not a rectangle any longer, but uses the shapes
of the given polygons (possibly stretched to be inside or outside the
base, depending on the value returned by
isExtraBorderOutside
).
Drawing a rectangle or a particular shape is decided in the method
drawExtraBorder
according to the value returned by
getExtraBorders
.
The polygons returned by this method are used by the methods
drawExtraBorder
and containsExtraBorders
.
Note: The polygons returned by this methods should be transformed to be in the same coordinate system as the drawn base.
protected void drawExtraBorders(Graphics g, IlvTransformer t, IlvRect rect)
The default implementation of this function calls drawExtraBorder
once for each border that has to be drawn.
g
- As in draw
.t
- As in draw
.rect
- As in draw
.drawExtraBorder(Graphics, IlvTransformer, IlvRect, IltPalette, int, int)
protected boolean drawAlarmBorder(Graphics g, IlvTransformer t, IlvRect rect, int distance)
protected boolean drawSelectionBorder(Graphics g, IlvTransformer t, IlvRect rect, int distance)
protected abstract boolean isExtraBorderOutside()
rect
used to call drawExtraBorders
.protected void drawExtraBorder(Graphics g, IlvTransformer t, IlvRect rect, Color color, int distance, int width)
isExtraBorderOutside()
.
The default implementation of this function creates a mono-color 1D
palette with the given color
and calls
drawExtraBorder(Graphics,IlvTransformer,IlvRect,IltPalette,int,int)
.
g
- As in draw
.t
- As in draw
.rect
- As in draw
.color
- The color for the border.distance
- The distance from the main part (not including thickness).width
- The width of the border.drawExtraBorder(Graphics, IlvTransformer, IlvRect, IltPalette, int, int)
protected void drawExtraBorder(Graphics g, IlvTransformer t, IlvRect rect, IltPalette palette, int distance, int width)
isExtraBorderOutside()
.
This method is called by drawExtraBorders
for each border that
needs to be drawn (selection, alarm and dotted borders).
The shape of the drawn borders is a rectangle if the dotted border
is visible OR if getExtraBorders
returns null
.
If the dotted border is invisible AND getExtraBorders
returns a non-null array of IltPolygon
,
then these polygons are used as shapes for the borders.
g
- As in draw
t
- As in draw
rect
- As in draw
palette
- The palette with the border colorsdistance
- The distance from the main part (not including width)width
- The width of the bordergetExtraBorders(ilog.views.IlvRect)
,
isExtraBorderOutside()
,
isDottedBorderVisible()
public IlvRect boundingBox(IlvTransformer t, IlvRect rect, boolean withSelection)
draw(g,t,rect)
draws into.
The argument rect
is a fresh copy and may be
destructively modified by this function.
This implementation of the function assumes that the main part
fills rect
. Depending on the value returned by
isExtraBorderOutside()
, the function returns rect
, or
rect
enlarged by the width of
the selection border, alarm border and dotted border, if present.
t
- Transformer applied to the object.rect
- As in draw
.withSelection
- if false
the rect
will not be enlarged by the selection.protected IlvRect boundingBoxWithTransformer(IlvTransformer t, IlvRect rect, boolean withSelection)
public boolean contains(IlvPoint p, IlvPoint tp, IlvTransformer t, IlvRect rect)
This implementation returns true
if
containsMain
or containsExtraBorders
returns
true
.
Note: The parameters tp
and rect
are given in
the same coordinate system. The transformer t
has already
been applied to these parameters.
p
- The point to be tested.tp
- The point p
transformed by the transformer t
.t
- The transformation that was applied to the object when it was
drawn.rect
- As in draw
.containsMain(ilog.views.IlvPoint, ilog.views.IlvPoint, ilog.views.IlvTransformer, ilog.views.IlvRect)
,
containsExtraBorders(ilog.views.IlvPoint, ilog.views.IlvPoint, ilog.views.IlvTransformer, ilog.views.IlvRect)
protected boolean containsMain(IlvPoint p, IlvPoint tp, IlvTransformer t, IlvRect rect)
true
only if the point corresponds to a point
drawn by the method drawMain
.
This implementation returns true
if the point tp
is
inside the rectangle rect
, because it is assumed that the
implementation of the drawMain
method fills
rect
.
Note: This method may be overridden to take into account the shape drawn by this base renderer, if it is not rectangular or if it has transparency.
Note: The parameters tp
and rect
are given in
the same coordinate system. The transformer t
has already
been applied to these parameters.
p
- The point to be tested.tp
- The point p
transformed by the transformer t
.t
- The transformation that was applied to the object when it was
drawn.rect
- As in draw
.drawMain(java.awt.Graphics, ilog.views.IlvTransformer, ilog.views.IlvRect)
protected boolean containsExtraBorders(IlvPoint p, IlvPoint tp, IlvTransformer t, IlvRect rect)
true
only if the point corresponds to a point
drawn by the method drawExtraBorders
.
This implementation returns true
if the point tp
is
one of the pixels drawn by the default implementation of
drawExtraBorders
. It takes into account the dotted border
when drawn, and the rectangular or polygonal borders according to the
value returned by getExtraBorders
.
Note: This method may be overridden to take into account particular borders drawn by a subclass.
Note: The parameters tp
and rect
are given in
the same coordinate system. The transformer t
has already
been applied to these parameters.
p
- The point to be tested.tp
- The point p
transformed by the transformer t
.t
- The transformation that was applied to the object when it was
drawn.rect
- As in draw
.getExtraBorders(ilog.views.IlvRect)
,
drawExtraBorders(java.awt.Graphics, ilog.views.IlvTransformer, ilog.views.IlvRect)
© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.