public class Shape extends Series
Title: Shape class
Description: Shape Series.
Copyright (c) 2005-2019 by Steema Software SL. All Rights Reserved.
Company: Steema Software SL
Series.MarkTextResolver
AUTODEPTH, AUTOZORDER, bActive, bBrush, bColorEach, calcVisiblePoints, colorMember, customMarkText, drawBetweenPoints, endZ, firstVisible, hasZValues, iColors, iNumSampleValues, iZOrder, labelMember, lastVisible, listenerList, mandatory, manualData, marks, middleZ, notMandatory, oldDataSource, percentDecimal, percentFormat, sLabels, startZ, useAxis, useSeriesColor, valueFormat, vxValues, vyValues, yMandatory
chart, InternalUse
Constructor and Description |
---|
Shape() |
Shape(IBaseChart c) |
Modifier and Type | Method and Description |
---|---|
protected void |
addSampleValues(int numValues) |
void |
assign(Series source)
Copies all properties from one Series component to another.
Only the common properties shared by both source and destination Series are copied. |
void |
calcZOrder() |
int |
clicked(int x,
int y)
Returns the ValueIndex of the "clicked" point in the Series.
|
void |
createSubGallery(Gallery addSubChart) |
protected void |
drawLegendShape(IGraphics3D g,
int valueIndex,
Rectangle rect) |
void |
drawValue(int valueIndex)
Called internally.
|
ChartBrush |
getBrush()
Defines the brush used to fill shape background.
|
java.lang.String |
getDescription()
Gets descriptive text.
|
ChartFont |
getFont()
Determines the font attributes used to output ShapeSeries.
No auto font sizing is performed, so you must specify the desired font size to avoid shape text from overlapping the Shape boundaries. |
TextShape |
getFormat() |
Gradient |
getGradient()
Gets Gradient fill characteristics for the ShapeSeries Shape.
|
ShapeTextHorizAlign |
getHorizAlignment()
Horizontally aligns the text.
There are three options; Centre, Left or Right. |
ChartPen |
getPen()
Defines pen to draw Series Shape.
|
ShapeStyle |
getStyle()
Defines how a TChartShape component appears on a Chart.
Default value: Circle |
java.lang.String[] |
getText()
Displays customized Strings inside Shapes.
You can use the Font and Aligment properties to control Text display. Note: You may need to change Shape Font size to a different value when creating metafiles or when zooming Charts. |
java.lang.String |
getText(int index) |
boolean |
getTransparent()
Allows Shape Brush attributes to fill the interior of the Shape.
When false, Shapes do not redraw their background, so charting contents behind Shape Series is seen inside the Shape. |
ShapeTextVertAlign |
getVertAlignment()
Sets the vertical alignment of Text within a TChartShape Series shape.
|
double |
getX0()
Coordinate used to define the englobing ShapeSeries rectangle.
The values should be expressed in Axis coordinates. |
double |
getX1()
Coordinate used to define the englobing ShapeSeries rectangle.
The values should be expressed in Axis coordinates. |
ShapeXYStyle |
getXYStyle()
Can be set to:- Axis, AxisOrigin or Pixels.
|
double |
getY0()
Coordinate used to define the englobing ShapeSeries rectangle.
The values should be expressed in Axis coordinates. |
double |
getY1()
Coordinate used to define the englobing ShapeSeries rectangle.
The values should be expressed in Axis coordinates. |
boolean |
isValidSourceOf(Series s)
Returns false if the Value parameter is the same as Self.
|
protected boolean |
moreSameZOrder()
Returns true if there are more series that share the same Z order.
For example Stacked Bars. |
void |
prepareForGallery(boolean isEnabled) |
void |
setChart(IBaseChart c)
Chart associated with this object.
|
void |
setHorizAlignment(ShapeTextHorizAlign value)
Horizontally aligns the text.
|
void |
setStyle(ShapeStyle value)
Defines how a TChartShape component appears on a Chart.
Default value: Circle |
void |
setSubGallery(int index)
Creates and prepares the index'th Series style to show at sub-gallery
dialog.
|
void |
setText(java.lang.String[] value) |
void |
setTransparent(boolean value)
Allows Shape Brush attributes to fill the interior of the Shape.
Default value: false |
void |
setVertAlignment(ShapeTextVertAlign value)
Sets the vertical alignment of Text within a TChartShape Series shape.
|
void |
setX0(double value)
Coordinate used to define the englobing ShapeSeries rectangle.
|
void |
setX1(double value)
Coordinate used to define the englobing ShapeSeries rectangle.
|
void |
setXYStyle(ShapeXYStyle value)
Can be set to:- Axis, AxisOrigin or Pixels.
|
void |
setY0(double value)
Coordinate used to define the englobing ShapeSeries rectangle.
|
void |
setY1(double value)
Coordinate used to define the englobing ShapeSeries rectangle.
|
add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, add, addChartValue, added, addedValue, addNull, addNullXY, addSeriesMouseListener, addSeriesPaintListener, addValues, assignDispose, assignValues, associatedToAxis, beginUpdate, calcFirstLastVisibleIndex, calcHorizMargins, calcPercentSt, calcPosValue, calculateMarkPosition, calcVerticalMargins, calcXPos, calcXPosValue, calcXSizeValue, calcYPos, calcYPosValue, calcYSizeValue, canAddRandomPoints, changeType, checkDataSource, checkMouse, checkOrder, checkOtherSeries, clear, clearLists, clicked, clone, cloneSeries, convertArray, countLegendItems, createNewSeries, createNewSeries, createNewSeries, dataSourceArray, delete, delete, delete, dispose, doAfterDrawValues, doBeforeDrawChart, doBeforeDrawValues, doClick, doClickPointer, doDoubleClick, draw, drawHiddenValue, drawLegend, drawLegend, drawMark, drawMarks, drawMarksSeries, drawSeries, drawSeriesForward, drawValuesForward, endUpdate, fillSampleValues, fillSampleValues, fireSeriesMouseEvent, fireSeriesPaint, firstDisplayed, galleryChanged3D, getActive, getAllowSinglePoint, getBitmapEditor, getColor, getColorEach, getColorMember, getColors, getCount, getCountLegendItems, getCursor, getCustomHorizAxis, getCustomVertAxis, getDataSource, getDefaultColor, getDefaultNullValue, getDepth, getEndZ, getFields, getFirstVisible, getFunction, getHasZValues, getHorizAxis, getHorizontalAxis, getLabelMember, getLabels, getLastVisible, getLegendString, getMandatory, getMandatoryAxis, getMarks, getMarkText, getMarkValue, getMaxXValue, getMaxYValue, getMaxZValue, getMiddleZ, getMinXValue, getMinYValue, getMinZValue, getNotMandatory, getNumGallerySeries, getNumSampleValues, getOriginValue, getPercentFormat, getPoint, getSeriesColor, getShowInLegend, getStartZ, getTitle, getUseAxis, getValueColor, getValueFormat, getValueIndexSwapper, getValueList, getValueList, getValueMarkText, getValuesLists, getVertAxis, getVerticalAxis, getVisible, getXValues, getYMandatory, getYValueList, getYValues, getZOrder, hasClickEvents, hasColors, hasDataSource, hasLabels, hasListenersOf, hasNoMandatoryValues, isNull, isPointInChartRect, isValidSeriesSource, lastDisplayed, lastVisibleMark, legendItemColor, legendToValueIndex, maxMarkWidth, mouseEvent, newFromType, numSampleValues, onDisposing, prepareLegendCanvas, randomBounds, readResolve, recalcGetAxis, refreshSeries, removeMarkTextResolver, removeSeriesMouseListener, removeSeriesPaintListener, repaint, sameClass, setActive, setColor, setColorEach, setColorMember, setColors, setCursor, setCustomHorizAxis, setCustomHorizAxis, setCustomVertAxis, setCustomVertAxis, setDataSource, setDefaultNullValue, setDepth, setEndZ, setFunction, setHorizontal, setHorizontalAxis, setLabelMember, setLabels, setMarks, setMarkTextResolver, setMiddleZ, setNull, setNull, setPercentFormat, setSeriesColor, setShowInLegend, setStartZ, setTitle, setValueFormat, setValueList, setVerticalAxis, setVisible, setXValues, setYValues, setZOrder, setZPositions, sortByLabels, sortByLabels, sortDrawSeries, swapValueIndex, titleOrName, toString, valueListOfAxis, valuesListAdd, xScreenToValue, yScreenToValue
getChart, invalidate, setBooleanProperty, setColorProperty, setDoubleProperty, setIntegerProperty, setStringProperty
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getChart, invalidate
public Shape()
public Shape(IBaseChart c)
public void assign(Series source)
Series
public void setChart(IBaseChart c)
TeeBase
protected void drawLegendShape(IGraphics3D g, int valueIndex, Rectangle rect)
drawLegendShape
in class Series
public java.lang.String getText(int index)
public double getX0()
public void setX0(double value)
value
- doublepublic double getX1()
public void setX1(double value)
value
- doublepublic double getY0()
public void setY0(double value)
value
- doublepublic double getY1()
public void setY1(double value)
value
- doublepublic ShapeStyle getStyle()
public void setStyle(ShapeStyle value)
value
- ShapeStylepublic TextShape getFormat()
public ShapeTextVertAlign getVertAlignment()
public void setVertAlignment(ShapeTextVertAlign value)
value
- ShapeTextVertAlignpublic ShapeTextHorizAlign getHorizAlignment()
public void setHorizAlignment(ShapeTextHorizAlign value)
value
- ShapeTextHorizAlignpublic void drawValue(int valueIndex)
protected void addSampleValues(int numValues)
addSampleValues
in class Series
public int clicked(int x, int y)
public ChartFont getFont()
public ChartBrush getBrush()
Example:
//shape1 shape[0] = new Shape(myChart.getChart()); tmpShape = shape[0]; tmpShape.getMarks().setVisible(false); tmpShape.setColor(Color.WHITE); tmpShape.getBrush().setColor(Color.WHITE); tmpShape.getBrush().setImageMode(ImageMode.TILE); tmpShape.getBrush().loadImage(ChartSamplePanel.class.getResource(URL_IMAGE1)); tmpShape.setStyle(ShapeStyle.CIRCLE); tmpShape.getPen().setColor(Color.RED); tmpShape.getPen().setWidth(2); tmpShape.setX1(50); tmpShape.setY1(50);
public ChartPen getPen()
public Gradient getGradient()
public java.lang.String[] getText()
public void setText(java.lang.String[] value)
public boolean getTransparent()
public void setTransparent(boolean value)
value
- booleanpublic void prepareForGallery(boolean isEnabled)
prepareForGallery
in class Series
public void calcZOrder()
calcZOrder
in class Series
protected boolean moreSameZOrder()
Series
moreSameZOrder
in class Series
public ShapeXYStyle getXYStyle()
public void setXYStyle(ShapeXYStyle value)
value
- ShapeXYStylepublic boolean isValidSourceOf(Series s)
isValidSourceOf
in class Series
s
- Seriespublic void createSubGallery(Gallery addSubChart)
createSubGallery
in class Series
public void setSubGallery(int index)
Series
setSubGallery
in interface ISeries
setSubGallery
in class Series
index
- intpublic java.lang.String getDescription()
getDescription
in class Series