lazarus/components/tachart/demo/axis/main.lfm

778 lines
23 KiB
Plaintext

object Form1: TForm1
Left = 343
Height = 430
Top = 184
Width = 533
Caption = 'TAChart axis demo'
ClientHeight = 430
ClientWidth = 533
OnCreate = FormCreate
Position = poScreenCenter
LCLVersion = '2.1.0.0'
object PageControl1: TPageControl
Left = 0
Height = 430
Top = 0
Width = 533
ActivePage = tsCustomMarks
Align = alClient
TabIndex = 0
TabOrder = 0
Options = [nboKeyboardTabSwitch]
object tsCustomMarks: TTabSheet
Caption = 'Customized marks'
ClientHeight = 402
ClientWidth = 525
object ChartCustomMarks: TChart
Left = 0
Height = 402
Top = 0
Width = 525
AxisList = <
item
TickLength = 0
Marks.Distance = 0
Marks.Format = '$%0:.9g'
Marks.Frame.Style = psSolid
Marks.LabelBrush.Color = clMoneyGreen
Marks.Source = lcsMarks
Marks.Style = smsCustom
Minors = <>
Title.LabelFont.Orientation = 900
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
TickLength = 0
Alignment = calBottom
AxisPen.Color = clGreen
AxisPen.Width = 3
AxisPen.Visible = True
Marks.LabelFont.Style = [fsBold]
Marks.Format = '%2:s'
Marks.LabelBrush.Style = bsClear
Marks.Source = lcsMarks
Marks.Style = smsLabel
Minors = <
item
Grid.Visible = False
Intervals.Count = 2
Intervals.MinLength = 5
Intervals.Options = [aipUseCount]
TickColor = clGreen
TickLength = 10
Marks.LabelBrush.Style = bsClear
end>
Title.LabelBrush.Style = bsClear
OnMarkToText = ChartCustomMarksAxisList1MarkToText
end>
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Frame.Visible = False
Margins.Left = 10
Margins.Top = 10
Margins.Right = 10
Margins.Bottom = 0
MarginsExternal.Left = 0
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'TAChart'
)
Align = alClient
object ChartCustomMarksBarSeries1: TBarSeries
BarBrush.Color = clGreen
BarPen.Color = clLime
BarPen.Width = 2
Marks.Frame.Visible = False
Marks.LabelBrush.Style = bsClear
Source = lcsMarks
end
end
end
object tsAxisGroup: TTabSheet
Caption = 'Axis groups'
ClientHeight = 402
ClientWidth = 525
object ChartAxisGroup: TChart
Left = 0
Height = 402
Top = 0
Width = 525
AxisList = <
item
Grid.Visible = False
TickLength = 0
Group = 2
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelFont.Orientation = 900
Title.LabelBrush.Style = bsClear
end
item
Alignment = calBottom
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelBrush.Style = bsClear
end>
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'TAChart'
)
Align = alClient
end
end
object tsSubmarks: TTabSheet
Caption = 'Submarks'
ClientHeight = 402
ClientWidth = 525
object ChartSubmarks: TChart
Left = 0
Height = 402
Top = 0
Width = 525
AxisList = <
item
TickLength = 6
Group = 1
Marks.LabelBrush.Style = bsClear
Marks.Source = udcsMain
Minors = <>
Title.LabelFont.Orientation = 900
Title.LabelBrush.Style = bsClear
end
item
Intervals.MaxLength = 100
Intervals.MinLength = 30
Intervals.NiceSteps = '0.2|0.25|0.5|1.0'
TickLength = 6
Alignment = calBottom
Group = 2
Marks.LabelFont.Style = [fsBold]
Marks.LabelBrush.Style = bsClear
Minors = <
item
Grid.Color = clGray
Grid.Cosmetic = False
Intervals.Count = 10
Intervals.MinLength = 5
Intervals.Options = [aipUseCount, aipUseMinLength]
Marks.Distance = 4
Marks.LabelFont.Height = -9
Marks.LabelFont.Orientation = 900
Marks.Format = '%0:.9g'
Marks.LabelBrush.Style = bsClear
Marks.Style = smsValue
end>
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
TickLength = 2
Group = 1
Marks.LabelBrush.Style = bsClear
Marks.Source = udcsSub
Marks.Style = smsNone
Minors = <>
Title.LabelBrush.Style = bsClear
end>
BackColor = clWhite
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'TAChart'
)
Align = alClient
object ChartSubmarksLineSeries1: TLineSeries
Source = udcsGraph
end
end
end
object tsDateTime: TTabSheet
Caption = 'Date and time'
ClientHeight = 402
ClientWidth = 525
object ChartDateTime: TChart
Left = 0
Height = 368
Top = 0
Width = 525
AxisList = <
item
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelFont.Orientation = 900
Title.LabelBrush.Style = bsClear
end
item
Alignment = calBottom
Marks.Format = '%2:s'
Marks.LabelBrush.Style = bsClear
Marks.OverlapPolicy = opHideNeighbour
Marks.Source = DateTimeIntervalChartSource1
Marks.Style = smsLabel
Minors = <>
Title.LabelBrush.Style = bsClear
end>
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'The series contain data points for every hour in 10 years'
'Left/right-click to zoom and see various labels on the bottom axis'
)
Title.Visible = True
Toolset = ChartToolsetDateTime
Align = alClient
object ChartDateTimeLineSeries1: TLineSeries
Source = rcsDates
end
end
object Panel1: TPanel
Left = 0
Height = 34
Top = 368
Width = 525
Align = alBottom
BevelOuter = bvNone
ClientHeight = 34
ClientWidth = 525
TabOrder = 1
object CbSuppressPrevUnit: TCheckBox
Left = 11
Height = 19
Top = 8
Width = 139
Caption = 'Suppress previous unit'
Checked = True
OnChange = CbSuppressPrevUnitChange
State = cbChecked
TabOrder = 0
end
object CbAlternateFormat: TCheckBox
Left = 195
Height = 19
Top = 8
Width = 145
Caption = 'Alternate format strings'
OnChange = CbAlternateFormatChange
TabOrder = 1
end
object Label1: TLabel
Left = 393
Height = 15
Top = 10
Width = 34
Caption = 'Label1'
ParentColor = False
end
end
end
object tsIntervals: TTabSheet
Caption = 'Intervals'
ClientHeight = 402
ClientWidth = 525
object ChartIntervals: TChart
Left = 0
Height = 402
Top = 0
Width = 525
AxisList = <
item
Grid.Visible = False
Intervals.NiceSteps = '0.25|1.0'
TickColor = clMaroon
TickLength = 3
AxisPen.Color = clMaroon
AxisPen.Visible = True
Marks.LabelFont.Color = clMaroon
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelFont.Color = clMaroon
Title.LabelFont.Orientation = 900
Title.Visible = True
Title.Caption = 'NiceSteps = 0.25'
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
Intervals.MinLength = 20
Intervals.NiceSteps = '0.3|0.6'
Alignment = calBottom
AxisPen.Visible = True
Marks.Format = '%0:.6g'
Marks.LabelBrush.Style = bsClear
Marks.Range.Max = 0.6
Marks.Range.Min = -0.3
Marks.Range.UseMax = True
Marks.Range.UseMin = True
Marks.Style = smsCustom
Minors = <>
Title.Visible = True
Title.Caption = 'Marks.Range = -0.3 .. 0.6'
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
Intervals.Count = 10
Intervals.MinLength = 4
Intervals.Options = [aipUseCount, aipUseMaxLength, aipUseMinLength, aipUseNiceSteps]
TickColor = clGreen
TickLength = 3
AxisPen.Color = clGreen
AxisPen.Visible = True
Margin = 8
Marks.LabelFont.Color = clGreen
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelFont.Color = clGreen
Title.LabelFont.Orientation = 900
Title.Visible = True
Title.Caption = 'MinLength = 4'
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
Intervals.MaxLength = 200
Intervals.Options = [aipUseCount, aipUseMaxLength, aipUseMinLength, aipUseNiceSteps]
TickColor = clNavy
TickLength = 3
AxisPen.Color = clNavy
AxisPen.Visible = True
Margin = 8
Marks.LabelFont.Color = clNavy
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelFont.Color = clNavy
Title.LabelFont.Orientation = 900
Title.Visible = True
Title.Caption = 'MaxLength = 200'
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
Intervals.Options = [aipUseMaxLength, aipUseMinLength]
TickLength = 3
AxisPen.Visible = True
Margin = 8
Marks.Format = '%0:.4g'
Marks.LabelBrush.Style = bsClear
Marks.Style = smsCustom
Minors = <>
Title.LabelFont.Orientation = 900
Title.Visible = True
Title.Caption = 'No nice steps'
Title.LabelBrush.Style = bsClear
end>
BackColor = clSilver
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Frame.Visible = False
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'TAChart'
)
Align = alClient
end
end
object tsPosition: TTabSheet
Caption = 'Position'
ClientHeight = 402
ClientWidth = 525
object ChartPosition: TChart
Left = 0
Height = 402
Top = 0
Width = 384
AxisList = <
item
Grid.Visible = False
Intervals.Tolerance = 1
AxisPen.Visible = True
Minors = <>
Position = 50
Title.LabelBrush.Style = bsClear
end
item
Grid.Visible = False
Intervals.Tolerance = 1
Alignment = calBottom
AxisPen.Visible = True
Minors = <>
Position = 50
Title.LabelBrush.Style = bsClear
end
item
Grid.Color = clGray
Intervals.Tolerance = 1
Visible = False
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelFont.Orientation = 900
Title.LabelBrush.Style = bsClear
end
item
Grid.Color = clGray
Intervals.Tolerance = 1
Visible = False
Alignment = calBottom
Marks.LabelBrush.Style = bsClear
Minors = <>
Title.LabelBrush.Style = bsClear
end>
BackColor = clWhite
Foot.Brush.Color = clBtnFace
Foot.Font.Color = clBlue
Title.Brush.Color = clBtnFace
Title.Font.Color = clBlue
Title.Text.Strings = (
'TAChart'
)
Align = alClient
Color = clWhite
object ChartPositionFuncSeries1: TFuncSeries
Extent.UseXMax = True
Extent.UseXMin = True
Extent.UseYMax = True
Extent.UseYMin = True
Extent.XMax = 100
Extent.XMin = -100
Extent.YMax = 30
Extent.YMin = -30
Pen.Color = clTeal
Pen.Width = 2
OnCalculate = ChartPositionFuncSeries1Calculate
end
end
object pnlPosition: TPanel
Left = 384
Height = 402
Top = 0
Width = 141
Align = alRight
ClientHeight = 402
ClientWidth = 141
TabOrder = 1
object gbPositionX: TGroupBox
Left = 1
Height = 124
Top = 1
Width = 139
Align = alTop
AutoSize = True
Caption = ' X axis '
ClientHeight = 104
ClientWidth = 135
TabOrder = 0
object seXPosition: TSpinEdit
AnchorSideLeft.Control = lblPositionX
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = gbPositionX
AnchorSideRight.Control = gbPositionX
AnchorSideRight.Side = asrBottom
Left = 62
Height = 23
Top = 0
Width = 65
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Left = 8
BorderSpacing.Right = 8
OnChange = seXPositionChange
TabOrder = 0
Value = 50
end
object lblPositionX: TLabel
AnchorSideLeft.Control = gbPositionX
AnchorSideTop.Control = seXPosition
AnchorSideTop.Side = asrCenter
Left = 8
Height = 15
Top = 4
Width = 46
BorderSpacing.Left = 8
Caption = 'Position:'
ParentColor = False
end
object cbStaticX: TCheckBox
AnchorSideLeft.Control = lblPositionX
AnchorSideTop.Control = cbUnitsX
AnchorSideTop.Side = asrBottom
Left = 8
Height = 19
Top = 54
Width = 103
BorderSpacing.Top = 4
Caption = 'Show static axis'
OnChange = cbStaticXChange
TabOrder = 1
end
object rbPositionBottom: TRadioButton
AnchorSideLeft.Control = lblPositionX
AnchorSideTop.Control = cbStaticX
AnchorSideTop.Side = asrBottom
Left = 8
Height = 19
Top = 77
Width = 60
BorderSpacing.Top = 4
BorderSpacing.Bottom = 8
Caption = 'Bottom'
Checked = True
OnChange = rbPositionBottomChange
TabOrder = 3
TabStop = True
end
object rbPositionTop: TRadioButton
AnchorSideLeft.Control = rbPositionBottom
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = rbPositionBottom
Left = 76
Height = 19
Top = 77
Width = 40
BorderSpacing.Left = 8
Caption = 'Top'
TabOrder = 2
end
object lblUnitsX: TLabel
AnchorSideLeft.Control = lblPositionX
AnchorSideTop.Control = cbUnitsX
AnchorSideTop.Side = asrCenter
Left = 8
Height = 15
Top = 31
Width = 30
Caption = 'Units:'
ParentColor = False
end
object cbUnitsX: TComboBox
AnchorSideLeft.Control = seXPosition
AnchorSideTop.Control = seXPosition
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = seXPosition
AnchorSideRight.Side = asrBottom
Left = 62
Height = 23
Top = 27
Width = 65
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 4
ItemHeight = 15
ItemIndex = 0
Items.Strings = (
'percent'
'axis'
'graph'
'pixel'
)
OnChange = cbUnitsXChange
Style = csDropDownList
TabOrder = 4
Text = 'percent'
end
end
object gbPositionY: TGroupBox
Left = 1
Height = 124
Top = 133
Width = 139
Align = alTop
AutoSize = True
BorderSpacing.Top = 8
Caption = ' Y axis '
ClientHeight = 104
ClientWidth = 135
TabOrder = 1
object lblPositionY: TLabel
AnchorSideLeft.Control = gbPositionY
AnchorSideTop.Control = seYPosition
AnchorSideTop.Side = asrCenter
Left = 8
Height = 15
Top = 4
Width = 46
BorderSpacing.Left = 8
Caption = 'Position:'
ParentColor = False
end
object cbStaticY: TCheckBox
AnchorSideLeft.Control = lblPositionY
AnchorSideTop.Control = cbUnitsY
AnchorSideTop.Side = asrBottom
Left = 8
Height = 19
Top = 54
Width = 103
BorderSpacing.Top = 4
Caption = 'Show static axis'
OnChange = cbStaticYChange
TabOrder = 0
end
object seYPosition: TSpinEdit
AnchorSideLeft.Control = lblPositionY
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = gbPositionY
AnchorSideRight.Control = gbPositionY
AnchorSideRight.Side = asrBottom
Left = 62
Height = 23
Top = 0
Width = 65
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Left = 8
BorderSpacing.Right = 8
OnChange = seYPositionChange
TabOrder = 1
Value = 50
end
object rbPositionRight: TRadioButton
AnchorSideLeft.Control = rbPositionLeft
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = rbPositionLeft
Left = 64
Height = 19
Top = 77
Width = 48
BorderSpacing.Left = 16
Caption = 'Right'
TabOrder = 2
end
object rbPositionLeft: TRadioButton
AnchorSideLeft.Control = lblPositionY
AnchorSideTop.Control = cbStaticY
AnchorSideTop.Side = asrBottom
Left = 8
Height = 19
Top = 77
Width = 40
BorderSpacing.Top = 4
BorderSpacing.Bottom = 8
Caption = 'Left'
Checked = True
OnChange = rbPositionLeftChange
TabOrder = 3
TabStop = True
end
object cbUnitsY: TComboBox
AnchorSideLeft.Control = seYPosition
AnchorSideTop.Control = seYPosition
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = seYPosition
AnchorSideRight.Side = asrBottom
Left = 62
Height = 23
Top = 27
Width = 65
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 4
ItemHeight = 15
ItemIndex = 0
Items.Strings = (
'percent'
'graph'
'pixel'
)
OnChange = cbUnitsYChange
Style = csDropDownList
TabOrder = 4
Text = 'percent'
end
object lblUnitsY: TLabel
AnchorSideLeft.Control = lblPositionY
AnchorSideTop.Control = cbUnitsY
AnchorSideTop.Side = asrCenter
Left = 8
Height = 15
Top = 31
Width = 30
Caption = 'Units:'
ParentColor = False
end
end
end
end
end
object lcsMarks: TListChartSource
DataPoints.Strings = (
'1|18000|?|January'
'2|35000|?|February'
'3|31000|?|March'
'4|26000|?|April'
'5|37000|?|May'
'6|22000|?|June'
)
left = 216
top = 164
end
object rcsDates: TRandomChartSource
RandSeed = 1079653020
XMax = 0
XMin = 0
YMax = 50
YMin = 5
left = 216
top = 216
end
object DateTimeIntervalChartSource1: TDateTimeIntervalChartSource
Params.Count = 10
Params.MaxLength = 150
Params.MinLength = 20
Params.Options = [aipUseCount, aipUseMaxLength, aipUseMinLength, aipUseNiceSteps]
OnDateTimeStepChange = DateTimeIntervalChartSource1DateTimeStepChange
left = 248
top = 320
end
object ChartToolsetDateTime: TChartToolset
left = 448
top = 320
object ChartToolset1ZoomIn: TZoomClickTool
Shift = [ssLeft]
ZoomFactor = 4
ZoomRatio = 0.25
end
object ChartToolset1ZoomOut: TZoomClickTool
Shift = [ssRight]
ZoomFactor = 0.25
ZoomRatio = 4
end
end
object udcsMain: TUserDefinedChartSource
OnGetChartDataItem = udcsMainGetChartDataItem
PointsNumber = 10
left = 344
top = 72
end
object udcsSub: TUserDefinedChartSource
OnGetChartDataItem = udcsSubGetChartDataItem
PointsNumber = 50
left = 344
top = 116
end
object udcsGraph: TUserDefinedChartSource
OnGetChartDataItem = udcsGraphGetChartDataItem
PointsNumber = 100
left = 352
top = 184
end
object csStripes: TChartStyles
Styles = <
item
Brush.Color = 16631498
UsePen = False
end
item
Brush.Color = 12319483
UsePen = False
end>
left = 304
top = 176
end
end