1object Form1: TForm1
2  Left = 343
3  Height = 430
4  Top = 184
5  Width = 533
6  Caption = 'TAChart axis demo'
7  ClientHeight = 430
8  ClientWidth = 533
9  OnCreate = FormCreate
10  Position = poScreenCenter
11  LCLVersion = '1.7'
12  object PageControl1: TPageControl
13    Left = 0
14    Height = 430
15    Top = 0
16    Width = 533
17    ActivePage = tsCustomMarks
18    Align = alClient
19    TabIndex = 0
20    TabOrder = 0
21    Options = [nboKeyboardTabSwitch]
22    object tsCustomMarks: TTabSheet
23      Caption = 'Customized marks'
24      ClientHeight = 402
25      ClientWidth = 525
26      object ChartCustomMarks: TChart
27        Left = 0
28        Height = 402
29        Top = 0
30        Width = 525
31        AxisList = <
32          item
33            TickLength = 0
34            Marks.Distance = 0
35            Marks.Format = '$%0:.9g'
36            Marks.Frame.Style = psSolid
37            Marks.LabelBrush.Color = clMoneyGreen
38            Marks.LabelBrush.Style = bsSolid
39            Marks.Source = lcsMarks
40            Marks.Style = smsCustom
41            Minors = <>
42            Title.LabelFont.Orientation = 900
43          end
44          item
45            Grid.Visible = False
46            TickLength = 0
47            Alignment = calBottom
48            AxisPen.Color = clGreen
49            AxisPen.Width = 3
50            AxisPen.Visible = True
51            Marks.LabelFont.Height = -13
52            Marks.LabelFont.Style = [fsBold]
53            Marks.Format = '%2:s'
54            Marks.Source = lcsMarks
55            Marks.Style = smsLabel
56            Minors = <
57              item
58                Grid.Visible = False
59                Intervals.Count = 2
60                Intervals.MinLength = 5
61                Intervals.Options = [aipUseCount]
62                TickColor = clGreen
63                TickLength = 10
64              end>
65            OnMarkToText = ChartCustomMarksAxisList1MarkToText
66          end>
67        Foot.Brush.Color = clBtnFace
68        Foot.Font.Color = clBlue
69        Frame.Visible = False
70        Margins.Left = 10
71        Margins.Top = 10
72        Margins.Right = 10
73        Margins.Bottom = 0
74        MarginsExternal.Left = 0
75        Title.Brush.Color = clBtnFace
76        Title.Font.Color = clBlue
77        Title.Text.Strings = (
78          'TAChart'
79        )
80        Align = alClient
81        object ChartCustomMarksBarSeries1: TBarSeries
82          Marks.Frame.Visible = False
83          Marks.LabelBrush.Style = bsClear
84          BarBrush.Color = clGreen
85          BarPen.Color = clLime
86          BarPen.Width = 2
87          Source = lcsMarks
88        end
89      end
90    end
91    object tsAxisGroup: TTabSheet
92      Caption = 'Axis groups'
93      ClientHeight = 404
94      ClientWidth = 525
95      object ChartAxisGroup: TChart
96        Left = 0
97        Height = 404
98        Top = 0
99        Width = 525
100        AxisList = <
101          item
102            Grid.Visible = False
103            TickLength = 0
104            Group = 2
105            Minors = <>
106            Title.LabelFont.Orientation = 900
107          end
108          item
109            Alignment = calBottom
110            Minors = <>
111          end>
112        Foot.Brush.Color = clBtnFace
113        Foot.Font.Color = clBlue
114        Title.Brush.Color = clBtnFace
115        Title.Font.Color = clBlue
116        Title.Text.Strings = (
117          'TAChart'
118        )
119        Align = alClient
120      end
121    end
122    object tsSubmarks: TTabSheet
123      Caption = 'Submarks'
124      ClientHeight = 404
125      ClientWidth = 525
126      object ChartSubmarks: TChart
127        Left = 0
128        Height = 404
129        Top = 0
130        Width = 525
131        AxisList = <
132          item
133            TickLength = 6
134            Group = 1
135            Marks.Source = udcsMain
136            Minors = <>
137            Title.LabelFont.Orientation = 900
138          end
139          item
140            Intervals.MaxLength = 100
141            Intervals.MinLength = 30
142            Intervals.NiceSteps = '0.2|0.25|0.5|1.0'
143            TickLength = 6
144            Alignment = calBottom
145            Group = 2
146            Marks.LabelFont.Style = [fsBold]
147            Minors = <
148              item
149                Grid.Color = clGray
150                Grid.Cosmetic = False
151                Intervals.Count = 10
152                Intervals.MinLength = 5
153                Intervals.Options = [aipUseCount, aipUseMinLength]
154                Marks.Distance = 4
155                Marks.LabelFont.Height = -9
156                Marks.LabelFont.Orientation = 900
157                Marks.Format = '%0:.9g'
158                Marks.Style = smsValue
159              end>
160          end
161          item
162            Grid.Visible = False
163            TickLength = 2
164            Group = 1
165            Marks.Source = udcsSub
166            Marks.Style = smsNone
167            Minors = <>
168          end>
169        BackColor = clWhite
170        Foot.Brush.Color = clBtnFace
171        Foot.Font.Color = clBlue
172        Title.Brush.Color = clBtnFace
173        Title.Font.Color = clBlue
174        Title.Text.Strings = (
175          'TAChart'
176        )
177        Align = alClient
178        object ChartSubmarksLineSeries1: TLineSeries
179          Source = udcsGraph
180        end
181      end
182    end
183    object tsDateTime: TTabSheet
184      Caption = 'Date and time'
185      ClientHeight = 402
186      ClientWidth = 525
187      object ChartDateTime: TChart
188        Left = 0
189        Height = 368
190        Top = 0
191        Width = 525
192        AxisList = <
193          item
194            Minors = <>
195            Title.LabelFont.Orientation = 900
196          end
197          item
198            Alignment = calBottom
199            Marks.Format = '%2:s'
200            Marks.OverlapPolicy = opHideNeighbour
201            Marks.Source = DateTimeIntervalChartSource1
202            Marks.Style = smsLabel
203            Minors = <>
204          end>
205        Foot.Brush.Color = clBtnFace
206        Foot.Font.Color = clBlue
207        Title.Brush.Color = clBtnFace
208        Title.Font.Color = clBlue
209        Title.Text.Strings = (
210          'The series contain data points for every hour in 10 years'
211          'Left/right-click to zoom and see various labels on the bottom axis'
212        )
213        Title.Visible = True
214        Toolset = ChartToolsetDateTime
215        Align = alClient
216        object ChartDateTimeLineSeries1: TLineSeries
217          Source = rcsDates
218        end
219      end
220      object Panel1: TPanel
221        Left = 0
222        Height = 34
223        Top = 368
224        Width = 525
225        Align = alBottom
226        BevelOuter = bvNone
227        ClientHeight = 34
228        ClientWidth = 525
229        TabOrder = 1
230        object CbSuppressPrevUnit: TCheckBox
231          Left = 11
232          Height = 19
233          Top = 8
234          Width = 139
235          Caption = 'Suppress previous unit'
236          Checked = True
237          OnChange = CbSuppressPrevUnitChange
238          State = cbChecked
239          TabOrder = 0
240        end
241        object CbAlternateFormat: TCheckBox
242          Left = 195
243          Height = 19
244          Top = 8
245          Width = 145
246          Caption = 'Alternate format strings'
247          OnChange = CbAlternateFormatChange
248          TabOrder = 1
249        end
250        object Label1: TLabel
251          Left = 393
252          Height = 15
253          Top = 10
254          Width = 34
255          Caption = 'Label1'
256          ParentColor = False
257        end
258      end
259    end
260    object tsIntervals: TTabSheet
261      Caption = 'Intervals'
262      ClientHeight = 404
263      ClientWidth = 525
264      object ChartIntervals: TChart
265        Left = 0
266        Height = 404
267        Top = 0
268        Width = 525
269        AxisList = <
270          item
271            Grid.Visible = False
272            Intervals.NiceSteps = '0.25|1.0'
273            TickColor = clMaroon
274            TickLength = 3
275            AxisPen.Color = clMaroon
276            AxisPen.Visible = True
277            Marks.LabelFont.Color = clMaroon
278            Minors = <>
279            Title.LabelFont.Color = clMaroon
280            Title.LabelFont.Orientation = 900
281            Title.Visible = True
282            Title.Caption = 'NiceSteps = 0.25'
283          end
284          item
285            Grid.Visible = False
286            Intervals.MinLength = 20
287            Intervals.NiceSteps = '0.3|0.6'
288            Alignment = calBottom
289            AxisPen.Visible = True
290            Marks.Format = '%0:.6g'
291            Marks.Range.Max = 0.6
292            Marks.Range.Min = -0.3
293            Marks.Range.UseMax = True
294            Marks.Range.UseMin = True
295            Marks.Style = smsCustom
296            Minors = <>
297            Title.Visible = True
298            Title.Caption = 'Marks.Range = -0.3 .. 0.6'
299          end
300          item
301            Grid.Visible = False
302            Intervals.Count = 10
303            Intervals.MinLength = 4
304            Intervals.Options = [aipUseCount, aipUseMaxLength, aipUseMinLength, aipUseNiceSteps]
305            TickColor = clGreen
306            TickLength = 3
307            AxisPen.Color = clGreen
308            AxisPen.Visible = True
309            Margin = 8
310            Marks.LabelFont.Color = clGreen
311            Minors = <>
312            Title.LabelFont.Color = clGreen
313            Title.LabelFont.Orientation = 900
314            Title.Visible = True
315            Title.Caption = 'MinLength = 4'
316          end
317          item
318            Grid.Visible = False
319            Intervals.MaxLength = 200
320            Intervals.Options = [aipUseCount, aipUseMaxLength, aipUseMinLength, aipUseNiceSteps]
321            TickColor = clNavy
322            TickLength = 3
323            AxisPen.Color = clNavy
324            AxisPen.Visible = True
325            Margin = 8
326            Marks.LabelFont.Color = clNavy
327            Minors = <>
328            Title.LabelFont.Color = clNavy
329            Title.LabelFont.Orientation = 900
330            Title.Visible = True
331            Title.Caption = 'MaxLength = 200'
332          end
333          item
334            Grid.Visible = False
335            Intervals.Options = [aipUseMaxLength, aipUseMinLength]
336            TickLength = 3
337            AxisPen.Visible = True
338            Margin = 8
339            Marks.Format = '%0:.4g'
340            Marks.Style = smsCustom
341            Minors = <>
342            Title.LabelFont.Orientation = 900
343            Title.Visible = True
344            Title.Caption = 'No nice steps'
345          end>
346        BackColor = clSilver
347        Foot.Brush.Color = clBtnFace
348        Foot.Font.Color = clBlue
349        Frame.Visible = False
350        Title.Brush.Color = clBtnFace
351        Title.Font.Color = clBlue
352        Title.Text.Strings = (
353          'TAChart'
354        )
355        Align = alClient
356      end
357    end
358    object tsPosition: TTabSheet
359      Caption = 'Position'
360      ClientHeight = 404
361      ClientWidth = 525
362      object ChartPosition: TChart
363        Left = 0
364        Height = 404
365        Top = 0
366        Width = 395
367        AxisList = <
368          item
369            Grid.Visible = False
370            Intervals.Tolerance = 1
371            AxisPen.Visible = True
372            Marks.LabelBrush.Style = bsSolid
373            Minors = <>
374            Position = 50
375          end
376          item
377            Grid.Visible = False
378            Intervals.Tolerance = 1
379            Alignment = calBottom
380            AxisPen.Visible = True
381            Marks.LabelBrush.Style = bsSolid
382            Minors = <>
383            Position = 50
384          end
385          item
386            Grid.Color = clGray
387            Intervals.Tolerance = 1
388            Visible = False
389            Minors = <>
390            Title.LabelFont.Orientation = 900
391          end
392          item
393            Grid.Color = clGray
394            Intervals.Tolerance = 1
395            Visible = False
396            Alignment = calBottom
397            Minors = <>
398          end>
399        BackColor = clWhite
400        Foot.Brush.Color = clBtnFace
401        Foot.Font.Color = clBlue
402        Title.Brush.Color = clBtnFace
403        Title.Font.Color = clBlue
404        Title.Text.Strings = (
405          'TAChart'
406        )
407        Align = alClient
408        Color = clWhite
409        object ChartPositionFuncSeries1: TFuncSeries
410          Extent.UseXMax = True
411          Extent.UseXMin = True
412          Extent.UseYMax = True
413          Extent.UseYMin = True
414          Extent.XMax = 100
415          Extent.XMin = -100
416          Extent.YMax = 30
417          Extent.YMin = -30
418          OnCalculate = ChartPositionFuncSeries1Calculate
419          Pen.Color = clTeal
420          Pen.Width = 2
421        end
422      end
423      object pnlPosition: TPanel
424        Left = 395
425        Height = 404
426        Top = 0
427        Width = 130
428        Align = alRight
429        ClientHeight = 404
430        ClientWidth = 130
431        TabOrder = 1
432        object gbPositionX: TGroupBox
433          Left = 1
434          Height = 121
435          Top = 1
436          Width = 128
437          Align = alTop
438          Caption = ' X axis '
439          ClientHeight = 101
440          ClientWidth = 124
441          TabOrder = 0
442          object seXPosition: TSpinEdit
443            Left = 57
444            Height = 21
445            Top = 1
446            Width = 58
447            OnChange = seXPositionChange
448            TabOrder = 0
449            Value = 50
450          end
451          object lblPositionX: TLabel
452            Left = 6
453            Height = 13
454            Top = 5
455            Width = 41
456            Caption = 'Position:'
457            ParentColor = False
458          end
459          object cbStaticX: TCheckBox
460            Left = 6
461            Height = 17
462            Top = 53
463            Width = 97
464            Caption = 'Show static axis'
465            OnChange = cbStaticXChange
466            TabOrder = 1
467          end
468          object rbPositionBottom: TRadioButton
469            Left = 6
470            Height = 17
471            Top = 77
472            Width = 54
473            Caption = 'Bottom'
474            Checked = True
475            OnChange = rbPositionBottomChange
476            TabOrder = 3
477            TabStop = True
478          end
479          object rbPositionTop: TRadioButton
480            Left = 70
481            Height = 17
482            Top = 77
483            Width = 38
484            Caption = 'Top'
485            TabOrder = 2
486          end
487          object lblUnitsX: TLabel
488            Left = 6
489            Height = 13
490            Top = 33
491            Width = 28
492            Caption = 'Units:'
493            ParentColor = False
494          end
495          object cbUnitsX: TComboBox
496            Left = 54
497            Height = 23
498            Top = 29
499            Width = 60
500            ItemHeight = 15
501            ItemIndex = 0
502            Items.Strings = (
503              'percent'
504              'axis'
505              'graph'
506              'pixel'
507            )
508            OnChange = cbUnitsXChange
509            Style = csDropDownList
510            TabOrder = 4
511            Text = 'percent'
512          end
513        end
514        object gbPositionY: TGroupBox
515          Left = 1
516          Height = 124
517          Top = 122
518          Width = 128
519          Align = alTop
520          Caption = ' Y axis '
521          ClientHeight = 104
522          ClientWidth = 124
523          TabOrder = 1
524          object lblPositionY: TLabel
525            Left = 6
526            Height = 13
527            Top = 4
528            Width = 41
529            Caption = 'Position:'
530            ParentColor = False
531          end
532          object cbStaticY: TCheckBox
533            Left = 6
534            Height = 17
535            Top = 56
536            Width = 97
537            Caption = 'Show static axis'
538            OnChange = cbStaticYChange
539            TabOrder = 0
540          end
541          object seYPosition: TSpinEdit
542            Left = 57
543            Height = 21
544            Top = 0
545            Width = 58
546            OnChange = seYPositionChange
547            TabOrder = 1
548            Value = 50
549          end
550          object rbPositionRight: TRadioButton
551            Left = 70
552            Height = 17
553            Top = 84
554            Width = 45
555            Caption = 'Right'
556            TabOrder = 2
557          end
558          object rbPositionLeft: TRadioButton
559            Left = 6
560            Height = 17
561            Top = 84
562            Width = 39
563            Caption = 'Left'
564            Checked = True
565            OnChange = rbPositionLeftChange
566            TabOrder = 3
567            TabStop = True
568          end
569          object cbUnitsY: TComboBox
570            Left = 54
571            Height = 23
572            Top = 29
573            Width = 60
574            ItemHeight = 15
575            ItemIndex = 0
576            Items.Strings = (
577              'percent'
578              'graph'
579              'pixel'
580            )
581            OnChange = cbUnitsYChange
582            Style = csDropDownList
583            TabOrder = 4
584            Text = 'percent'
585          end
586          object lblUnitsY: TLabel
587            Left = 6
588            Height = 13
589            Top = 33
590            Width = 28
591            Caption = 'Units:'
592            ParentColor = False
593          end
594        end
595      end
596    end
597  end
598  object lcsMarks: TListChartSource
599    DataPoints.Strings = (
600      '1|18000|?|January'
601      '2|35000|?|February'
602      '3|31000|?|March'
603      '4|26000|?|April'
604      '5|37000|?|May'
605      '6|22000|?|June'
606    )
607    left = 216
608    top = 164
609  end
610  object rcsDates: TRandomChartSource
611    RandSeed = 1079653020
612    XMax = 0
613    XMin = 0
614    YMax = 50
615    YMin = 5
616    left = 216
617    top = 216
618  end
619  object DateTimeIntervalChartSource1: TDateTimeIntervalChartSource
620    Params.Count = 10
621    Params.MaxLength = 150
622    Params.MinLength = 20
623    Params.Options = [aipUseCount, aipUseMaxLength, aipUseMinLength, aipUseNiceSteps]
624    OnDateTimeStepChange = DateTimeIntervalChartSource1DateTimeStepChange
625    left = 352
626    top = 232
627  end
628  object ChartToolsetDateTime: TChartToolset
629    left = 440
630    top = 232
631    object ChartToolset1ZoomIn: TZoomClickTool
632      Shift = [ssLeft]
633      ZoomFactor = 4
634      ZoomRatio = 0.25
635    end
636    object ChartToolset1ZoomOut: TZoomClickTool
637      Shift = [ssRight]
638      ZoomFactor = 0.25
639      ZoomRatio = 4
640    end
641  end
642  object udcsMain: TUserDefinedChartSource
643    OnGetChartDataItem = udcsMainGetChartDataItem
644    PointsNumber = 10
645    left = 440
646    top = 60
647  end
648  object udcsSub: TUserDefinedChartSource
649    OnGetChartDataItem = udcsSubGetChartDataItem
650    PointsNumber = 50
651    left = 440
652    top = 116
653  end
654  object udcsGraph: TUserDefinedChartSource
655    OnGetChartDataItem = udcsGraphGetChartDataItem
656    PointsNumber = 100
657    left = 440
658    top = 172
659  end
660  object csStripes: TChartStyles
661    Styles = <
662      item
663        Brush.Color = 16631498
664        UsePen = False
665      end
666      item
667        Brush.Color = 12319483
668        UsePen = False
669      end>
670    left = 352
671    top = 176
672  end
673end
674