Difference between revisions of "TAChart Chart"

From Lazarus wiki
Jump to navigationJump to search
 
(6 intermediate revisions by 3 users not shown)
Line 1: Line 1:
The Chart is the component from where you control much of the behaviour of your diagrams.
+
!! Under Construction... !!
 +
 
 +
The Chart is the component from where you control much of the behavior of your diagrams.
  
<br>
 
 
* [[#Methods_Public_id|'''Public Methods''']]
 
* [[#Methods_Public_id|'''Public Methods''']]
Clone <br>
+
*:Clone  
SaveToImage <br>
+
*:SaveToImage  
GetFullExtent <br>
+
*:GetFullExtent  
GetLegendItems <br>
+
*:GetLegendItems
GraphToImage <br>
+
*:GraphToImage
ImageToGraph <br>
+
*:ImageToGraph  
XGraphToImage <br>
+
*:XGraphToImage  
XImageToGraph <br>
+
*:XImageToGraph  
YGraphToImage <br>
+
*:YGraphToImage  
YImageToGraph <br>
+
*:YImageToGraph  
 
 
 
# [[#IsPointInViewPort_id|'''IsPointInViewPort <F>''']]
 
# [[#IsPointInViewPort_id|'''IsPointInViewPort <F>''']]
 
# [[#EraseBackground_id|'''EraseBackground <P>''']]
 
# [[#EraseBackground_id|'''EraseBackground <P>''']]
Line 22: Line 22:
 
# [[#DrawLineVert_id|'''Procedure DrawLineVert''']]
 
# [[#DrawLineVert_id|'''Procedure DrawLineVert''']]
 
# [[#DrawOnCanvas_id|'''Procedure DrawOnCanvas''']]
 
# [[#DrawOnCanvas_id|'''Procedure DrawOnCanvas''']]
AddSeries <br>
+
#:AddSeries
DeleteSeries <br>
+
#:DeleteSeries
RemoveSeries <br>
+
#:RemoveSeries
ClearSeries <br>
+
#:ClearSeries
CopyToClipboardBitmap <br>
+
#:CopyToClipboardBitmap
DisableRedrawing <br>
+
#:DisableRedrawing  
Draw <br>
+
#:Draw
DrawLegendOn <br>
+
#:DrawLegendOn
EnableRedrawing <br>
+
#:EnableRedrawing
PaintOnAuxCanvas <br>
+
#:PaintOnAuxCanvas
PaintOnCanvas <br>
+
#:PaintOnCanvas
Prepare <br>
+
#:Prepare
SaveToBitmapFile <br>
+
#:SaveToBitmapFile
SaveToFile <br>
+
#:SaveToFile
StyleChanged <br>
+
#:StyleChanged
ZoomFull <br>
+
#:ZoomFull
 
 
 
# [[#Properties_id|'''Properties''']]
 
# [[#Properties_id|'''Properties''']]
 
* [[#Published_prop_id|'''Published''']]
 
* [[#Published_prop_id|'''Published''']]
Align <br>
+
*: Align
Anchors <br>
+
*: Anchors
BorderSpacing <br>
+
*: BorderSpacing
Color <br>
+
*: Color
DoubleBuffered <br>
+
*: DoubleBuffered
DragCursor <br>
+
*: DragCursor
DragMode <br>
+
*: DragMode
Enabled <br>
+
*: Enabled
ParentColor <br>
+
*: ParentColor
ParentShowHint <br>
+
*: ParentShowHint
PopupMenu <br>
+
*: PopupMenu
ShowHint <br>
+
*: ShowHint
Visible <br>
+
*: Visible
 
+
*: Drawer
Drawer <br>
+
*: AutoFocus
AutoFocus <br>
+
*: AllowZoom
AllowZoom <br>
+
*: AntialiasingMode
AntialiasingMode <br>
+
*: AxisList
AxisList <br>
+
*: AxisVisible
AxisVisible <br>
+
*: BackColor
BackColor <br>
+
*: BottomAxis
BottomAxis <br>
+
*: Depth
Depth <br>
+
*: ExpandPercentage
ExpandPercentage <br>
+
*: Extent
Extent <br>
+
*: ExtentSizeLimit
ExtentSizeLimit <br>
+
*: Foot
Foot <br>
+
*: Frame
Frame <br>
+
*: GUIConnector
GUIConnector <br>
+
*: LeftAxis
LeftAxis <br>
+
*: Legend
Legend <br>
+
*: Margins
Margins <br>
+
*: MarginsExternal
MarginsExternal <br>
+
*: Proportional
Proportional <br>
+
*: ReticuleMode
ReticuleMode <br>
+
*: Series
Series <br>
+
*: Title
Title <br>
+
*: Toolset
Toolset <br>
 
 
* [[#Unpublished_prop_id|'''Unpublished''']]
 
* [[#Unpublished_prop_id|'''Unpublished''']]
 
ActiveToolIndex <br>
 
ActiveToolIndex <br>
Line 99: Line 97:
 
YGraphMin <br>
 
YGraphMin <br>
 
# [[#Events_id|'''Events''']]
 
# [[#Events_id|'''Events''']]
 +
OnAfterDraw <br>
 +
OnAfterDrawBackground <br>
 +
OnAfterDrawBackWall <br>
 +
OnAfterPaint <br>
 +
OnBeforeDrawBackground <br>
 +
OnBeforeDrawBackWall <br>
 +
OnDrawReticule <br>
 +
OnExtentChanged <br>
 +
OnExtentChanging <br>
 +
OnClick <br>
 +
OnDblClick <br>
 +
OnDragDrop <br>
 +
OnDragOver <br>
 +
OnEndDrag <br>
 +
OnMouseDown <br>
 +
OnMouseMove <br>
 +
OnMouseUp <br>
 +
OnStartDrag <br>
 +
 +
 
* [[#Methods_Public_id|'''Public Methods''']]
 
* [[#Methods_Public_id|'''Public Methods''']]
 
** [[#Functions_id|'''Functions''']]
 
** [[#Functions_id|'''Functions''']]
Line 114: Line 132:
 
** [[#Unpublished_prop_id|'''Published''']]
 
** [[#Unpublished_prop_id|'''Published''']]
 
* [[#Events_id|'''Events''']]
 
* [[#Events_id|'''Events''']]
 
 
<br><br><br>
 
  
 
   public // Helpers for series drawing
 
   public // Helpers for series drawing
    procedure DrawLineHoriz(ADrawer: IChartDrawer; AY: Integer);
 
    procedure DrawLineVert(ADrawer: IChartDrawer; AX: Integer);
 
    procedure DrawOnCanvas(Rect: TRect; ACanvas: TCanvas); deprecated;
 
    function IsPointInViewPort(const AP: TDoublePoint): Boolean;
 
 
  public
 
    property Drawer: IChartDrawer read FConnectorData.FDrawer;
 
 
  public // Coordinate conversion
 
    function GraphToImage(const AGraphPoint: TDoublePoint): TPoint;
 
    function ImageToGraph(const APoint: TPoint): TDoublePoint; overload;
 
    function ImageToGraph(const AX, AY: Integer): TDoublePoint; overload;
 
    function XGraphToImage(AX: Double): Integer; inline;
 
    function XImageToGraph(AX: Integer): Double; inline;
 
    function YGraphToImage(AY: Double): Integer; inline;
 
    function YImageToGraph(AY: Integer): Double; inline;
 
 
 
  published
 
 
  published
 
    property OnAfterDraw: TDrawEvent read FOnAfterDraw write SetOnAfterDraw;
 
    property OnAfterDrawBackground: TChartAfterDrawEvent
 
      read FOnAfterDrawBackground write SetOnAfterDrawBackground;
 
    property OnAfterDrawBackWall: TChartAfterDrawEvent
 
      read FOnAfterDrawBackWall write SetOnAfterDrawBackWall;
 
    property OnAfterPaint: TChartEvent read FOnAfterPaint write FOnAfterPaint;
 
    property OnBeforeDrawBackground: TChartBeforeDrawEvent
 
      read FOnBeforeDrawBackground write SetOnBeforeDrawBackground;
 
    property OnBeforeDrawBackWall: TChartBeforeDrawEvent
 
      read FOnBeforeDrawBackWall write SetOnBeforeDrawBackWall;
 
    property OnDrawReticule: TDrawReticuleEvent
 
      read FOnDrawReticule write SetOnDrawReticule;
 
    property OnExtentChanged: TChartEvent
 
      read FOnExtentChanged write FOnExtentChanged;
 
    property OnExtentChanging: TChartEvent
 
      read FOnExtentChanging write FOnExtentChanging;
 
 
  
  published
+
[[Category:Old or unknown pages]]
    property OnClick;
 
    property OnDblClick;
 
    property OnDragDrop;
 
    property OnDragOver;
 
    property OnEndDrag;
 
    property OnMouseDown;
 
    property OnMouseMove;
 
    property OnMouseUp;
 
    property OnStartDrag;
 

Latest revision as of 11:58, 2 February 2017

!! Under Construction... !!

The Chart is the component from where you control much of the behavior of your diagrams.

  • Public Methods
    Clone
    SaveToImage
    GetFullExtent
    GetLegendItems
    GraphToImage
    ImageToGraph
    XGraphToImage
    XImageToGraph
    YGraphToImage
    YImageToGraph
  1. IsPointInViewPort <F>
  2. EraseBackground

  3. Procedure GetChildren
  4. Procedure Paint
  5. Procedure SetChildOrder
  6. Procedure DrawLineHoriz
  7. Procedure DrawLineVert
  8. Procedure DrawOnCanvas
    AddSeries
    DeleteSeries
    RemoveSeries
    ClearSeries
    CopyToClipboardBitmap
    DisableRedrawing
    Draw
    DrawLegendOn
    EnableRedrawing
    PaintOnAuxCanvas
    PaintOnCanvas
    Prepare
    SaveToBitmapFile
    SaveToFile
    StyleChanged
    ZoomFull
  9. Properties
  • Published
    Align
    Anchors
    BorderSpacing
    Color
    DoubleBuffered
    DragCursor
    DragMode
    Enabled
    ParentColor
    ParentShowHint
    PopupMenu
    ShowHint
    Visible
    Drawer
    AutoFocus
    AllowZoom
    AntialiasingMode
    AxisList
    AxisVisible
    BackColor
    BottomAxis
    Depth
    ExpandPercentage
    Extent
    ExtentSizeLimit
    Foot
    Frame
    GUIConnector
    LeftAxis
    Legend
    Margins
    MarginsExternal
    Proportional
    ReticuleMode
    Series
    Title
    Toolset
  • Unpublished

ActiveToolIndex
Broadcaster
ChartHeight
ChartWidth
ClipRect
CurrentExtent
ExtentBroadcaster
IsZoomed
LogicalExtent
OnChartPaint
PrevLogicalExtent
RenderingParams
ReticulePos
SeriesCount
XGraphMax
XGraphMin
YGraphMax
YGraphMin

  1. Events

OnAfterDraw
OnAfterDrawBackground
OnAfterDrawBackWall
OnAfterPaint
OnBeforeDrawBackground
OnBeforeDrawBackWall
OnDrawReticule
OnExtentChanged
OnExtentChanging
OnClick
OnDblClick
OnDragDrop
OnDragOver
OnEndDrag
OnMouseDown
OnMouseMove
OnMouseUp
OnStartDrag


 public // Helpers for series drawing