SimChart 3.0 Reference

Hierarchy:

TGraphicControl -- TSCMain +-- TSCChart
                           |
                           +-- TSCPie
                           |
                           +-- TSCHBar
                           |
                           +-- TSCRadar

New properties, methods and events:

 TSCChart
 Properties BarStyle
DataHLOC
HintOptions
Kind
LeftVisiblePoint
MarkerSize
MarkerStyle
NVisiblePoint
Options
PenStyle
PenWidth
Percent3D
ValueFormatLeft
ValueFormatRight
WallColor
XAxis
XCaption
XGridColor
YLeftAxis
YLeftCaption

YLeftGridColor
YLeftInitValue
YLeftLogBase
YRightAxis
YRightCaption
YRightGridColor
YRightInitValue
YRightLogBase
Derived from TSCMain:
AntiAlias
BackColor
BorderWidth
BottomCaption

Chart3D
ColorValues
DataValues

ForeColor

Legend
NPoint
NSeries

PointLabels
SeriesLabels
TopCaption
 Methods AddBarSeries
AddLineSeries
AddSeries CalcXPoint CalcYValue
Derived from TSCMain:
BeginUpdate
ClearData
CopyToBitmap

CopyToMetafile
DeleteSeries
EndUpdate

GetPercent
PtInChart
SHLPoint

SHRPoint
SwapSeries
 Events
Derived from TSCMain:
OnAfterDraw

OnChange

OnClickOnChart
 
OnGetHint
         
 TSCPie
 Properties Explode
Explodes
HintOptions
Kind
Options PercentExplode
Derived from TSCMain:
AntiAlias
BackColor
BorderWidth
BottomCaption

Chart3D
ColorValues
DataValues
ForeColor

Legend
NPoint
NSeries
PointLabels

SeriesLabels
TopCaption
ValueFormat
 Methods  
Derived from TSCMain:
BeginUpdate
ClearData
CopyToBitmap

CopyToMetafile
EndUpdate
GetPercent

PtInChart
SHLPoint

SHRPoint
SwapSeries
 Events
Derived from TSCMain:
OnAfterDraw

OnChange

OnClickOnChart
 
OnGetHint
         
 TSCHBar
 Properties BarStyle
HintOptions
Kind
Options
Percent3D
WallColor
XAxis
XCaption
XGridColor
XLabelPos
YAxis
YCaption
YGridColor
YInitValue
Derived from TSCMain:
AntiAlias
BackColor
BorderWidth
BottomCaption

Chart3D
ColorValues
DataValues
ForeColor

Legend
NPoint
NSeries
PointLabels

SeriesLabels
TopCaption
ValueFormat
 Methods AddSeries      
Derived from TSCMain:
BeginUpdate
ClearData
CopyToBitmap

CopyToMetafile
DeleteSeries
EndUpdate

GetPercent
PtInChart
SHLPoint

SHRPoint
SwapSeries
 Events
Derived from TSCMain:
OnAfterDraw

OnChange

OnClickOnChart
 
OnGetHint
         
 TSCRadar
 Properties Axis
Filled
GridColor
HintOptions
Kind
MarkerSize
MarkerStyle
PenStyle
PenWidth
WallColor
YInit
  Derived from TSCMain:
AntiAlias
BackColor
BorderWidth
BottomCaption

Chart3D
ColorValues
DataValues
ForeColor

Legend
NPoint
NSeries
PointLabels

SeriesLabels
TopCaption
ValueFormat
 Methods AddRadar      
  Derived from TSCMain:
BeginUpdate
ClearData
CopyToBitmap

CopyToMetafile
DeleteSeries
EndUpdate

GetPercent
PtInChart
SHLPoint

SHRPoint
SwapSeries
 Events        
  Derived from TSCMain:
OnAfterDraw

OnChange

OnClickOnChart
 
OnGetHint

 


 TSCMain
 Properties
  property AntiAlias: TAntiAlias;
TAntiAlias = ( aaNone, aaLo, aaHi );
  Set anti-alias mode used to improve chart image. Note: aaHi provide best anti-alias but slower to draw, it's not recommended to use for big chart or on slow computer.
  property BackColor: TColor;   Set chart's background color.
  property BorderWidth: Integer;   BorderWidth is the distance, in pixels, between component border and the chart image.
  property BottomCaption: string;   Places a text at the bottom of the chart. Can use little HTML formating.
  property Chart3D: Boolean;   If set to True it will display the chart in perspective view (3D).
  property ColorValues[ASeries: Integer]: TColor;   This property is used to store color information for each series.
  property DataValues[ASeries, APoint: Integer]: Single;   Use this property to enter chart's data values.
  property ForeColor: TColor;   Set chart's foreground color.
  property Legend: TLegend;   Change various legend display properties.
  property NPoint: Integer;   Set number of data point for each series.
  property NSeries: Integer;   NSeries is the number of series on the chart.
  property PointLabels[APoint: Integer]: string;   This property is used to store data point labels.
  property SeriesLabels[ASeries: Integer]: string;   This property is used to store series labels. These labels are then used as legend text to draw legend.
  property TopCaption: string;   Places a text on the top of the chart, commonly used to display chart title. Can use little HTML formating.
  property ValueFormat: string;   Set text used to format chart's data values.
 Methods (TSCMain)
  procedure BeginUpdate;   BeginUpdate method suspends updating and  drawing of the chart until EndUpdate method is called. Call this method before making multiple changes to the chart to prevent multiple calculations and draws.
  procedure ClearData( Flag: TClear );
TClear = ( clAll, clDataValue, clSeriesLabel, clPointLabel );
  Clear chart data as specified by the Flag parameter.
  procedure CopyToBitmap( ABitmap: TBitmap; AntiAlias: TAntiAlias = aaNone; AWidth: Integer = 0; AHeight: Integer = 0; ABorder: Integer = -1 );   Copy the chart image to ABitmap in bitmap format.
  procedure CopyToMetafile( var AMetafile: TMetafile; AWidth: Integer = 0; AHeight: Integer = 0; ABorder: Integer = -1 );   Copy the chart image to AMetafile in metafile format. Windows only.
  procedure DeleteSeries( ASeries: Integer );   This method is used to delete a series.
  procedure EndUpdate;   EndUpdate method re-enables chart updating that was turned off with BeginUpdate method.
  procedure GetPercent( ASeries, APoint: Integer ): Single;   Get percentage value of a data point.
  function PtInChart( X, Y: Integer; var ASArea: TSArea ): Boolean;
TSArea = record
  Series, Point, Legend: Integer;
  R: TRect;
end;
  Use this method to get chart area information on coordinate (X, Y).
  procedure SHLPoint( APoint: Integer );   Shift left the chart data, and fill the right side with zero.
  procedure SHRPoint( APoint: Integer );   Shift right the chart data, and fill the left side with zero.
  procedure SwapSeries( Series1, Series2: Integer );   Exchange the series position of two series in the chart.
 Events (TSCMain)
  property OnAfterDraw: TNotifyEvent;   OnAfterDraw occurs when the chart just has been drawn.
  property OnChange: TNotifyEvent;    
  property OnClickOnChart: TClickOnChartEvent = procedure( Sender: TObject; Shift: TShiftState; ASeries, APoint, ALegend: Integer ) of object;   OnClickOnChart occurs when the user clicks on the chart.
  property OnGetHint: TGetHintEvent = procedure( Sender: TObject; ASeries, APoint, ALegend: Integer; var HintText: string ) of object;   OnGetHint occurs when the hint window is about to be displayed. You can modify the HintText variable to change the default hint text. Hint text can use little HTML formating.
       
 TSCChart
 Properties
  property BarStyle[ASeries: Integer]: TBarStyle;
TBarStyle = ( bsBar, bsCylinder, bsPyramid, bsCone );
  For bar series only. Change bar style for each series.
  property DataHLOC[ASeries, APoint: Integer]: THLOC;
THLOC = record
  Hi, Lo, Open, Close: Single;
end;
  Use this property to enter data values for hi-lo, hi-lo-close, hi-lo-open-close and candle stick series. Values are entered in the order of hi, lo, open and then close value.
  property HintOptions: THintOptions;
THintOption = ( hoSeries, hoPoint, hoValue, hoOpenClose, hoPercent, hoStackedValue, hoStackedPercent, hoFocus );
THintOptions = set of THintOption;
  HintOptions specifies default hint text.
  property Kind[ASeries: Integer]: TChartKind;
TChartKind = ( ckLine, ckStair, ckArea, ckBar, ckHL, ckHLC, ckHLOC, ckCStick, ckCBar, ckSArea, ckSBar, ckCSBar, ckS100Area, ckS100Bar, ckCS100Bar );
  Specifies chart type for each series to be drawn.
  property LeftVisiblePoint: Integer;   Used to scroll the visible data point  that has been set by NVisiblePoint property.
  property MarkerSize[ASeries: Integer]: Integer;   For 2D line chart (ckLine) only. Specifies the size of marker in pixels.
  property MarkerStyle[ASeries: Integer]: TMarkerStyle;
TMarkerStyle = ( msNone, msSquare, msDiamond, msUpTri, msDownTri, msRound );
  For 2D line chart (ckLine) only. Specifies the style used to draw the line marker.
  property NVisiblePoint: Integer;   Set number of visible point.
  property Options: TCOptions;
TCOption = ( coRotateXLabel, coStaggerXLabel, coHideWall, coBarShade );
TCOptions = set of TCOption;
  Change chart various appearance.
  property PenStyle[ASeries: Integer]: TPenStyle;
TPenStyle = ( psSolid, psDash, psDot, psDashDot, psDashDotDot, psClear, psInsideFrame );
  For 2D line and stair chart (ckLine and ckStair) only. Change pen style used to draw the line.
  property PenWidth[ASeries: Integer]: Integer;   For 2D line and stair chart (ckLine and ckStair) only. Set pen width used to draw the line.
  property Percent3D: Integer;   Change the depth ratio on 3D-chart. You can specify a percent number from 1 to 50.
  property ValueFormatLeft: string;   Set text used to format y-left-axis value.
  property ValueFormatRight: string;   Set text used to format y-right-axis value.
  property WallColor: TColor;   Specifies the color used to draw chart's wall background.
  property XAxis: TAxis;   Change display properties for x-axis.
  property XCaption: string;   Set x-axis caption text.
  property XGridColor: TColor;   Specifies x-axis grid line color.
  property YAxis[ASeries: Integer]: TYAxis;
TYAxis = ( yaLeft, yaRight );
  Specifies which y-axis is used for each series.
  property YLeftAxis: TAxis;   Change display properties for y-left-axis.
  property YLeftCaption: string;   Set y-left-axis caption text.
  property YLeftGridColor: TColor;   Specifies y-left-axis grid line color. 
  property YLeftInitValue: TYInitValue;   Define initial max and min values for y-left-axis.
  property YLeftLogBase: Single;   Set base number for y-left-axis logarithmic scale.
  property YRightAxis: TAxis;   Change display properties for y-right-axis.
  property YRightCaption: string;   Set y-right-axis caption text.
  property YRightGridColor: TColor;   Specifies y-right-axis grid line color.
  property YRightInitValue: TYInitValue;   Define initial max and min values for y-right-axis.
  property YRightLogBase: Single;   Set base number for y-right-axis logarithmic scale.
 Methods (TSCChart)
  procedure AddBarSeries( AKind: TChartKind; AYAxis: TYAxis; AColor: TColor; ALabel: string; ABarStyle: TBarStyle );
TChartKind = ( ckLine, ckStair, ckArea, ckBar, ckHL, ckHLC, ckHLOC, ckCStick, ckCBar, ckSArea, ckSBar, ckCSBar, ckS100Area, ckS100Bar, ckCS100Bar );
  Use this method to add a bar series with its attributes.
  procedure AddLineSeries( AYAxis: TYAxis; AColor: TColor; ALabel: string; MarkerStyle: TMarkerStyle; MarkerSize, PenWidth: Byte; PenStyle: TPenStyle );   Use this method to add a 2D line series with its attributes.
  procedure AddSeries( AKind: TChartKind; AYAxis: TYAxis; AColor: TColor; ALabel: string );   Use this method to add a series on the chart.
  function CalcXPoint( ASeries: Integer; APoint: Integer ): Integer;   Convert a point position to chart's canvas X coordinate.
  function CalcYValue( AYAxis: TYAxis; ASeries: Integer; AYValue: Single ): Integer;   Convert a y-value to canvas Y coordinate.
       
 TSCPie
 Properties
  property Explode: Boolean;   If True then pie chart is in exploded state.
  property Explodes[ASeries: Integer]: Boolean;   Specifies whether a series is exploded or not.
  property HintOptions: THintOptions;
THintOption = ( hoSeries, hoPoint, hoValue, hoPercent, hoFocus );
THintOptions = set of THintOption;
  HintOptions specifies default hint text.
  property Kind: TPieKind;
TPieKind = ( ckPie, ckDoughnut );
  Specifies the type of the chart to be drawn.
  property Options: TPieOptions;
TPieOption = ( coShowLabel, coShowValue, coShowPercent );
TPieOptions = set of TPieOption;
  Specifies several labels to be displayed on the chart.
  property PercentExplode: Integer;   Change the explode range from center of the chart. You can specify a percent number from 1 to 50.
       
 TSCHBar
 Properties
  property BarStyle[ASeries: Integer]: TBarStyle;
TBarStyle = ( bsBar, bsCylinder, bsPyramid, bsCone );
  Change bar style for each series.
  property HintOptions: THintOptions;
THintOption = ( hoSeries, hoPoint, hoValue, hoPercent, hoStackedValue,hoStackedPercent, hoFocus );
THintOptions = set of THintOption;
  HintOptions specifies default hint text.
  property Kind[ASeries: Integer]: THKind;
THKind = ( ckHBar, ckSHBar, ckS100HBar );
  Specifies chart type for each series.
  property Options: THCOptions;
THCOption = ( coRotateYLabel, coStaggerYLabel, coHideWall, coBarShade );
THCOptions = set of THCOption;
  Change chart various appearance.
  property Percent3D: Integer;   Change the depth ratio on 3D-chart. You can specify a percent number from 1 to 50.
  property WallColor: TColor;   Specifies the color used to draw chart's wall background.
  property XAxis: TAxisOptions;  

Change display properties for x-axis.

  property XCaption: string;   Set x-axis caption text.
  property XGridColor: TColor;   Specifies x-axis grid line color.
  property XLabelPos: TXLabelPos;
TXLabelPos = ( xlLeft, xlTop, xlMiddle );
  Specifies x-axis label placement.
  property YAxis: TAxisOptions;   Change display properties for y-axis.
  property YCaption: string;   Set y-axis caption text.
  property YGridColor: TColor;   Specifies y-axis grid line color.
  property YInitValue: TYInitValue;   Define initial max and min values for y-axis.
 Methods (TSCHBar)
  procedure AddSeries( AKind: THKind; ABarStyle: TBarStyle;
ALabel: string; AColor: TColor );
THKind = ( ckHBar, ckSHBar, ckS100HBar );
  Use this method to add a series on the chart.
       
 TSCRadar
 Properties
  property Axis: TAxisOptions;   Change display properties for the axis.
  property Filled[ASeries: Integer]: Boolean;   Specifies whether a radar series is filled or not.
  property GridColor: TColor;   Specifies grid line color.
  property HintOptions: THintOptions;
THintOption = ( hoSeries, hoPoint, hoValue, hoPercent, hoStackedValue, hoStackedPercent, hoFocus );
THintOptions = set of THintOption;
  HintOptions specifies default hint text.
  property Kind: TRKind;
TRKind = ( ckRadar, ckSRadar, ckS100Radar );
  Specifies the type of the chart to be drawn.
  property MarkerSize[ASeries: Integer]: Integer;   Specifies the size of marker in pixels.
  property MarkerStyle[ASeries: Integer]: TMarkerStyle;
TMarkerStyle = ( msNone, msSquare, msDiamond, msUpTri, msDownTri, msRound );
  Specifies the style used to draw the line marker.
  property PenStyle[ASeries: Integer]: TPenStyle;
TPenStyle = ( psSolid, psDash, psDot, psDashDot, psDashDotDot, psClear, psInsideFrame );
  Set pen style used to draw the line.
  property PenWidth[ASeries: Integer]: Integer;   Set pen width used to draw the line.
  property WallColor: TColor;   Specifies the color used to draw chart's wall background.
  property YInit: TYInitValue;   Define initial max and min values for y-axis.
 Methods (TSCRadar)
  procedure AddRadar( ALabel: string; AColor: TColor; AMStyle: TMarkerStyle = msSquare; AMSize: Integer = 3; APenWidth: Integer = 1; APenStyle: TPenStyle = psSolid; Filled: Boolean = False );   Use this method to add a radar series on the chart.
       
 Little HTML Formating

Some captions and hint text on SimChart can use little HTML formating. Supported HTML formating include:

  • <b></b> - bold
  • <i></i> - italic
  • <u></u> - underline
  • <s></s> - striketrough
  • <font face=Tahoma size=14 color=#FF00C0></font> - change font setting
  • <br> - line break
  • <left>, <right> and <center> - change line alignment
 Copyright © 2004 Adi P. Winarso. All rights reserved. Last updated: May 11th, 2004.