mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 01:39:25 +02:00
TAChart: Refactor charteditor demo.
git-svn-id: trunk@65025 -
This commit is contained in:
parent
a2f76da804
commit
67a1d35c1a
@ -1,12 +1,13 @@
|
|||||||
object AxisEditor: TAxisEditor
|
object AxisEditor: TAxisEditor
|
||||||
Left = 662
|
Left = 931
|
||||||
Height = 487
|
Height = 524
|
||||||
Top = 270
|
Top = 284
|
||||||
Width = 548
|
Width = 535
|
||||||
ActiveControl = cbShow
|
ActiveControl = cbShow
|
||||||
Caption = 'Axis title editor'
|
Caption = 'Axis title editor'
|
||||||
ClientHeight = 487
|
ClientHeight = 524
|
||||||
ClientWidth = 548
|
ClientWidth = 535
|
||||||
|
OnActivate = FormActivate
|
||||||
OnCloseQuery = FormCloseQuery
|
OnCloseQuery = FormCloseQuery
|
||||||
OnCreate = FormCreate
|
OnCreate = FormCreate
|
||||||
OnDestroy = FormDestroy
|
OnDestroy = FormDestroy
|
||||||
@ -16,29 +17,29 @@ object AxisEditor: TAxisEditor
|
|||||||
object PageControl: TPageControl
|
object PageControl: TPageControl
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 408
|
Height = 445
|
||||||
Top = 33
|
Top = 33
|
||||||
Width = 536
|
Width = 523
|
||||||
ActivePage = pgTitle
|
ActivePage = pgGrid
|
||||||
Align = alClient
|
Align = alClient
|
||||||
BorderSpacing.Left = 6
|
BorderSpacing.Left = 6
|
||||||
BorderSpacing.Right = 6
|
BorderSpacing.Right = 6
|
||||||
TabIndex = 0
|
TabIndex = 2
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object pgTitle: TTabSheet
|
object pgTitle: TTabSheet
|
||||||
Caption = 'Title'
|
Caption = 'Title'
|
||||||
ClientHeight = 380
|
ClientHeight = 417
|
||||||
ClientWidth = 528
|
ClientWidth = 515
|
||||||
object TitleMemoPanel: TPanel
|
object TitleMemoPanel: TPanel
|
||||||
Left = 6
|
Left = 8
|
||||||
Height = 159
|
Height = 190
|
||||||
Top = 6
|
Top = 8
|
||||||
Width = 516
|
Width = 499
|
||||||
Align = alClient
|
Align = alClient
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 8
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 159
|
ClientHeight = 190
|
||||||
ClientWidth = 516
|
ClientWidth = 499
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object lblTitle: TLabel
|
object lblTitle: TLabel
|
||||||
AnchorSideLeft.Control = TitleMemoPanel
|
AnchorSideLeft.Control = TitleMemoPanel
|
||||||
@ -60,9 +61,9 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideBottom.Control = TitleMemoPanel
|
AnchorSideBottom.Control = TitleMemoPanel
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 138
|
Height = 169
|
||||||
Top = 21
|
Top = 21
|
||||||
Width = 516
|
Width = 499
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
BorderSpacing.Top = 4
|
BorderSpacing.Top = 4
|
||||||
OnChange = mmoTitleChange
|
OnChange = mmoTitleChange
|
||||||
@ -74,7 +75,7 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
AnchorSideRight.Control = TitleMemoPanel
|
AnchorSideRight.Control = TitleMemoPanel
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 462
|
Left = 445
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 54
|
Width = 54
|
||||||
@ -88,15 +89,15 @@ object AxisEditor: TAxisEditor
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
object TitleParamsPanel: TPanel
|
object TitleParamsPanel: TPanel
|
||||||
Left = 6
|
Left = 8
|
||||||
Height = 203
|
Height = 203
|
||||||
Top = 171
|
Top = 206
|
||||||
Width = 516
|
Width = 499
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 8
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 203
|
ClientHeight = 203
|
||||||
ClientWidth = 516
|
ClientWidth = 499
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object rgTitleAlignment: TRadioGroup
|
object rgTitleAlignment: TRadioGroup
|
||||||
AnchorSideLeft.Control = TitleParamsPanel
|
AnchorSideLeft.Control = TitleParamsPanel
|
||||||
@ -106,12 +107,13 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 0
|
Left = 0
|
||||||
Height = 51
|
Height = 51
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 249
|
Width = 240
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
AutoFill = True
|
AutoFill = True
|
||||||
BorderSpacing.InnerBorder = 6
|
AutoSize = True
|
||||||
Caption = 'Alignment'
|
Caption = 'Alignment'
|
||||||
ChildSizing.LeftRightSpacing = 6
|
ChildSizing.LeftRightSpacing = 16
|
||||||
|
ChildSizing.TopBottomSpacing = 6
|
||||||
ChildSizing.HorizontalSpacing = 16
|
ChildSizing.HorizontalSpacing = 16
|
||||||
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
||||||
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
||||||
@ -120,7 +122,7 @@ object AxisEditor: TAxisEditor
|
|||||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||||
ChildSizing.ControlsPerLine = 3
|
ChildSizing.ControlsPerLine = 3
|
||||||
ClientHeight = 31
|
ClientHeight = 31
|
||||||
ClientWidth = 245
|
ClientWidth = 236
|
||||||
Columns = 3
|
Columns = 3
|
||||||
ItemIndex = 0
|
ItemIndex = 0
|
||||||
Items.Strings = (
|
Items.Strings = (
|
||||||
@ -139,38 +141,11 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 0
|
Left = 0
|
||||||
Height = 104
|
Height = 104
|
||||||
Top = 59
|
Top = 59
|
||||||
Width = 249
|
Width = 240
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Font'
|
Caption = 'gbTitleFont'
|
||||||
ClientHeight = 84
|
|
||||||
ClientWidth = 245
|
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
inline TitleFontFrame: TFontFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 76
|
|
||||||
Width = 229
|
|
||||||
Align = alClient
|
|
||||||
Anchors = [akTop, akLeft, akRight]
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
ClientHeight = 76
|
|
||||||
ClientWidth = 229
|
|
||||||
inherited cmbFontName: TComboBox
|
|
||||||
AnchorSideLeft.Control = TitleFontFrame
|
|
||||||
AnchorSideTop.Control = TitleFontFrame
|
|
||||||
AnchorSideRight.Control = TitleFontFrame
|
|
||||||
Width = 229
|
|
||||||
end
|
|
||||||
inherited cbFontColor: TColorButton
|
|
||||||
AnchorSideRight.Control = TitleFontFrame
|
|
||||||
Left = 197
|
|
||||||
end
|
|
||||||
inherited cbBold: TCheckBox
|
|
||||||
AnchorSideLeft.Control = TitleFontFrame
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
object gbTitleShapeBrushPenMargins: TGroupBox
|
object gbTitleShapeBrushPenMargins: TGroupBox
|
||||||
AnchorSideLeft.Control = Bevel1
|
AnchorSideLeft.Control = Bevel1
|
||||||
@ -178,59 +153,19 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideTop.Control = rgTitleAlignment
|
AnchorSideTop.Control = rgTitleAlignment
|
||||||
AnchorSideRight.Control = TitleParamsPanel
|
AnchorSideRight.Control = TitleParamsPanel
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
AnchorSideBottom.Control = TitleParamsPanel
|
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 267
|
Left = 258
|
||||||
Height = 203
|
Height = 163
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 249
|
Width = 241
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
Caption = 'Title background'
|
Caption = 'gbTitleShapeBrushPenMargins'
|
||||||
ClientHeight = 183
|
|
||||||
ClientWidth = 245
|
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
inline TitleShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 175
|
|
||||||
Align = alClient
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
ClientHeight = 175
|
|
||||||
inherited cmbShape: TComboBox
|
|
||||||
AnchorSideLeft.Control = TitleShapeBrushPenMarginsFrame
|
|
||||||
AnchorSideTop.Control = TitleShapeBrushPenMarginsFrame
|
|
||||||
AnchorSideRight.Control = TitleShapeBrushPenMarginsFrame
|
|
||||||
end
|
|
||||||
inherited gbBackground: TGroupBox
|
|
||||||
AnchorSideLeft.Control = TitleShapeBrushPenMarginsFrame
|
|
||||||
end
|
|
||||||
inherited gbBorder: TGroupBox
|
|
||||||
AnchorSideRight.Control = TitleShapeBrushPenMarginsFrame
|
|
||||||
end
|
|
||||||
inherited gbMargins: TGroupBox
|
|
||||||
AnchorSideBottom.Control = TitleShapeBrushPenMarginsFrame
|
|
||||||
Height = 83
|
|
||||||
ClientHeight = 63
|
|
||||||
inherited seBottomMargin: TSpinEdit
|
|
||||||
Top = 32
|
|
||||||
end
|
|
||||||
inherited seLeftMargin: TSpinEdit
|
|
||||||
Top = 16
|
|
||||||
end
|
|
||||||
inherited seRightMargin: TSpinEdit
|
|
||||||
Top = 16
|
|
||||||
end
|
|
||||||
inherited Bevel2: TBevel
|
|
||||||
Height = 1
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
object Bevel1: TBevel
|
object Bevel1: TBevel
|
||||||
AnchorSideLeft.Control = TitleParamsPanel
|
AnchorSideLeft.Control = TitleParamsPanel
|
||||||
AnchorSideLeft.Side = asrCenter
|
AnchorSideLeft.Side = asrCenter
|
||||||
Left = 249
|
Left = 240
|
||||||
Height = 50
|
Height = 50
|
||||||
Top = 32
|
Top = 32
|
||||||
Width = 18
|
Width = 18
|
||||||
@ -242,21 +177,24 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 15
|
Height = 15
|
||||||
Top = 175
|
Top = 183
|
||||||
Width = 45
|
Width = 45
|
||||||
Caption = 'Distance'
|
Caption = 'Distance'
|
||||||
FocusControl = seTitleDistance
|
FocusControl = seTitleDistance
|
||||||
ParentColor = False
|
ParentColor = False
|
||||||
end
|
end
|
||||||
object seTitleDistance: TSpinEdit
|
object seTitleDistance: TSpinEdit
|
||||||
|
AnchorSideLeft.Control = lblTitleDistance
|
||||||
|
AnchorSideLeft.Side = asrBottom
|
||||||
AnchorSideTop.Control = gbTitleFont
|
AnchorSideTop.Control = gbTitleFont
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 72
|
Left = 53
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 171
|
Top = 179
|
||||||
Width = 58
|
Width = 58
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Left = 8
|
||||||
|
BorderSpacing.Top = 16
|
||||||
OnChange = seTitleDistanceChange
|
OnChange = seTitleDistanceChange
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
end
|
end
|
||||||
@ -264,23 +202,23 @@ object AxisEditor: TAxisEditor
|
|||||||
end
|
end
|
||||||
object pgLabels: TTabSheet
|
object pgLabels: TTabSheet
|
||||||
Caption = 'Labels'
|
Caption = 'Labels'
|
||||||
ClientHeight = 380
|
ClientHeight = 417
|
||||||
ClientWidth = 540
|
ClientWidth = 515
|
||||||
object gbAxisRange: TGroupBox
|
object gbAxisRange: TGroupBox
|
||||||
AnchorSideLeft.Control = pgLabels
|
AnchorSideLeft.Control = pgLabels
|
||||||
AnchorSideTop.Control = pgLabels
|
AnchorSideTop.Control = pgLabels
|
||||||
AnchorSideRight.Control = Bevel2
|
AnchorSideRight.Control = Bevel2
|
||||||
Left = 6
|
Left = 8
|
||||||
Height = 150
|
Height = 150
|
||||||
Top = 6
|
Top = 8
|
||||||
Width = 256
|
Width = 241
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Left = 6
|
BorderSpacing.Left = 8
|
||||||
BorderSpacing.Top = 6
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Axis limits'
|
Caption = 'Axis limits'
|
||||||
ClientHeight = 130
|
ClientHeight = 130
|
||||||
ClientWidth = 252
|
ClientWidth = 237
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object lblAutomatic: TLabel
|
object lblAutomatic: TLabel
|
||||||
AnchorSideLeft.Control = gbAxisRange
|
AnchorSideLeft.Control = gbAxisRange
|
||||||
@ -330,7 +268,7 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 129
|
Left = 129
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 29
|
Top = 29
|
||||||
Width = 99
|
Width = 84
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Left = 24
|
BorderSpacing.Left = 24
|
||||||
@ -348,7 +286,7 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 129
|
Left = 129
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 60
|
Top = 60
|
||||||
Width = 99
|
Width = 84
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
@ -373,136 +311,49 @@ object AxisEditor: TAxisEditor
|
|||||||
object gbLabelFont: TGroupBox
|
object gbLabelFont: TGroupBox
|
||||||
AnchorSideLeft.Control = Bevel2
|
AnchorSideLeft.Control = Bevel2
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
|
AnchorSideTop.Control = gbAxisRange
|
||||||
AnchorSideRight.Control = pgLabels
|
AnchorSideRight.Control = pgLabels
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 278
|
Left = 265
|
||||||
Height = 104
|
Height = 104
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 254
|
Width = 242
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
Caption = 'Label font'
|
Caption = 'gbLabelFont'
|
||||||
ClientHeight = 84
|
|
||||||
ClientWidth = 250
|
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
inline LabelFontFrame: TFontFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 84
|
|
||||||
Width = 234
|
|
||||||
Align = alClient
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
ClientHeight = 84
|
|
||||||
ClientWidth = 234
|
|
||||||
inherited cmbFontName: TComboBox
|
|
||||||
AnchorSideLeft.Control = LabelFontFrame
|
|
||||||
AnchorSideTop.Control = LabelFontFrame
|
|
||||||
AnchorSideRight.Control = LabelFontFrame
|
|
||||||
Width = 234
|
|
||||||
end
|
|
||||||
inherited cbFontColor: TColorButton
|
|
||||||
AnchorSideRight.Control = LabelFontFrame
|
|
||||||
Left = 202
|
|
||||||
end
|
|
||||||
inherited cbBold: TCheckBox
|
|
||||||
AnchorSideLeft.Control = LabelFontFrame
|
|
||||||
BorderSpacing.Bottom = 6
|
|
||||||
end
|
|
||||||
inherited seOrientation: TSpinEdit
|
|
||||||
Alignment = taRightJustify
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
object gbShapeFillBorder: TGroupBox
|
object gbShapeFillBorder: TGroupBox
|
||||||
AnchorSideLeft.Control = Bevel2
|
AnchorSideLeft.Control = Bevel2
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
Left = 278
|
AnchorSideTop.Control = gbLabelFont
|
||||||
Height = 236
|
AnchorSideTop.Side = asrBottom
|
||||||
Top = 136
|
AnchorSideRight.Control = gbLabelFont
|
||||||
Width = 267
|
AnchorSideRight.Side = asrBottom
|
||||||
Caption = 'Label background'
|
Left = 265
|
||||||
ClientHeight = 216
|
Height = 266
|
||||||
ClientWidth = 263
|
Top = 128
|
||||||
|
Width = 242
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
BorderSpacing.Top = 16
|
||||||
|
Caption = 'gbShapeFillBorder'
|
||||||
TabOrder = 4
|
TabOrder = 4
|
||||||
inline LabelShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 208
|
|
||||||
Width = 247
|
|
||||||
Align = alClient
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
ClientHeight = 208
|
|
||||||
ClientWidth = 247
|
|
||||||
inherited cmbShape: TComboBox
|
|
||||||
AnchorSideLeft.Control = LabelShapeBrushPenMarginsFrame
|
|
||||||
AnchorSideTop.Control = LabelShapeBrushPenMarginsFrame
|
|
||||||
AnchorSideRight.Control = LabelShapeBrushPenMarginsFrame
|
|
||||||
Width = 247
|
|
||||||
end
|
|
||||||
inherited gbBackground: TGroupBox
|
|
||||||
AnchorSideLeft.Control = LabelShapeBrushPenMarginsFrame
|
|
||||||
Width = 116
|
|
||||||
ClientWidth = 112
|
|
||||||
inherited cbFillColor: TColorButton
|
|
||||||
Left = 72
|
|
||||||
end
|
|
||||||
end
|
|
||||||
inherited gbBorder: TGroupBox
|
|
||||||
AnchorSideRight.Control = LabelShapeBrushPenMarginsFrame
|
|
||||||
Left = 131
|
|
||||||
Width = 116
|
|
||||||
ClientWidth = 112
|
|
||||||
inherited cbBorderColor: TColorButton
|
|
||||||
Left = 74
|
|
||||||
end
|
|
||||||
end
|
|
||||||
inherited gbMargins: TGroupBox
|
|
||||||
AnchorSideBottom.Control = LabelShapeBrushPenMarginsFrame
|
|
||||||
Height = 116
|
|
||||||
Width = 247
|
|
||||||
ClientHeight = 96
|
|
||||||
ClientWidth = 243
|
|
||||||
inherited seTopMargin: TSpinEdit
|
|
||||||
Left = 96
|
|
||||||
end
|
|
||||||
inherited seBottomMargin: TSpinEdit
|
|
||||||
Left = 96
|
|
||||||
Top = 65
|
|
||||||
end
|
|
||||||
inherited seLeftMargin: TSpinEdit
|
|
||||||
Left = 38
|
|
||||||
Top = 33
|
|
||||||
end
|
|
||||||
inherited seRightMargin: TSpinEdit
|
|
||||||
Left = 154
|
|
||||||
Top = 33
|
|
||||||
end
|
|
||||||
inherited Bevel2: TBevel
|
|
||||||
Left = 96
|
|
||||||
Height = 34
|
|
||||||
end
|
|
||||||
end
|
|
||||||
inherited Bevel1: TBevel
|
|
||||||
Left = 123
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
object gbLabels: TGroupBox
|
object gbLabels: TGroupBox
|
||||||
AnchorSideLeft.Control = gbAxisRange
|
AnchorSideLeft.Control = gbAxisRange
|
||||||
AnchorSideTop.Control = gbAxisRange
|
AnchorSideTop.Control = gbAxisRange
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = Bevel2
|
AnchorSideRight.Control = Bevel2
|
||||||
Left = 6
|
Left = 8
|
||||||
Height = 113
|
Height = 113
|
||||||
Top = 166
|
Top = 168
|
||||||
Width = 256
|
Width = 241
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Top = 10
|
BorderSpacing.Top = 10
|
||||||
Caption = 'Labels'
|
Caption = 'Labels'
|
||||||
ClientHeight = 93
|
ClientHeight = 93
|
||||||
ClientWidth = 252
|
ClientWidth = 237
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object cbLabelsVisible: TCheckBox
|
object cbLabelsVisible: TCheckBox
|
||||||
AnchorSideLeft.Control = gbLabels
|
AnchorSideLeft.Control = gbLabels
|
||||||
@ -527,7 +378,7 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 96
|
Left = 96
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 27
|
Top = 27
|
||||||
Width = 140
|
Width = 125
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Left = 35
|
BorderSpacing.Left = 35
|
||||||
BorderSpacing.Top = 6
|
BorderSpacing.Top = 6
|
||||||
@ -555,8 +406,9 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 96
|
Left = 96
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 58
|
Top = 58
|
||||||
Width = 66
|
Width = 68
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Bottom = 12
|
BorderSpacing.Bottom = 12
|
||||||
OnChange = seLabelDistanceChange
|
OnChange = seLabelDistanceChange
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
@ -577,7 +429,7 @@ object AxisEditor: TAxisEditor
|
|||||||
object Bevel2: TBevel
|
object Bevel2: TBevel
|
||||||
AnchorSideLeft.Control = pgLabels
|
AnchorSideLeft.Control = pgLabels
|
||||||
AnchorSideLeft.Side = asrCenter
|
AnchorSideLeft.Side = asrCenter
|
||||||
Left = 262
|
Left = 249
|
||||||
Height = 50
|
Height = 50
|
||||||
Top = 280
|
Top = 280
|
||||||
Width = 16
|
Width = 16
|
||||||
@ -589,25 +441,30 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = gbLabels
|
AnchorSideRight.Control = gbLabels
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
AnchorSideBottom.Control = gbShapeFillBorder
|
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 6
|
Left = 8
|
||||||
Height = 83
|
Height = 88
|
||||||
Top = 289
|
Top = 291
|
||||||
Width = 256
|
Width = 241
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
AutoSize = True
|
||||||
BorderSpacing.Top = 10
|
BorderSpacing.Top = 10
|
||||||
|
BorderSpacing.Bottom = 8
|
||||||
Caption = 'Ticks'
|
Caption = 'Ticks'
|
||||||
ClientHeight = 63
|
ClientHeight = 68
|
||||||
ClientWidth = 252
|
ClientWidth = 237
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
object seTickLength: TSpinEdit
|
object seTickLength: TSpinEdit
|
||||||
|
AnchorSideLeft.Control = lblTickLength
|
||||||
|
AnchorSideLeft.Side = asrBottom
|
||||||
AnchorSideTop.Control = gbTicks
|
AnchorSideTop.Control = gbTicks
|
||||||
Left = 96
|
Left = 99
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 2
|
Top = 2
|
||||||
Width = 66
|
Width = 68
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
BorderSpacing.Left = 16
|
||||||
BorderSpacing.Top = 2
|
BorderSpacing.Top = 2
|
||||||
OnChange = seTickLengthChange
|
OnChange = seTickLengthChange
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -616,12 +473,14 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideLeft.Control = seTickLength
|
AnchorSideLeft.Control = seTickLength
|
||||||
AnchorSideTop.Control = seTickLength
|
AnchorSideTop.Control = seTickLength
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 96
|
Left = 99
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 33
|
Top = 33
|
||||||
Width = 66
|
Width = 68
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
|
BorderSpacing.Bottom = 12
|
||||||
OnChange = seTickInnerLengthChange
|
OnChange = seTickInnerLengthChange
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
end
|
end
|
||||||
@ -650,9 +509,8 @@ object AxisEditor: TAxisEditor
|
|||||||
end
|
end
|
||||||
object cbTickColor: TColorButton
|
object cbTickColor: TColorButton
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
AnchorSideRight.Control = LabelShapeBrushPenMarginsFrame.gbBackground
|
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 200
|
Left = 185
|
||||||
Height = 25
|
Height = 25
|
||||||
Top = 20
|
Top = 20
|
||||||
Width = 32
|
Width = 32
|
||||||
@ -667,140 +525,72 @@ object AxisEditor: TAxisEditor
|
|||||||
end
|
end
|
||||||
object pgGrid: TTabSheet
|
object pgGrid: TTabSheet
|
||||||
Caption = 'Grid'
|
Caption = 'Grid'
|
||||||
ClientHeight = 380
|
ClientHeight = 417
|
||||||
ClientWidth = 540
|
ClientWidth = 515
|
||||||
object gbGrid: TGroupBox
|
object gbGrid: TGroupBox
|
||||||
AnchorSideLeft.Control = pgGrid
|
AnchorSideLeft.Control = pgGrid
|
||||||
AnchorSideTop.Control = pgGrid
|
AnchorSideTop.Control = pgGrid
|
||||||
AnchorSideRight.Control = gbFrame
|
AnchorSideRight.Control = gbFrame
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 16
|
Left = 8
|
||||||
Height = 115
|
Height = 115
|
||||||
Top = 16
|
Top = 8
|
||||||
Width = 280
|
Width = 277
|
||||||
Anchors = [akTop, akLeft, akRight]
|
BorderSpacing.Left = 8
|
||||||
AutoSize = True
|
BorderSpacing.Top = 8
|
||||||
BorderSpacing.Left = 16
|
|
||||||
BorderSpacing.Top = 16
|
|
||||||
Caption = 'Grid lines'
|
Caption = 'Grid lines'
|
||||||
ClientHeight = 95
|
ClientHeight = 95
|
||||||
ClientWidth = 276
|
ClientWidth = 273
|
||||||
|
Constraints.MinWidth = 277
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object cbGridVisible: TCheckBox
|
object cbGridVisible: TCheckBox
|
||||||
AnchorSideLeft.Control = gbGrid
|
|
||||||
AnchorSideTop.Control = gbGrid
|
|
||||||
Left = 16
|
Left = 16
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 54
|
Width = 241
|
||||||
|
Align = alTop
|
||||||
BorderSpacing.Left = 16
|
BorderSpacing.Left = 16
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Visible'
|
|
||||||
OnChange = cbGridVisibleChange
|
|
||||||
TabOrder = 0
|
|
||||||
end
|
|
||||||
inline GridPenFrame: TPenFrame
|
|
||||||
AnchorSideLeft.Control = cbGridVisible
|
|
||||||
AnchorSideTop.Control = cbGridVisible
|
|
||||||
AnchorSideTop.Side = asrBottom
|
|
||||||
AnchorSideRight.Control = gbGrid
|
|
||||||
AnchorSideRight.Side = asrBottom
|
|
||||||
Left = 16
|
|
||||||
Height = 52
|
|
||||||
Top = 35
|
|
||||||
Width = 244
|
|
||||||
Anchors = [akTop, akLeft, akRight]
|
|
||||||
BorderSpacing.Top = 8
|
|
||||||
BorderSpacing.Right = 16
|
BorderSpacing.Right = 16
|
||||||
BorderSpacing.Bottom = 8
|
BorderSpacing.Bottom = 8
|
||||||
ClientHeight = 52
|
Caption = 'Visible'
|
||||||
ClientWidth = 244
|
OnChange = cbGridVisibleChange
|
||||||
TabOrder = 1
|
TabOrder = 0
|
||||||
inherited cbPenStyle: TChartComboBox
|
|
||||||
AnchorSideTop.Control = GridPenFrame
|
|
||||||
Width = 160
|
|
||||||
end
|
|
||||||
inherited lblPenStyle: TLabel
|
|
||||||
AnchorSideLeft.Control = GridPenFrame
|
|
||||||
end
|
|
||||||
inherited cbPenWidth: TChartComboBox
|
|
||||||
Width = 160
|
|
||||||
end
|
|
||||||
inherited cbPenColor: TColorButton
|
|
||||||
AnchorSideRight.Control = GridPenFrame
|
|
||||||
Left = 213
|
|
||||||
end
|
|
||||||
inherited Bevel1: TBevel
|
|
||||||
Left = 208
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object pgLine: TTabSheet
|
object pgLine: TTabSheet
|
||||||
Caption = 'Line'
|
Caption = 'Line'
|
||||||
ClientHeight = 380
|
ClientHeight = 417
|
||||||
ClientWidth = 540
|
ClientWidth = 515
|
||||||
object gbFrame: TGroupBox
|
object gbFrame: TGroupBox
|
||||||
AnchorSideLeft.Control = pgLine
|
AnchorSideLeft.Control = pgLine
|
||||||
AnchorSideTop.Control = pgLine
|
AnchorSideTop.Control = pgLine
|
||||||
|
AnchorSideRight.Control = gbArrow
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 119
|
Height = 119
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 288
|
Width = 277
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Left = 8
|
BorderSpacing.Left = 8
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Frame'
|
Caption = 'gbFrame'
|
||||||
ClientHeight = 99
|
ClientHeight = 99
|
||||||
ClientWidth = 284
|
ClientWidth = 273
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object cbFrameVisible: TCheckBox
|
object cbFrameVisible: TCheckBox
|
||||||
AnchorSideLeft.Control = gbFrame
|
|
||||||
AnchorSideTop.Control = gbFrame
|
|
||||||
Left = 16
|
Left = 16
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 54
|
Width = 241
|
||||||
|
Align = alTop
|
||||||
BorderSpacing.Left = 16
|
BorderSpacing.Left = 16
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Visible'
|
|
||||||
OnChange = cbFrameVisibleChange
|
|
||||||
TabOrder = 0
|
|
||||||
end
|
|
||||||
inline FramePenFrame: TPenFrame
|
|
||||||
AnchorSideLeft.Control = cbFrameVisible
|
|
||||||
AnchorSideTop.Control = cbFrameVisible
|
|
||||||
AnchorSideTop.Side = asrBottom
|
|
||||||
AnchorSideRight.Control = gbFrame
|
|
||||||
AnchorSideRight.Side = asrBottom
|
|
||||||
Left = 16
|
|
||||||
Height = 52
|
|
||||||
Top = 35
|
|
||||||
Width = 252
|
|
||||||
Anchors = [akTop, akLeft, akRight]
|
|
||||||
BorderSpacing.Top = 8
|
|
||||||
BorderSpacing.Right = 16
|
BorderSpacing.Right = 16
|
||||||
BorderSpacing.Bottom = 8
|
BorderSpacing.Bottom = 8
|
||||||
ClientHeight = 52
|
Caption = 'Visible'
|
||||||
ClientWidth = 252
|
OnChange = cbFrameVisibleChange
|
||||||
TabOrder = 1
|
TabOrder = 0
|
||||||
inherited cbPenStyle: TChartComboBox
|
|
||||||
AnchorSideTop.Control = FramePenFrame
|
|
||||||
Width = 167
|
|
||||||
end
|
|
||||||
inherited lblPenStyle: TLabel
|
|
||||||
AnchorSideLeft.Control = FramePenFrame
|
|
||||||
end
|
|
||||||
inherited cbPenWidth: TChartComboBox
|
|
||||||
Width = 167
|
|
||||||
end
|
|
||||||
inherited cbPenColor: TColorButton
|
|
||||||
AnchorSideRight.Control = nil
|
|
||||||
Left = 220
|
|
||||||
Anchors = [akTop]
|
|
||||||
end
|
|
||||||
inherited Bevel1: TBevel
|
|
||||||
Left = 215
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object gbAxisLine: TGroupBox
|
object gbAxisLine: TGroupBox
|
||||||
@ -810,78 +600,47 @@ object AxisEditor: TAxisEditor
|
|||||||
AnchorSideRight.Control = gbFrame
|
AnchorSideRight.Control = gbFrame
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 115
|
Height = 137
|
||||||
Top = 143
|
Top = 143
|
||||||
Width = 288
|
Width = 277
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
AutoSize = True
|
|
||||||
BorderSpacing.Top = 16
|
BorderSpacing.Top = 16
|
||||||
Caption = 'Axis line'
|
Caption = 'gbAxisLine'
|
||||||
ClientHeight = 95
|
ClientHeight = 117
|
||||||
ClientWidth = 284
|
ClientWidth = 273
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object cbAxisLineVisible: TCheckBox
|
object cbAxisLineVisible: TCheckBox
|
||||||
AnchorSideLeft.Control = gbAxisLine
|
|
||||||
AnchorSideTop.Control = gbAxisLine
|
|
||||||
Left = 16
|
Left = 16
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 54
|
Width = 241
|
||||||
|
Align = alTop
|
||||||
BorderSpacing.Left = 16
|
BorderSpacing.Left = 16
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Visible'
|
|
||||||
OnChange = cbAxisLineVisibleChange
|
|
||||||
TabOrder = 0
|
|
||||||
end
|
|
||||||
inline AxisLinePenFrame: TPenFrame
|
|
||||||
AnchorSideLeft.Control = cbAxisLineVisible
|
|
||||||
AnchorSideTop.Control = cbAxisLineVisible
|
|
||||||
AnchorSideTop.Side = asrBottom
|
|
||||||
AnchorSideRight.Control = gbAxisLine
|
|
||||||
AnchorSideRight.Side = asrBottom
|
|
||||||
Left = 16
|
|
||||||
Height = 52
|
|
||||||
Top = 35
|
|
||||||
Width = 252
|
|
||||||
Anchors = [akTop, akLeft, akRight]
|
|
||||||
BorderSpacing.Top = 8
|
|
||||||
BorderSpacing.Right = 16
|
BorderSpacing.Right = 16
|
||||||
BorderSpacing.Bottom = 8
|
BorderSpacing.Bottom = 8
|
||||||
ClientHeight = 52
|
Caption = 'Visible'
|
||||||
ClientWidth = 252
|
OnChange = cbAxisLineVisibleChange
|
||||||
TabOrder = 1
|
TabOrder = 0
|
||||||
inherited cbPenStyle: TChartComboBox
|
|
||||||
AnchorSideTop.Control = AxisLinePenFrame
|
|
||||||
Width = 168
|
|
||||||
end
|
|
||||||
inherited lblPenStyle: TLabel
|
|
||||||
AnchorSideLeft.Control = AxisLinePenFrame
|
|
||||||
end
|
|
||||||
inherited cbPenWidth: TChartComboBox
|
|
||||||
Width = 168
|
|
||||||
end
|
|
||||||
inherited cbPenColor: TColorButton
|
|
||||||
AnchorSideRight.Control = AxisLinePenFrame
|
|
||||||
Left = 221
|
|
||||||
end
|
|
||||||
inherited Bevel1: TBevel
|
|
||||||
Left = 216
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object gbArrow: TGroupBox
|
object gbArrow: TGroupBox
|
||||||
AnchorSideLeft.Control = gbFrame
|
AnchorSideLeft.Control = gbFrame
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
AnchorSideTop.Control = gbFrame
|
AnchorSideTop.Control = gbFrame
|
||||||
Left = 320
|
AnchorSideRight.Control = pgLine
|
||||||
|
AnchorSideRight.Side = asrBottom
|
||||||
|
Left = 309
|
||||||
Height = 156
|
Height = 156
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 187
|
Width = 200
|
||||||
|
Anchors = [akTop, akRight]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Left = 24
|
BorderSpacing.Left = 24
|
||||||
|
BorderSpacing.Right = 6
|
||||||
Caption = 'Arrow'
|
Caption = 'Arrow'
|
||||||
ClientHeight = 136
|
ClientHeight = 136
|
||||||
ClientWidth = 183
|
ClientWidth = 196
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
object cbArrowVisible: TCheckBox
|
object cbArrowVisible: TCheckBox
|
||||||
AnchorSideLeft.Control = gbArrow
|
AnchorSideLeft.Control = gbArrow
|
||||||
@ -937,7 +696,7 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 101
|
Left = 101
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 35
|
Top = 35
|
||||||
Width = 66
|
Width = 79
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Left = 24
|
BorderSpacing.Left = 24
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
@ -954,7 +713,7 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 101
|
Left = 101
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 66
|
Top = 66
|
||||||
Width = 66
|
Width = 79
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
@ -970,7 +729,7 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 101
|
Left = 101
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 97
|
Top = 97
|
||||||
Width = 66
|
Width = 79
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
@ -985,12 +744,12 @@ object AxisEditor: TAxisEditor
|
|||||||
Left = 0
|
Left = 0
|
||||||
Height = 33
|
Height = 33
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 548
|
Width = 535
|
||||||
Align = alTop
|
Align = alTop
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 33
|
ClientHeight = 33
|
||||||
ClientWidth = 548
|
ClientWidth = 535
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object cbShow: TCheckBox
|
object cbShow: TCheckBox
|
||||||
AnchorSideLeft.Control = PanelTop
|
AnchorSideLeft.Control = PanelTop
|
||||||
@ -1012,8 +771,8 @@ object AxisEditor: TAxisEditor
|
|||||||
object ButtonPanel: TButtonPanel
|
object ButtonPanel: TButtonPanel
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 34
|
Height = 34
|
||||||
Top = 447
|
Top = 484
|
||||||
Width = 536
|
Width = 523
|
||||||
OKButton.Name = 'OKButton'
|
OKButton.Name = 'OKButton'
|
||||||
OKButton.DefaultCaption = True
|
OKButton.DefaultCaption = True
|
||||||
OKButton.OnClick = OKButtonClick
|
OKButton.OnClick = OKButtonClick
|
||||||
|
@ -18,7 +18,6 @@ type
|
|||||||
|
|
||||||
TAxisEditor = class(TForm)
|
TAxisEditor = class(TForm)
|
||||||
ButtonPanel: TButtonPanel;
|
ButtonPanel: TButtonPanel;
|
||||||
GridPenFrame: TPenFrame;
|
|
||||||
Bevel1: TBevel;
|
Bevel1: TBevel;
|
||||||
Bevel2: TBevel;
|
Bevel2: TBevel;
|
||||||
Bevel3: TBevel;
|
Bevel3: TBevel;
|
||||||
@ -38,7 +37,6 @@ type
|
|||||||
cbFrameVisible: TCheckBox;
|
cbFrameVisible: TCheckBox;
|
||||||
cbArrowVisible: TCheckBox;
|
cbArrowVisible: TCheckBox;
|
||||||
edLabelFormat: TEdit;
|
edLabelFormat: TEdit;
|
||||||
AxisLinePenFrame: TPenFrame;
|
|
||||||
gbAxisLine: TGroupBox;
|
gbAxisLine: TGroupBox;
|
||||||
gbGrid: TGroupBox;
|
gbGrid: TGroupBox;
|
||||||
gbTitleFont: TGroupBox;
|
gbTitleFont: TGroupBox;
|
||||||
@ -58,7 +56,6 @@ type
|
|||||||
lblTitleDistance: TLabel;
|
lblTitleDistance: TLabel;
|
||||||
lblTickLength: TLabel;
|
lblTickLength: TLabel;
|
||||||
lblTickInnerLength: TLabel;
|
lblTickInnerLength: TLabel;
|
||||||
FramePenFrame: TPenFrame;
|
|
||||||
seTickLength: TSpinEdit;
|
seTickLength: TSpinEdit;
|
||||||
seTickInnerLength: TSpinEdit;
|
seTickInnerLength: TSpinEdit;
|
||||||
seTitleDistance: TSpinEdit;
|
seTitleDistance: TSpinEdit;
|
||||||
@ -67,8 +64,6 @@ type
|
|||||||
seArrowLength: TSpinEdit;
|
seArrowLength: TSpinEdit;
|
||||||
seArrowWidth: TSpinEdit;
|
seArrowWidth: TSpinEdit;
|
||||||
pgGrid: TTabSheet;
|
pgGrid: TTabSheet;
|
||||||
TitleFontFrame: TFontFrame;
|
|
||||||
LabelFontFrame: TFontFrame;
|
|
||||||
gbAxisRange: TGroupBox;
|
gbAxisRange: TGroupBox;
|
||||||
lblLabelFormat: TLabel;
|
lblLabelFormat: TLabel;
|
||||||
PanelTop: TPanel;
|
PanelTop: TPanel;
|
||||||
@ -77,8 +72,6 @@ type
|
|||||||
lblAutomatic: TLabel;
|
lblAutomatic: TLabel;
|
||||||
lblTitle: TLabel;
|
lblTitle: TLabel;
|
||||||
mmoTitle: TMemo;
|
mmoTitle: TMemo;
|
||||||
LabelShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame;
|
|
||||||
TitleShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame;
|
|
||||||
TitleMemoPanel: TPanel;
|
TitleMemoPanel: TPanel;
|
||||||
PageControl: TPageControl;
|
PageControl: TPageControl;
|
||||||
TitleParamsPanel: TPanel;
|
TitleParamsPanel: TPanel;
|
||||||
@ -98,6 +91,7 @@ type
|
|||||||
procedure cbTickColorColorChanged(Sender: TObject);
|
procedure cbTickColorColorChanged(Sender: TObject);
|
||||||
procedure cbTitleVisibleChange(Sender: TObject);
|
procedure cbTitleVisibleChange(Sender: TObject);
|
||||||
procedure edLabelFormatEditingDone(Sender: TObject);
|
procedure edLabelFormatEditingDone(Sender: TObject);
|
||||||
|
procedure FormActivate(Sender: TObject);
|
||||||
procedure FormCloseQuery(Sender: TObject; var CanClose: boolean);
|
procedure FormCloseQuery(Sender: TObject; var CanClose: boolean);
|
||||||
procedure FormCreate(Sender: TObject);
|
procedure FormCreate(Sender: TObject);
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
@ -119,13 +113,22 @@ type
|
|||||||
FAxis: TChartAxis;
|
FAxis: TChartAxis;
|
||||||
FOKClicked: Boolean;
|
FOKClicked: Boolean;
|
||||||
FSavedAxis: TChartAxis;
|
FSavedAxis: TChartAxis;
|
||||||
|
FTitleFontFrame: TFontFrame;
|
||||||
|
FTitleShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame;
|
||||||
|
FLabelFontFrame: TFontFrame;
|
||||||
|
FGridPenFrame: TPenFrame;
|
||||||
|
FFramePenFrame: TPenFrame;
|
||||||
|
FAxisLinePenFrame: TPenFrame;
|
||||||
|
FLabelShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame;
|
||||||
function GetAlignment(AItemIndex: Integer): TAlignment;
|
function GetAlignment(AItemIndex: Integer): TAlignment;
|
||||||
function GetAlignmentIndex(AValue: TAlignment): Integer;
|
function GetAlignmentIndex(AValue: TAlignment): Integer;
|
||||||
function GetPage: TAxisEditorPage;
|
function GetPage: TAxisEditorPage;
|
||||||
procedure SetPage(AValue: TAxisEditorPage);
|
procedure SetPage(AValue: TAxisEditorPage);
|
||||||
procedure ChangedHandler(Sender: TObject);
|
procedure ChangedHandler(Sender: TObject);
|
||||||
|
procedure LabelChangedHandler(Sender: TObject);
|
||||||
procedure LabelFontChangedHandler(Sender: TObject);
|
procedure LabelFontChangedHandler(Sender: TObject);
|
||||||
procedure LabelShapeChangedHandler(AShape: TChartLabelShape);
|
procedure LabelShapeChangedHandler(AShape: TChartLabelShape);
|
||||||
|
procedure TitleChangedHandler(Sender: TObject);
|
||||||
procedure TitleFontChangedHandler(Sender: TObject);
|
procedure TitleFontChangedHandler(Sender: TObject);
|
||||||
procedure TitleShapeChangedHandler(AShape: TChartLabelShape);
|
procedure TitleShapeChangedHandler(AShape: TChartLabelShape);
|
||||||
protected
|
protected
|
||||||
@ -144,7 +147,7 @@ implementation
|
|||||||
{$R *.lfm}
|
{$R *.lfm}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
ceUtils;
|
Math, ceUtils;
|
||||||
|
|
||||||
procedure TAxisEditor.cbAutoMaxChange(Sender: TObject);
|
procedure TAxisEditor.cbAutoMaxChange(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
@ -214,6 +217,21 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TAxisEditor.FormActivate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
Constraints.MinWidth := Max(gbTitleShapeBrushPenMargins.Width, gbTitleFont.Width) * 2 + Bevel1.Width +
|
||||||
|
TitleMemoPanel.BorderSpacing.Around*2 +
|
||||||
|
PageControl.BorderSpacing.Left + PageControl.BorderSpacing.Right;
|
||||||
|
|
||||||
|
Constraints.MinHeight := gbTicks.Top + gbTicks.Height + gbTicks.BorderSpacing.Bottom +
|
||||||
|
PageControl.Height - PageControl.ClientHeight +
|
||||||
|
PanelTop.Height +
|
||||||
|
ButtonPanel.Height + ButtonPanel.BorderSpacing.Around * 2;
|
||||||
|
|
||||||
|
Width := 1; // Enforce constraints
|
||||||
|
Height := 1;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TAxisEditor.FormCloseQuery(Sender: TObject; var CanClose: boolean);
|
procedure TAxisEditor.FormCloseQuery(Sender: TObject; var CanClose: boolean);
|
||||||
begin
|
begin
|
||||||
if not CanClose then exit;
|
if not CanClose then exit;
|
||||||
@ -226,20 +244,91 @@ end;
|
|||||||
|
|
||||||
procedure TAxisEditor.FormCreate(Sender: TObject);
|
procedure TAxisEditor.FormCreate(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
// Insert frames at runtime - this makes life much easier...
|
||||||
|
FTitleFontFrame := TFontFrame.Create(self);
|
||||||
|
FTitleFontFrame.Parent := gbTitleFont;
|
||||||
|
FTitleFontFrame.Name := '';
|
||||||
|
FTitleFontFrame.Align := alClient;
|
||||||
|
FTitleFontFrame.BorderSpacing.Left := 8;
|
||||||
|
FTitleFontFrame.BorderSpacing.Right := 8;
|
||||||
|
FTitleFontFrame.OnChange := @TitleFontChangedHandler;
|
||||||
|
gbTitleFont.AutoSize := true;
|
||||||
|
gbTitleFont.Caption := 'Font';
|
||||||
|
|
||||||
|
FTitleShapeBrushPenMarginsFrame := TShapeBrushPenMarginsFrame.Create(self);
|
||||||
|
FTitleShapeBrushPenMarginsFrame.Parent := gbTitleShapeBrushPenMargins;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.Name := '';
|
||||||
|
FTitleShapeBrushPenMarginsFrame.BorderSpacing.Left := 8;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.BorderSpacing.Right := 8;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.BorderSpacing.Bottom := 8;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.OnChange := @TitleChangedHandler;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.OnShapeChange := @TitleShapeChangedHandler;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.AutoSize := true;
|
||||||
|
gbTitleShapeBrushPenMargins.AutoSize := true;
|
||||||
|
gbTitleShapeBrushPenMargins.Caption := 'Title background';
|
||||||
|
|
||||||
|
FLabelFontFrame := TFontFrame.Create(self);
|
||||||
|
FLabelFontFrame.Parent := gbLabelFont;
|
||||||
|
FLabelFontFrame.Name := '';
|
||||||
|
FLabelFontFrame.Align := alClient;
|
||||||
|
FLabelFontFrame.BorderSpacing.Left := 8;
|
||||||
|
FLabelFontFrame.BorderSpacing.Right := 8;
|
||||||
|
FLabelFontFrame.OnChange := @LabelFontChangedHandler;
|
||||||
|
gbLabelFont.AutoSize := true;
|
||||||
|
gbLabelFont.Caption := 'Label font';
|
||||||
|
|
||||||
|
FLabelShapeBrushPenMarginsFrame := TShapeBrushPenMarginsFrame.Create(self);
|
||||||
|
FLabelShapeBrushPenMarginsFrame.Parent := gbShapeFillBorder;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.Name := '';
|
||||||
|
FLabelShapeBrushPenMarginsFrame.Align := alClient;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.BorderSpacing.Left := 8;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.BorderSpacing.Right := 8;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.BorderSpacing.Bottom := 8;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.OnChange := @LabelChangedHandler;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.OnShapeChange := @LabelShapeChangedHandler;
|
||||||
|
FLabelShapeBrushPenMarginsFrame.AutoSize := true;
|
||||||
|
gbShapeFillBorder.AutoSize := true;
|
||||||
|
gbShapeFillBorder.Caption := 'Label background';
|
||||||
|
|
||||||
|
FGridPenFrame := TPenFrame.Create(Self);
|
||||||
|
FGridPenFrame.Parent := gbGrid;
|
||||||
|
FGridPenFrame.Name := '';
|
||||||
|
FGridPenFrame.Align := alTop;
|
||||||
|
FGridPenFrame.Top := 1000;
|
||||||
|
FGridPenFrame.BorderSpacing.Left := 16;
|
||||||
|
FGridPenFrame.BorderSpacing.Right := 16;
|
||||||
|
FGridPenFrame.BorderSpacing.Bottom := 16;
|
||||||
|
FGridPenFrame.OnChange := @ChangedHandler;
|
||||||
|
gbGrid.AutoSize := true;
|
||||||
|
gbGrid.Caption := 'Grid lines';
|
||||||
|
|
||||||
|
FFramePenFrame := TPenFrame.Create(Self);
|
||||||
|
FFramePenFrame.Parent := gbFrame;
|
||||||
|
FFramePenFrame.Name := '';
|
||||||
|
FFramePenFrame.Align := alTop;
|
||||||
|
FFramePenFrame.Top := 1000;
|
||||||
|
FFramePenFrame.BorderSpacing.Left := 16;
|
||||||
|
FFramePenFrame.BorderSpacing.Right := 16;
|
||||||
|
FFramePenFrame.BorderSpacing.Bottom := 16;
|
||||||
|
FFramePenFrame.OnChange := @ChangedHandler;
|
||||||
|
gbFrame.AutoSize := true;
|
||||||
|
gbFrame.Caption := 'Frame';
|
||||||
|
|
||||||
|
FAxisLinePenFrame := TPenFrame.Create(Self);
|
||||||
|
FAxisLinePenFrame.Parent := gbAxisLine;
|
||||||
|
FAxisLinePenFrame.Name := '';
|
||||||
|
FAxisLinePenFrame.Align := alTop;
|
||||||
|
FAxisLinePenFrame.Top := 1000;
|
||||||
|
FAxisLinePenFrame.BorderSpacing.Left := 16;
|
||||||
|
FAxisLinePenFrame.BorderSpacing.Right := 16;
|
||||||
|
FAxisLinePenFrame.BorderSpacing.Bottom := 16;
|
||||||
|
FAxisLinePenFrame.OnChange := @ChangedHandler;
|
||||||
|
gbAxisLine.AutoSize := true;
|
||||||
|
gbAxisLine.Caption := 'Axis line';
|
||||||
|
|
||||||
BoldHeaders(self);
|
BoldHeaders(self);
|
||||||
|
|
||||||
TitleShapeBrushPenMarginsFrame.OnChange := @ChangedHandler;
|
TitleParamsPanel.AutoSize := true;
|
||||||
TitleShapeBrushPenMarginsFrame.OnShapeChange := @TitleShapeChangedHandler;
|
|
||||||
TitleFontFrame.OnChange := @TitleFontChangedHandler;
|
|
||||||
|
|
||||||
LabelShapeBrushPenMarginsFrame.OnChange := @ChangedHandler;
|
|
||||||
LabelShapeBrushPenMarginsFrame.OnShapeChange := @LabelShapeChangedHandler;
|
|
||||||
LabelFontFrame.OnChange := @LabelFontChangedHandler;
|
|
||||||
|
|
||||||
FramePenFrame.OnChange := @ChangedHandler;
|
|
||||||
AxisLinePenFrame.OnChange := @ChangedHandler;
|
|
||||||
|
|
||||||
GridPenFrame.OnChange := @ChangedHandler;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TAxisEditor.FormDestroy(Sender: TObject);
|
procedure TAxisEditor.FormDestroy(Sender: TObject);
|
||||||
@ -250,6 +339,8 @@ end;
|
|||||||
procedure TAxisEditor.FormShow(Sender: TObject);
|
procedure TAxisEditor.FormShow(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
FOKClicked := false;
|
FOKClicked := false;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.AutoSize := false;
|
||||||
|
FTitleShapeBrushPenMarginsFrame.Align := alClient;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TAxisEditor.GetAlignment(AItemIndex: Integer): TAlignment;
|
function TAxisEditor.GetAlignment(AItemIndex: Integer): TAlignment;
|
||||||
@ -281,6 +372,11 @@ begin
|
|||||||
ModalResult := mrYesToAll;
|
ModalResult := mrYesToAll;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TAxisEditor.LabelChangedHandler(Sender: TObject);
|
||||||
|
begin
|
||||||
|
GetChart.Invalidate;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TAxisEditor.LabelFontChangedHandler(Sender: TObject);
|
procedure TAxisEditor.LabelFontChangedHandler(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
GetChart.Invalidate;
|
GetChart.Invalidate;
|
||||||
@ -319,11 +415,13 @@ begin
|
|||||||
// Page "Title"
|
// Page "Title"
|
||||||
cbTitleVisible.Checked := Axis.Title.Visible;
|
cbTitleVisible.Checked := Axis.Title.Visible;
|
||||||
mmoTitle.Lines.Text := Axis.Title.Caption;
|
mmoTitle.Lines.Text := Axis.Title.Caption;
|
||||||
|
mmoTitle.Font := Axis.Title.LabelFont;
|
||||||
|
mmoTitle.Font.Orientation := 0; // Memo has horizontal text only
|
||||||
with Axis.Title do begin
|
with Axis.Title do begin
|
||||||
rgTitleAlignment.ItemIndex := GetAlignmentIndex(Alignment);
|
rgTitleAlignment.ItemIndex := GetAlignmentIndex(Alignment);
|
||||||
seTitleDistance.Value := Distance;
|
seTitleDistance.Value := Distance;
|
||||||
TitleFontFrame.Prepare(LabelFont, true);
|
FTitleFontFrame.Prepare(LabelFont, true);
|
||||||
TitleShapeBrushPenMarginsFrame.Prepare(Shape, LabelBrush, Frame, Margins);
|
FTitleShapeBrushPenMarginsFrame.Prepare(Shape, LabelBrush, Frame, Margins);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
// Page "Labels"
|
// Page "Labels"
|
||||||
@ -339,18 +437,19 @@ begin
|
|||||||
seLabelDistance.Value := Distance;
|
seLabelDistance.Value := Distance;
|
||||||
cbLabelsVisible.Checked := Visible;
|
cbLabelsVisible.Checked := Visible;
|
||||||
edLabelFormat.Text := Format;
|
edLabelFormat.Text := Format;
|
||||||
LabelFontFrame.Prepare(LabelFont, true);
|
FLabelFontFrame.Prepare(LabelFont, true);
|
||||||
LabelShapeBrushPenMarginsFrame.Prepare(Shape, LabelBrush, Frame, Margins);
|
FLabelShapeBrushPenMarginsFrame.Prepare(Shape, LabelBrush, Frame, Margins);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
// Page "Grid"
|
// Page "Grid"
|
||||||
GridPenFrame.Prepare(FAxis.Grid);
|
cbGridVisible.Checked := FAxis.Grid.EffVisible;
|
||||||
|
FGridPenFrame.Prepare(FAxis.Grid);
|
||||||
|
|
||||||
// Page "Line"
|
// Page "Line"
|
||||||
cbFrameVisible.Checked := GetChart.Frame.EffVisible;
|
cbFrameVisible.Checked := GetChart.Frame.EffVisible;
|
||||||
FramePenFrame.Prepare(GetChart.Frame);
|
FFramePenFrame.Prepare(GetChart.Frame);
|
||||||
cbAxisLineVisible.Checked := FAxis.AxisPen.EffVisible;
|
cbAxisLineVisible.Checked := FAxis.AxisPen.EffVisible;
|
||||||
AxisLinePenFrame.Prepare(FAxis.AxisPen);
|
FAxisLinePenFrame.Prepare(FAxis.AxisPen);
|
||||||
cbArrowVisible.Checked := FAxis.Arrow.Visible;
|
cbArrowVisible.Checked := FAxis.Arrow.Visible;
|
||||||
seArrowBaseLength.Value := FAxis.Arrow.BaseLength;
|
seArrowBaseLength.Value := FAxis.Arrow.BaseLength;
|
||||||
seArrowLength.Value := FAxis.Arrow.Length;
|
seArrowLength.Value := FAxis.Arrow.Length;
|
||||||
@ -412,9 +511,16 @@ begin
|
|||||||
PageControl.ActivePageIndex := ord(AValue);
|
PageControl.ActivePageIndex := ord(AValue);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TAxisEditor.TitleChangedHandler(Sender: TObject);
|
||||||
|
begin
|
||||||
|
mmoTitle.Color := FAxis.Title.LabelBrush.Color;
|
||||||
|
GetChart.Invalidate;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TAxisEditor.TitleFontChangedHandler(Sender: TObject);
|
procedure TAxisEditor.TitleFontChangedHandler(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
mmoTitle.Font.Assign(FAxis.Title.LabelFont);
|
mmoTitle.Font.Assign(FAxis.Title.LabelFont);
|
||||||
|
mmoTitle.Font.Orientation := 0;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TAxisEditor.TitleShapeChangedHandler(AShape: TChartLabelShape);
|
procedure TAxisEditor.TitleShapeChangedHandler(AShape: TChartLabelShape);
|
||||||
|
@ -60,7 +60,7 @@ end;
|
|||||||
procedure TBrushFrame.Prepare(ABrush: TBrush);
|
procedure TBrushFrame.Prepare(ABrush: TBrush);
|
||||||
begin
|
begin
|
||||||
FBrush := ABrush;
|
FBrush := ABrush;
|
||||||
cbBrushColor.ButtonColor := ABrush.Color;
|
cbBrushColor.ButtonColor := ColorToRGB(ABrush.Color);
|
||||||
cbBrushStyle.BrushStyle := ABrush.Style;
|
cbBrushStyle.BrushStyle := ABrush.Style;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
object FontFrame: TFontFrame
|
object FontFrame: TFontFrame
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 75
|
Height = 84
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 250
|
Width = 301
|
||||||
ClientHeight = 75
|
ClientHeight = 84
|
||||||
ClientWidth = 250
|
ClientWidth = 301
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
DesignLeft = 332
|
DesignLeft = 332
|
||||||
DesignTop = 128
|
DesignTop = 128
|
||||||
@ -16,51 +16,20 @@ object FontFrame: TFontFrame
|
|||||||
Left = 0
|
Left = 0
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 250
|
Width = 301
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
ItemHeight = 15
|
ItemHeight = 15
|
||||||
OnChange = cmbFontNameChange
|
OnChange = cmbFontNameChange
|
||||||
Style = csDropDownList
|
Style = csDropDownList
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
end
|
end
|
||||||
object cmbFontSize: TComboBox
|
|
||||||
AnchorSideTop.Control = cbFontColor
|
|
||||||
AnchorSideTop.Side = asrCenter
|
|
||||||
AnchorSideRight.Side = asrBottom
|
|
||||||
Left = 0
|
|
||||||
Height = 23
|
|
||||||
Top = 30
|
|
||||||
Width = 94
|
|
||||||
BorderSpacing.Right = 6
|
|
||||||
ItemHeight = 15
|
|
||||||
OnChange = cmbFontSizeChange
|
|
||||||
Style = csDropDownList
|
|
||||||
TabOrder = 1
|
|
||||||
end
|
|
||||||
object cbFontColor: TColorButton
|
|
||||||
AnchorSideTop.Control = cmbFontName
|
|
||||||
AnchorSideTop.Side = asrBottom
|
|
||||||
AnchorSideRight.Control = Owner
|
|
||||||
AnchorSideRight.Side = asrBottom
|
|
||||||
AnchorSideBottom.Side = asrBottom
|
|
||||||
Left = 218
|
|
||||||
Height = 25
|
|
||||||
Top = 29
|
|
||||||
Width = 32
|
|
||||||
Anchors = [akTop, akRight]
|
|
||||||
BorderSpacing.Top = 6
|
|
||||||
BorderWidth = 2
|
|
||||||
ButtonColorSize = 16
|
|
||||||
ButtonColor = clBlack
|
|
||||||
OnColorChanged = cbFontColorColorChanged
|
|
||||||
end
|
|
||||||
object cbBold: TCheckBox
|
object cbBold: TCheckBox
|
||||||
AnchorSideLeft.Control = Owner
|
AnchorSideLeft.Control = Owner
|
||||||
AnchorSideTop.Control = cmbFontSize
|
AnchorSideTop.Control = Panel2
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 59
|
Top = 60
|
||||||
Width = 45
|
Width = 45
|
||||||
BorderSpacing.Top = 6
|
BorderSpacing.Top = 6
|
||||||
BorderSpacing.Bottom = 8
|
BorderSpacing.Bottom = 8
|
||||||
@ -68,7 +37,7 @@ object FontFrame: TFontFrame
|
|||||||
Font.Style = [fsBold]
|
Font.Style = [fsBold]
|
||||||
OnChange = cbBoldChange
|
OnChange = cbBoldChange
|
||||||
ParentFont = False
|
ParentFont = False
|
||||||
TabOrder = 3
|
TabOrder = 1
|
||||||
end
|
end
|
||||||
object cbItalic: TCheckBox
|
object cbItalic: TCheckBox
|
||||||
AnchorSideLeft.Control = cbBold
|
AnchorSideLeft.Control = cbBold
|
||||||
@ -76,14 +45,14 @@ object FontFrame: TFontFrame
|
|||||||
AnchorSideTop.Control = cbBold
|
AnchorSideTop.Control = cbBold
|
||||||
Left = 53
|
Left = 53
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 59
|
Top = 60
|
||||||
Width = 45
|
Width = 45
|
||||||
BorderSpacing.Left = 8
|
BorderSpacing.Left = 8
|
||||||
Caption = 'Italic'
|
Caption = 'Italic'
|
||||||
Font.Style = [fsItalic]
|
Font.Style = [fsItalic]
|
||||||
OnChange = cbItalicChange
|
OnChange = cbItalicChange
|
||||||
ParentFont = False
|
ParentFont = False
|
||||||
TabOrder = 4
|
TabOrder = 2
|
||||||
end
|
end
|
||||||
object cbUnderline: TCheckBox
|
object cbUnderline: TCheckBox
|
||||||
AnchorSideLeft.Control = cbItalic
|
AnchorSideLeft.Control = cbItalic
|
||||||
@ -92,7 +61,7 @@ object FontFrame: TFontFrame
|
|||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 106
|
Left = 106
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 59
|
Top = 60
|
||||||
Width = 78
|
Width = 78
|
||||||
BorderSpacing.Left = 8
|
BorderSpacing.Left = 8
|
||||||
BorderSpacing.Right = 6
|
BorderSpacing.Right = 6
|
||||||
@ -100,18 +69,62 @@ object FontFrame: TFontFrame
|
|||||||
Font.Style = [fsUnderline]
|
Font.Style = [fsUnderline]
|
||||||
OnChange = cbUnderlineChange
|
OnChange = cbUnderlineChange
|
||||||
ParentFont = False
|
ParentFont = False
|
||||||
TabOrder = 5
|
TabOrder = 3
|
||||||
end
|
end
|
||||||
object lblOrientation: TLabel
|
object Panel2: TPanel
|
||||||
AnchorSideLeft.Control = cmbFontSize
|
AnchorSideLeft.Control = Owner
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideTop.Control = cmbFontName
|
||||||
AnchorSideTop.Control = cbFontColor
|
AnchorSideTop.Side = asrBottom
|
||||||
|
AnchorSideRight.Control = Owner
|
||||||
|
AnchorSideRight.Side = asrBottom
|
||||||
|
Left = 0
|
||||||
|
Height = 31
|
||||||
|
Top = 23
|
||||||
|
Width = 301
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
BevelOuter = bvNone
|
||||||
|
ChildSizing.EnlargeHorizontal = crsHomogenousSpaceResize
|
||||||
|
ChildSizing.ShrinkHorizontal = crsHomogenousSpaceResize
|
||||||
|
ChildSizing.ControlsPerLine = 3
|
||||||
|
ClientHeight = 31
|
||||||
|
ClientWidth = 301
|
||||||
|
TabOrder = 4
|
||||||
|
object cmbFontSize: TComboBox
|
||||||
|
AnchorSideLeft.Control = Panel2
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
Left = 106
|
AnchorSideRight.Control = Panel1
|
||||||
|
Left = 0
|
||||||
|
Height = 23
|
||||||
|
Top = 6
|
||||||
|
Width = 144
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
BorderSpacing.Right = 16
|
||||||
|
ItemHeight = 15
|
||||||
|
OnChange = cmbFontSizeChange
|
||||||
|
Style = csDropDownList
|
||||||
|
TabOrder = 0
|
||||||
|
end
|
||||||
|
object Panel1: TPanel
|
||||||
|
AnchorSideRight.Control = cbFontColor
|
||||||
|
Left = 160
|
||||||
|
Height = 23
|
||||||
|
Top = 6
|
||||||
|
Width = 97
|
||||||
|
Anchors = [akTop, akRight]
|
||||||
|
AutoSize = True
|
||||||
|
BorderSpacing.Right = 16
|
||||||
|
BevelOuter = bvNone
|
||||||
|
ClientHeight = 23
|
||||||
|
ClientWidth = 97
|
||||||
|
TabOrder = 1
|
||||||
|
object lblOrientation: TLabel
|
||||||
|
AnchorSideLeft.Control = Panel1
|
||||||
|
AnchorSideTop.Control = seOrientation
|
||||||
|
AnchorSideTop.Side = asrCenter
|
||||||
|
Left = 0
|
||||||
Height = 15
|
Height = 15
|
||||||
Top = 34
|
Top = 4
|
||||||
Width = 31
|
Width = 31
|
||||||
BorderSpacing.Left = 12
|
|
||||||
Caption = 'Angle'
|
Caption = 'Angle'
|
||||||
FocusControl = seOrientation
|
FocusControl = seOrientation
|
||||||
ParentColor = False
|
ParentColor = False
|
||||||
@ -119,16 +132,35 @@ object FontFrame: TFontFrame
|
|||||||
object seOrientation: TSpinEdit
|
object seOrientation: TSpinEdit
|
||||||
AnchorSideLeft.Control = lblOrientation
|
AnchorSideLeft.Control = lblOrientation
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
AnchorSideTop.Control = cbFontColor
|
AnchorSideTop.Control = Panel1
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
Left = 143
|
Left = 39
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 30
|
Top = 0
|
||||||
Width = 58
|
Width = 58
|
||||||
BorderSpacing.Left = 6
|
BorderSpacing.Left = 8
|
||||||
MaxValue = 360
|
MaxValue = 360
|
||||||
MinValue = -360
|
MinValue = -360
|
||||||
OnChange = seOrientationChange
|
OnChange = seOrientationChange
|
||||||
TabOrder = 2
|
TabOrder = 0
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cbFontColor: TColorButton
|
||||||
|
AnchorSideTop.Side = asrBottom
|
||||||
|
AnchorSideRight.Control = Panel2
|
||||||
|
AnchorSideRight.Side = asrBottom
|
||||||
|
AnchorSideBottom.Side = asrBottom
|
||||||
|
Left = 273
|
||||||
|
Height = 23
|
||||||
|
Top = 6
|
||||||
|
Width = 28
|
||||||
|
Anchors = [akTop, akRight]
|
||||||
|
BorderSpacing.Top = 6
|
||||||
|
BorderWidth = 2
|
||||||
|
ButtonColorSize = 16
|
||||||
|
ButtonColor = clBlack
|
||||||
|
Margin = 2
|
||||||
|
OnColorChanged = cbFontColorColorChanged
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -5,7 +5,8 @@ unit ceFontFrame;
|
|||||||
interface
|
interface
|
||||||
|
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, Graphics, Forms, Controls, StdCtrls, Dialogs, Spin;
|
Classes, SysUtils, Graphics, Forms, Controls, StdCtrls, Dialogs, Spin,
|
||||||
|
ExtCtrls;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
@ -19,6 +20,8 @@ type
|
|||||||
cmbFontName: TComboBox;
|
cmbFontName: TComboBox;
|
||||||
cmbFontSize: TComboBox;
|
cmbFontSize: TComboBox;
|
||||||
lblOrientation: TLabel;
|
lblOrientation: TLabel;
|
||||||
|
Panel1: TPanel;
|
||||||
|
Panel2: TPanel;
|
||||||
seOrientation: TSpinEdit;
|
seOrientation: TSpinEdit;
|
||||||
procedure cbBoldChange(Sender: TObject);
|
procedure cbBoldChange(Sender: TObject);
|
||||||
procedure cbFontColorColorChanged(Sender: TObject);
|
procedure cbFontColorColorChanged(Sender: TObject);
|
||||||
|
@ -2,12 +2,12 @@ object LegendEditor: TLegendEditor
|
|||||||
Left = 978
|
Left = 978
|
||||||
Height = 396
|
Height = 396
|
||||||
Top = 169
|
Top = 169
|
||||||
Width = 553
|
Width = 590
|
||||||
ActiveControl = cbShow
|
ActiveControl = cbShow
|
||||||
BorderStyle = bsDialog
|
BorderStyle = bsDialog
|
||||||
Caption = 'Legend editor'
|
Caption = 'Legend editor'
|
||||||
ClientHeight = 396
|
ClientHeight = 396
|
||||||
ClientWidth = 553
|
ClientWidth = 590
|
||||||
OnCloseQuery = FormCloseQuery
|
OnCloseQuery = FormCloseQuery
|
||||||
OnCreate = FormCreate
|
OnCreate = FormCreate
|
||||||
OnDestroy = FormDestroy
|
OnDestroy = FormDestroy
|
||||||
@ -18,7 +18,7 @@ object LegendEditor: TLegendEditor
|
|||||||
Left = 6
|
Left = 6
|
||||||
Height = 34
|
Height = 34
|
||||||
Top = 356
|
Top = 356
|
||||||
Width = 541
|
Width = 578
|
||||||
OKButton.Name = 'OKButton'
|
OKButton.Name = 'OKButton'
|
||||||
OKButton.DefaultCaption = True
|
OKButton.DefaultCaption = True
|
||||||
OKButton.OnClick = OKButtonClick
|
OKButton.OnClick = OKButtonClick
|
||||||
@ -36,13 +36,13 @@ object LegendEditor: TLegendEditor
|
|||||||
Left = 8
|
Left = 8
|
||||||
Height = 309
|
Height = 309
|
||||||
Top = 39
|
Top = 39
|
||||||
Width = 537
|
Width = 574
|
||||||
Align = alClient
|
Align = alClient
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Around = 8
|
BorderSpacing.Around = 8
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 309
|
ClientHeight = 309
|
||||||
ClientWidth = 537
|
ClientWidth = 574
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object gbBackground: TGroupBox
|
object gbBackground: TGroupBox
|
||||||
AnchorSideLeft.Control = gbAlignment
|
AnchorSideLeft.Control = gbAlignment
|
||||||
@ -149,45 +149,8 @@ object LegendEditor: TLegendEditor
|
|||||||
Width = 216
|
Width = 216
|
||||||
Anchors = [akTop, akLeft, akBottom]
|
Anchors = [akTop, akLeft, akBottom]
|
||||||
BorderSpacing.Left = 20
|
BorderSpacing.Left = 20
|
||||||
Caption = 'Font'
|
Caption = 'gbFont'
|
||||||
ClientHeight = 92
|
|
||||||
ClientWidth = 212
|
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
inline FontFrame1: TFontFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 84
|
|
||||||
Width = 196
|
|
||||||
Align = alClient
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
ClientHeight = 84
|
|
||||||
ClientWidth = 196
|
|
||||||
inherited cmbFontName: TComboBox
|
|
||||||
AnchorSideLeft.Control = FontFrame1
|
|
||||||
AnchorSideTop.Control = FontFrame1
|
|
||||||
AnchorSideRight.Control = FontFrame1
|
|
||||||
Width = 196
|
|
||||||
end
|
|
||||||
inherited cbFontColor: TColorButton
|
|
||||||
AnchorSideRight.Control = FontFrame1
|
|
||||||
Left = 164
|
|
||||||
end
|
|
||||||
inherited cbBold: TCheckBox
|
|
||||||
AnchorSideLeft.Control = FontFrame1
|
|
||||||
end
|
|
||||||
inherited lblOrientation: TLabel
|
|
||||||
Left = 110
|
|
||||||
Anchors = [akTop]
|
|
||||||
Visible = False
|
|
||||||
end
|
|
||||||
inherited seOrientation: TSpinEdit
|
|
||||||
Left = 147
|
|
||||||
Width = 26
|
|
||||||
Alignment = taRightJustify
|
|
||||||
Visible = False
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
object gbAlignment: TGroupBox
|
object gbAlignment: TGroupBox
|
||||||
AnchorSideLeft.Control = ParamsPanel
|
AnchorSideLeft.Control = ParamsPanel
|
||||||
@ -538,12 +501,12 @@ object LegendEditor: TLegendEditor
|
|||||||
Left = 0
|
Left = 0
|
||||||
Height = 31
|
Height = 31
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 553
|
Width = 590
|
||||||
Align = alTop
|
Align = alTop
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 31
|
ClientHeight = 31
|
||||||
ClientWidth = 553
|
ClientWidth = 590
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object cbShow: TCheckBox
|
object cbShow: TCheckBox
|
||||||
Left = 8
|
Left = 8
|
||||||
|
@ -24,7 +24,6 @@ type
|
|||||||
cbInverted: TCheckBox;
|
cbInverted: TCheckBox;
|
||||||
cbUseSideBar: TCheckBox;
|
cbUseSideBar: TCheckBox;
|
||||||
cbItemFillOrder: TComboBox;
|
cbItemFillOrder: TComboBox;
|
||||||
FontFrame1: TFontFrame;
|
|
||||||
gbBackground: TGroupBox;
|
gbBackground: TGroupBox;
|
||||||
gbBorder: TGroupBox;
|
gbBorder: TGroupBox;
|
||||||
gbFont: TGroupBox;
|
gbFont: TGroupBox;
|
||||||
@ -75,6 +74,7 @@ type
|
|||||||
FLegend: TChartLegend;
|
FLegend: TChartLegend;
|
||||||
FSavedLegend: TChartLegend;
|
FSavedLegend: TChartLegend;
|
||||||
FOKClicked: Boolean;
|
FOKClicked: Boolean;
|
||||||
|
FFontFrame: TFontFrame;
|
||||||
procedure ChangedHandler(Sender: TObject);
|
procedure ChangedHandler(Sender: TObject);
|
||||||
function GetAlignment: TLegendAlignment;
|
function GetAlignment: TLegendAlignment;
|
||||||
procedure SetAlignment(AValue: TLegendAlignment);
|
procedure SetAlignment(AValue: TLegendAlignment);
|
||||||
@ -163,8 +163,18 @@ end;
|
|||||||
|
|
||||||
procedure TLegendEditor.FormCreate(Sender: TObject);
|
procedure TLegendEditor.FormCreate(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
FFontFrame := TFontFrame.Create(self);
|
||||||
|
FFontFrame.Parent := gbFont;
|
||||||
|
FFontFrame.Name := '';
|
||||||
|
FFontFrame.Align := alClient;
|
||||||
|
FFontFrame.BorderSpacing.Left := 8;
|
||||||
|
FFontFrame.BorderSpacing.Right := 8;
|
||||||
|
FFontFrame.AutoSize := true;
|
||||||
|
FFontFrame.OnChange := @ChangedHandler;
|
||||||
|
gbFont.AutoSize := true;
|
||||||
|
gbFont.Caption := 'Font';
|
||||||
|
|
||||||
BoldHeaders(Self);
|
BoldHeaders(Self);
|
||||||
FontFrame1.OnChange := @ChangedHandler;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TLegendEditor.FormDestroy(Sender: TObject);
|
procedure TLegendEditor.FormDestroy(Sender: TObject);
|
||||||
@ -270,10 +280,10 @@ begin
|
|||||||
SetAlignment(ALegend.Alignment);
|
SetAlignment(ALegend.Alignment);
|
||||||
|
|
||||||
cbFilled.Checked := ALegend.BackgroundBrush.Style <> bsClear;
|
cbFilled.Checked := ALegend.BackgroundBrush.Style <> bsClear;
|
||||||
cbFillColor.Selected := ALegend.BackgroundBrush.Color;
|
cbFillColor.Selected := ColorToRGB(ALegend.BackgroundBrush.Color);
|
||||||
|
|
||||||
cbShowBorder.Checked := (ALegend.Frame.Style <> psClear) and ALegend.Frame.Visible;
|
cbShowBorder.Checked := (ALegend.Frame.Style <> psClear) and ALegend.Frame.Visible;
|
||||||
cbBorderColor.Selected := ALegend.Frame.Color;
|
cbBorderColor.Selected := ColorToRGB(ALegend.Frame.Color);
|
||||||
|
|
||||||
seMarginX.Value := ALegend.MarginX;
|
seMarginX.Value := ALegend.MarginX;
|
||||||
seMarginY.Value := ALegend.MarginY;
|
seMarginY.Value := ALegend.MarginY;
|
||||||
@ -285,7 +295,7 @@ begin
|
|||||||
seSpacing.Value := ALegend.Spacing;
|
seSpacing.Value := ALegend.Spacing;
|
||||||
cbItemFillOrder.ItemIndex := ord(ALegend.ItemFillOrder);
|
cbItemFillOrder.ItemIndex := ord(ALegend.ItemFillOrder);
|
||||||
|
|
||||||
FontFrame1.Prepare(ALegend.Font, false);
|
FFontFrame.Prepare(ALegend.Font, false);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
@ -83,6 +83,7 @@ object PenFrame: TPenFrame
|
|||||||
BorderWidth = 2
|
BorderWidth = 2
|
||||||
ButtonColorSize = 16
|
ButtonColorSize = 16
|
||||||
ButtonColor = clBlack
|
ButtonColor = clBlack
|
||||||
|
Margin = 2
|
||||||
OnColorChanged = cbPenColorColorChanged
|
OnColorChanged = cbPenColorColorChanged
|
||||||
end
|
end
|
||||||
object Bevel1: TBevel
|
object Bevel1: TBevel
|
||||||
|
@ -76,7 +76,7 @@ begin
|
|||||||
FPen := APen;
|
FPen := APen;
|
||||||
cbPenStyle.PenStyle := FPen.Style;
|
cbPenStyle.PenStyle := FPen.Style;
|
||||||
cbPenWidth.PenWidth := FPen.Width;
|
cbPenWidth.PenWidth := FPen.Width;
|
||||||
cbPenColor.ButtonColor := FPen.Color;
|
cbPenColor.ButtonColor := ColorToRGB(FPen.Color);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
@ -1,11 +1,10 @@
|
|||||||
object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 187
|
Height = 237
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 230
|
Width = 263
|
||||||
ClientHeight = 187
|
ClientHeight = 237
|
||||||
ClientWidth = 230
|
ClientWidth = 263
|
||||||
Constraints.MinWidth = 230
|
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
DesignLeft = 1498
|
DesignLeft = 1498
|
||||||
DesignTop = 388
|
DesignTop = 388
|
||||||
@ -18,7 +17,7 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
Left = 0
|
Left = 0
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 230
|
Width = 263
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
Enabled = False
|
Enabled = False
|
||||||
ItemHeight = 15
|
ItemHeight = 15
|
||||||
@ -42,27 +41,31 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 53
|
Height = 54
|
||||||
Top = 31
|
Top = 31
|
||||||
Width = 108
|
Width = 124
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
AutoSize = True
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
Caption = 'Background'
|
Caption = 'Background'
|
||||||
ClientHeight = 33
|
ClientHeight = 34
|
||||||
ClientWidth = 104
|
ClientWidth = 120
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object cbFilled: TCheckBox
|
object cbFilled: TCheckBox
|
||||||
AnchorSideLeft.Control = gbBackground
|
AnchorSideLeft.Control = gbBackground
|
||||||
AnchorSideTop.Control = cbFillColor
|
AnchorSideTop.Control = cbFillColor
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
|
AnchorSideRight.Control = cbFillColor
|
||||||
Left = 10
|
Left = 10
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 3
|
Top = 3
|
||||||
Width = 48
|
Width = 62
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Left = 10
|
BorderSpacing.Left = 10
|
||||||
BorderSpacing.Top = 6
|
BorderSpacing.Top = 6
|
||||||
BorderSpacing.Bottom = 10
|
BorderSpacing.Right = 8
|
||||||
|
BorderSpacing.Bottom = 12
|
||||||
Caption = 'Filled'
|
Caption = 'Filled'
|
||||||
OnChange = cbFilledChange
|
OnChange = cbFilledChange
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -71,16 +74,18 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
AnchorSideTop.Control = gbBackground
|
AnchorSideTop.Control = gbBackground
|
||||||
AnchorSideRight.Control = gbBackground
|
AnchorSideRight.Control = gbBackground
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 64
|
Left = 80
|
||||||
Height = 25
|
Height = 25
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 32
|
Width = 32
|
||||||
Anchors = [akTop, akRight]
|
Anchors = [akTop, akRight]
|
||||||
|
BorderSpacing.Left = 8
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
BorderSpacing.Bottom = 8
|
BorderSpacing.Bottom = 8
|
||||||
BorderWidth = 2
|
BorderWidth = 2
|
||||||
ButtonColorSize = 16
|
ButtonColorSize = 16
|
||||||
ButtonColor = clBlack
|
ButtonColor = clBlack
|
||||||
|
Margin = 2
|
||||||
Visible = False
|
Visible = False
|
||||||
OnColorChanged = cbFillColorColorChanged
|
OnColorChanged = cbFillColorColorChanged
|
||||||
end
|
end
|
||||||
@ -92,28 +97,30 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
AnchorSideBottom.Control = gbBackground
|
AnchorSideBottom.Control = gbBackground
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 123
|
Left = 139
|
||||||
Height = 53
|
Height = 54
|
||||||
Top = 31
|
Top = 31
|
||||||
Width = 107
|
Width = 124
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Left = 8
|
BorderSpacing.Left = 8
|
||||||
Caption = 'Border'
|
Caption = 'Border'
|
||||||
ClientHeight = 33
|
ClientHeight = 34
|
||||||
ClientWidth = 103
|
ClientWidth = 120
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
object cbShowBorder: TCheckBox
|
object cbShowBorder: TCheckBox
|
||||||
AnchorSideLeft.Control = gbBorder
|
AnchorSideLeft.Control = gbBorder
|
||||||
AnchorSideTop.Control = cbBorderColor
|
AnchorSideTop.Control = cbBorderColor
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrCenter
|
||||||
|
AnchorSideRight.Control = cbBorderColor
|
||||||
Left = 10
|
Left = 10
|
||||||
Height = 19
|
Height = 19
|
||||||
Top = 3
|
Top = 3
|
||||||
Width = 54
|
Width = 68
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Left = 10
|
BorderSpacing.Left = 10
|
||||||
BorderSpacing.Top = 6
|
BorderSpacing.Top = 6
|
||||||
BorderSpacing.Bottom = 10
|
BorderSpacing.Bottom = 12
|
||||||
Caption = 'Visible '
|
Caption = 'Visible '
|
||||||
OnChange = cbShowBorderChange
|
OnChange = cbShowBorderChange
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -122,16 +129,18 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
AnchorSideTop.Control = gbBorder
|
AnchorSideTop.Control = gbBorder
|
||||||
AnchorSideRight.Control = gbBorder
|
AnchorSideRight.Control = gbBorder
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 65
|
Left = 82
|
||||||
Height = 25
|
Height = 25
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 30
|
Width = 30
|
||||||
Anchors = [akTop, akRight]
|
Anchors = [akTop, akRight]
|
||||||
|
BorderSpacing.Left = 4
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
BorderSpacing.Bottom = 8
|
BorderSpacing.Bottom = 8
|
||||||
BorderWidth = 2
|
BorderWidth = 2
|
||||||
ButtonColorSize = 16
|
ButtonColorSize = 16
|
||||||
ButtonColor = clBlack
|
ButtonColor = clBlack
|
||||||
|
Margin = 2
|
||||||
Visible = False
|
Visible = False
|
||||||
OnColorChanged = cbBorderColorColorChanged
|
OnColorChanged = cbBorderColorColorChanged
|
||||||
end
|
end
|
||||||
@ -142,60 +151,41 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = gbBorder
|
AnchorSideRight.Control = gbBorder
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
AnchorSideBottom.Control = Owner
|
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 95
|
Height = 97
|
||||||
Top = 92
|
Top = 93
|
||||||
Width = 230
|
Width = 263
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
AutoSize = True
|
||||||
BorderSpacing.Top = 8
|
BorderSpacing.Top = 8
|
||||||
Caption = 'Margins'
|
Caption = 'Margins'
|
||||||
ClientHeight = 75
|
ClientHeight = 77
|
||||||
ClientWidth = 226
|
ClientWidth = 259
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
object seTopMargin: TSpinEdit
|
object seTopMargin: TSpinEdit
|
||||||
AnchorSideLeft.Control = gbMargins
|
AnchorSideLeft.Control = gbMargins
|
||||||
AnchorSideLeft.Side = asrCenter
|
AnchorSideLeft.Side = asrCenter
|
||||||
AnchorSideTop.Control = gbMargins
|
AnchorSideTop.Control = gbMargins
|
||||||
Left = 88
|
Left = 104
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 50
|
Width = 50
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Bottom = 4
|
|
||||||
OnChange = seTopMarginChange
|
OnChange = seTopMarginChange
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
end
|
end
|
||||||
object seBottomMargin: TSpinEdit
|
|
||||||
AnchorSideLeft.Control = gbMargins
|
|
||||||
AnchorSideLeft.Side = asrCenter
|
|
||||||
AnchorSideTop.Control = Bevel2
|
|
||||||
AnchorSideTop.Side = asrBottom
|
|
||||||
AnchorSideBottom.Control = gbMargins
|
|
||||||
AnchorSideBottom.Side = asrBottom
|
|
||||||
Left = 88
|
|
||||||
Height = 23
|
|
||||||
Top = 44
|
|
||||||
Width = 50
|
|
||||||
Alignment = taRightJustify
|
|
||||||
Anchors = [akLeft, akBottom]
|
|
||||||
BorderSpacing.Top = 4
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
OnChange = seBottomMarginChange
|
|
||||||
TabOrder = 3
|
|
||||||
end
|
|
||||||
object seLeftMargin: TSpinEdit
|
object seLeftMargin: TSpinEdit
|
||||||
AnchorSideTop.Control = Bevel2
|
AnchorSideTop.Control = seTopMargin
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = seTopMargin
|
AnchorSideRight.Control = seTopMargin
|
||||||
Left = 30
|
Left = 46
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 22
|
Top = 23
|
||||||
Width = 50
|
Width = 50
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
Anchors = [akTop, akRight]
|
Anchors = [akTop, akRight]
|
||||||
BorderSpacing.Top = 4
|
BorderSpacing.Left = 32
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
OnChange = seLeftMarginChange
|
OnChange = seLeftMarginChange
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
@ -203,30 +193,33 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
object seRightMargin: TSpinEdit
|
object seRightMargin: TSpinEdit
|
||||||
AnchorSideLeft.Control = seTopMargin
|
AnchorSideLeft.Control = seTopMargin
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
AnchorSideTop.Control = Bevel2
|
AnchorSideTop.Control = seTopMargin
|
||||||
AnchorSideTop.Side = asrCenter
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 146
|
Left = 162
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 22
|
Top = 23
|
||||||
Width = 50
|
Width = 50
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Left = 8
|
BorderSpacing.Left = 8
|
||||||
BorderSpacing.Top = 4
|
BorderSpacing.Right = 32
|
||||||
OnChange = seRightMarginChange
|
OnChange = seRightMarginChange
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
end
|
end
|
||||||
object Bevel2: TBevel
|
object seBottomMargin: TSpinEdit
|
||||||
AnchorSideLeft.Control = gbMargins
|
AnchorSideLeft.Control = gbMargins
|
||||||
AnchorSideLeft.Side = asrCenter
|
AnchorSideLeft.Side = asrCenter
|
||||||
AnchorSideTop.Control = seTopMargin
|
AnchorSideTop.Control = seLeftMargin
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideBottom.Control = seBottomMargin
|
AnchorSideBottom.Control = gbMargins
|
||||||
Left = 88
|
AnchorSideBottom.Side = asrBottom
|
||||||
Height = 13
|
Left = 104
|
||||||
Top = 27
|
Height = 23
|
||||||
|
Top = 46
|
||||||
Width = 50
|
Width = 50
|
||||||
Anchors = [akTop, akLeft, akBottom]
|
Alignment = taRightJustify
|
||||||
Shape = bsSpacer
|
BorderSpacing.Bottom = 8
|
||||||
|
OnChange = seBottomMarginChange
|
||||||
|
TabOrder = 3
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object Bevel1: TBevel
|
object Bevel1: TBevel
|
||||||
@ -234,7 +227,7 @@ object ShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame
|
|||||||
AnchorSideLeft.Side = asrCenter
|
AnchorSideLeft.Side = asrCenter
|
||||||
AnchorSideTop.Control = cmbShape
|
AnchorSideTop.Control = cmbShape
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 115
|
Left = 131
|
||||||
Height = 50
|
Height = 50
|
||||||
Top = 23
|
Top = 23
|
||||||
Width = 1
|
Width = 1
|
||||||
|
@ -6,7 +6,7 @@ interface
|
|||||||
|
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, Graphics, Forms, Controls, StdCtrls, Dialogs, Spin, ExtCtrls,
|
Classes, SysUtils, Graphics, Forms, Controls, StdCtrls, Dialogs, Spin, ExtCtrls,
|
||||||
TATextElements;
|
TATypes, TATextElements;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
@ -16,7 +16,6 @@ type
|
|||||||
|
|
||||||
TShapeBrushPenMarginsFrame = class(TFrame)
|
TShapeBrushPenMarginsFrame = class(TFrame)
|
||||||
Bevel1: TBevel;
|
Bevel1: TBevel;
|
||||||
Bevel2: TBevel;
|
|
||||||
cbBorderColor: TColorButton;
|
cbBorderColor: TColorButton;
|
||||||
cbFillColor: TColorButton;
|
cbFillColor: TColorButton;
|
||||||
cbFilled: TCheckBox;
|
cbFilled: TCheckBox;
|
||||||
@ -42,17 +41,18 @@ type
|
|||||||
FOnChange: TNotifyEvent;
|
FOnChange: TNotifyEvent;
|
||||||
FOnShapeChange: TShapeChangeEvent;
|
FOnShapeChange: TShapeChangeEvent;
|
||||||
FBrush: TBrush;
|
FBrush: TBrush;
|
||||||
FPen: TPen;
|
FPen: TChartPen;
|
||||||
FMargins: TChartLabelMargins;
|
FMargins: TChartLabelMargins;
|
||||||
FShape: TChartLabelShape;
|
FShape: TChartLabelShape;
|
||||||
|
FLockEvents: Integer;
|
||||||
procedure DoChanged;
|
procedure DoChanged;
|
||||||
procedure DoShapeChanged(AShape: TChartLabelShape);
|
procedure DoShapeChanged(AShape: TChartLabelShape);
|
||||||
procedure UpdateControls;
|
procedure UpdateControls;
|
||||||
public
|
public
|
||||||
constructor Create(AOwner: TComponent); override;
|
constructor Create(AOwner: TComponent); override;
|
||||||
procedure GetData(out AShape: TChartLabelShape; ABrush: TBrush;
|
procedure GetData(out AShape: TChartLabelShape; ABrush: TBrush;
|
||||||
APen: TPen; AMargins: TChartLabelMargins);
|
APen: TChartPen; AMargins: TChartLabelMargins);
|
||||||
procedure Prepare(AShape: TChartLabelShape; ABrush: TBrush; APen: TPen;
|
procedure Prepare(AShape: TChartLabelShape; ABrush: TBrush; APen: TChartPen;
|
||||||
AMargins: TChartLabelMargins);
|
AMargins: TChartLabelMargins);
|
||||||
property OnChange: TNotifyEvent read FOnChange write FOnChange;
|
property OnChange: TNotifyEvent read FOnChange write FOnChange;
|
||||||
property OnShapeChange: TShapeChangeEvent read FOnShapeChange write FOnShapeChange;
|
property OnShapeChange: TShapeChangeEvent read FOnShapeChange write FOnShapeChange;
|
||||||
@ -78,7 +78,7 @@ end;
|
|||||||
procedure TShapeBrushPenMarginsFrame.cbBorderColorColorChanged(Sender: TObject);
|
procedure TShapeBrushPenMarginsFrame.cbBorderColorColorChanged(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
FPen.Color := cbBorderColor.ButtonColor;
|
FPen.Color := cbBorderColor.ButtonColor;
|
||||||
if FPen.Style <> psClear then
|
// if FPen.Style <> psClear then
|
||||||
DoChanged;
|
DoChanged;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -102,25 +102,27 @@ end;
|
|||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.cbShowBorderChange(Sender: TObject);
|
procedure TShapeBrushPenMarginsFrame.cbShowBorderChange(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
if cbShowBorder.Checked then FPen.Style := psSolid else FPen.Style := psClear;
|
FPen.Visible := cbShowBorder.Checked;
|
||||||
|
if FPen.Visible and (FPen.Style = psClear) then FPen.Style := psSolid;
|
||||||
UpdateControls;
|
UpdateControls;
|
||||||
DoChanged;
|
DoChanged;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TShapeBrushPenMarginsFrame.cmbShapeChange(Sender: TObject);
|
||||||
|
begin
|
||||||
|
DoShapeChanged(TChartLabelShape(cmbShape.ItemIndex));
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.DoChanged;
|
procedure TShapeBrushPenMarginsFrame.DoChanged;
|
||||||
begin
|
begin
|
||||||
if Assigned(FOnChange) then FOnChange(Self);
|
if (FLockEvents = 0) and Assigned(FOnChange) then
|
||||||
|
FOnChange(Self);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.DoShapeChanged(AShape: TChartLabelShape);
|
procedure TShapeBrushPenMarginsFrame.DoShapeChanged(AShape: TChartLabelShape);
|
||||||
begin
|
begin
|
||||||
if Assigned(FOnShapeChange) then FOnShapeChange(AShape);
|
if (FLockEvents = 0) and Assigned(FOnShapeChange) then
|
||||||
end;
|
FOnShapeChange(AShape);
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.cmbShapeChange(Sender: TObject);
|
|
||||||
begin
|
|
||||||
FShape := TChartLabelShape(cmbShape.ItemIndex);
|
|
||||||
DoShapeChanged(FShape);
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.seBottomMarginChange(Sender: TObject);
|
procedure TShapeBrushPenMarginsFrame.seBottomMarginChange(Sender: TObject);
|
||||||
@ -148,13 +150,17 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.GetData(out AShape: TChartLabelShape;
|
procedure TShapeBrushPenMarginsFrame.GetData(out AShape: TChartLabelShape;
|
||||||
ABrush: TBrush; APen: TPen; AMargins: TChartLabelMargins);
|
ABrush: TBrush; APen: TChartPen; AMargins: TChartLabelMargins);
|
||||||
begin
|
begin
|
||||||
AShape := TChartLabelShape(cmbShape.ItemIndex);
|
AShape := TChartLabelShape(cmbShape.ItemIndex);
|
||||||
|
if HandleAllocated then
|
||||||
|
begin
|
||||||
if cbFilled.Checked then ABrush.Style := bsSolid else ABrush.Style := bsClear;
|
if cbFilled.Checked then ABrush.Style := bsSolid else ABrush.Style := bsClear;
|
||||||
ABrush.Color := cbFillColor.ButtonColor;
|
ABrush.Color := cbFillColor.ButtonColor;
|
||||||
if cbShowBorder.Checked then APen.Style := psSolid else APen.Style := psClear;
|
APen.Visible := cbShowBorder.Checked;
|
||||||
|
APen.Style := psSolid;
|
||||||
APen.Color := cbBorderColor.ButtonColor;
|
APen.Color := cbBorderColor.ButtonColor;
|
||||||
|
end;
|
||||||
AMargins.Top := seTopMargin.Value;
|
AMargins.Top := seTopMargin.Value;
|
||||||
AMargins.Left := seLeftMargin.Value;
|
AMargins.Left := seLeftMargin.Value;
|
||||||
AMargins.Right := seRightMargin.Value;
|
AMargins.Right := seRightMargin.Value;
|
||||||
@ -162,21 +168,26 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.Prepare(AShape: TChartLabelShape;
|
procedure TShapeBrushPenMarginsFrame.Prepare(AShape: TChartLabelShape;
|
||||||
ABrush: TBrush; APen: TPen; AMargins: TChartLabelMargins);
|
ABrush: TBrush; APen: TChartPen; AMargins: TChartLabelMargins);
|
||||||
begin
|
begin
|
||||||
|
inc(FLockEvents);
|
||||||
FShape := AShape;
|
FShape := AShape;
|
||||||
FBrush := ABrush;
|
FBrush := ABrush;
|
||||||
FPen := APen;
|
FPen := APen;
|
||||||
FMargins := AMargins;
|
FMargins := AMargins;
|
||||||
cmbShape.ItemIndex := ord(AShape);
|
cmbShape.ItemIndex := ord(AShape);
|
||||||
cbFilled.Checked := ABrush.Style <> bsClear;
|
cbFilled.Checked := ABrush.Style <> bsClear;
|
||||||
cbFillColor.ButtonColor := ABrush.Color;
|
cbFillColor.ButtonColor := ColorToRGB(ABrush.Color);
|
||||||
cbShowBorder.Checked := APen.Style <> psClear;
|
cbShowBorder.Checked := APen.EffVisible;
|
||||||
cbBorderColor.ButtonColor := APen.Color;
|
if APen.Color = clDefault then
|
||||||
|
cbBorderColor.ButtonColor := ColorToRGB(clWindowText)
|
||||||
|
else
|
||||||
|
cbBorderColor.ButtonColor := ColorToRGB(APen.Color);
|
||||||
seTopMargin.Value := AMargins.Top;
|
seTopMargin.Value := AMargins.Top;
|
||||||
seLeftMargin.Value := AMargins.Left;
|
seLeftMargin.Value := AMargins.Left;
|
||||||
seRightMargin.Value := AMargins.Right;
|
seRightMargin.Value := AMargins.Right;
|
||||||
seBottomMargin.Value := AMargins.Bottom;
|
seBottomMargin.Value := AMargins.Bottom;
|
||||||
|
dec(FLockEvents);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TShapeBrushPenMarginsFrame.UpdateControls;
|
procedure TShapeBrushPenMarginsFrame.UpdateControls;
|
||||||
|
@ -1,12 +1,13 @@
|
|||||||
object TitleFootEditor: TTitleFootEditor
|
object TitleFootEditor: TTitleFootEditor
|
||||||
Left = 608
|
Left = 608
|
||||||
Height = 467
|
Height = 357
|
||||||
Top = 235
|
Top = 235
|
||||||
Width = 561
|
Width = 561
|
||||||
ActiveControl = cbShow
|
ActiveControl = cbShow
|
||||||
Caption = 'Title/footer editor'
|
Caption = 'Title/footer editor'
|
||||||
ClientHeight = 467
|
ClientHeight = 357
|
||||||
ClientWidth = 561
|
ClientWidth = 561
|
||||||
|
OnActivate = FormActivate
|
||||||
OnCloseQuery = FormCloseQuery
|
OnCloseQuery = FormCloseQuery
|
||||||
OnCreate = FormCreate
|
OnCreate = FormCreate
|
||||||
OnDestroy = FormDestroy
|
OnDestroy = FormDestroy
|
||||||
@ -16,7 +17,7 @@ object TitleFootEditor: TTitleFootEditor
|
|||||||
object ButtonPanel: TButtonPanel
|
object ButtonPanel: TButtonPanel
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 34
|
Height = 34
|
||||||
Top = 427
|
Top = 317
|
||||||
Width = 549
|
Width = 549
|
||||||
OKButton.Name = 'OKButton'
|
OKButton.Name = 'OKButton'
|
||||||
OKButton.DefaultCaption = True
|
OKButton.DefaultCaption = True
|
||||||
@ -33,13 +34,13 @@ object TitleFootEditor: TTitleFootEditor
|
|||||||
end
|
end
|
||||||
object ParamsPanel: TPanel
|
object ParamsPanel: TPanel
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 219
|
Height = 187
|
||||||
Top = 200
|
Top = 122
|
||||||
Width = 545
|
Width = 545
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
BorderSpacing.Around = 8
|
BorderSpacing.Around = 8
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 219
|
ClientHeight = 187
|
||||||
ClientWidth = 545
|
ClientWidth = 545
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
object rgAlignment: TRadioGroup
|
object rgAlignment: TRadioGroup
|
||||||
@ -47,21 +48,23 @@ object TitleFootEditor: TTitleFootEditor
|
|||||||
AnchorSideTop.Control = ParamsPanel
|
AnchorSideTop.Control = ParamsPanel
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 52
|
Height = 51
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 264
|
Width = 211
|
||||||
Anchors = [akTop, akLeft, akBottom]
|
|
||||||
AutoFill = True
|
AutoFill = True
|
||||||
|
AutoSize = True
|
||||||
Caption = 'Alignment'
|
Caption = 'Alignment'
|
||||||
ChildSizing.LeftRightSpacing = 6
|
ChildSizing.LeftRightSpacing = 16
|
||||||
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
ChildSizing.TopBottomSpacing = 6
|
||||||
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
ChildSizing.HorizontalSpacing = 16
|
||||||
|
ChildSizing.EnlargeHorizontal = crsScaleChilds
|
||||||
|
ChildSizing.EnlargeVertical = crsScaleChilds
|
||||||
ChildSizing.ShrinkHorizontal = crsScaleChilds
|
ChildSizing.ShrinkHorizontal = crsScaleChilds
|
||||||
ChildSizing.ShrinkVertical = crsScaleChilds
|
ChildSizing.ShrinkVertical = crsScaleChilds
|
||||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||||
ChildSizing.ControlsPerLine = 3
|
ChildSizing.ControlsPerLine = 3
|
||||||
ClientHeight = 32
|
ClientHeight = 31
|
||||||
ClientWidth = 260
|
ClientWidth = 207
|
||||||
Columns = 3
|
Columns = 3
|
||||||
ItemIndex = 0
|
ItemIndex = 0
|
||||||
Items.Strings = (
|
Items.Strings = (
|
||||||
@ -73,125 +76,49 @@ object TitleFootEditor: TTitleFootEditor
|
|||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
end
|
end
|
||||||
object gbShapeBrushPenMargins: TGroupBox
|
object gbShapeBrushPenMargins: TGroupBox
|
||||||
Left = 288
|
AnchorSideLeft.Control = rgAlignment
|
||||||
Height = 216
|
AnchorSideLeft.Side = asrBottom
|
||||||
|
AnchorSideTop.Control = rgAlignment
|
||||||
|
AnchorSideRight.Control = ParamsPanel
|
||||||
|
AnchorSideRight.Side = asrBottom
|
||||||
|
Left = 235
|
||||||
|
Height = 168
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 255
|
Width = 310
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
BorderSpacing.Left = 24
|
||||||
Caption = 'Title/footer background'
|
Caption = 'Title/footer background'
|
||||||
ClientHeight = 196
|
|
||||||
ClientWidth = 251
|
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
inline ShapeBrushPenMarginsFrame1: TShapeBrushPenMarginsFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 188
|
|
||||||
Width = 235
|
|
||||||
Align = alClient
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
ClientHeight = 188
|
|
||||||
ClientWidth = 235
|
|
||||||
inherited cmbShape: TComboBox
|
|
||||||
AnchorSideLeft.Control = ShapeBrushPenMarginsFrame1
|
|
||||||
AnchorSideTop.Control = ShapeBrushPenMarginsFrame1
|
|
||||||
AnchorSideRight.Control = ShapeBrushPenMarginsFrame1
|
|
||||||
Width = 235
|
|
||||||
end
|
|
||||||
inherited gbBackground: TGroupBox
|
|
||||||
AnchorSideLeft.Control = ShapeBrushPenMarginsFrame1
|
|
||||||
Width = 110
|
|
||||||
ClientWidth = 106
|
|
||||||
inherited cbFillColor: TColorButton
|
|
||||||
Left = 66
|
|
||||||
end
|
|
||||||
end
|
|
||||||
inherited gbBorder: TGroupBox
|
|
||||||
AnchorSideRight.Control = ShapeBrushPenMarginsFrame1
|
|
||||||
Left = 125
|
|
||||||
Width = 110
|
|
||||||
ClientWidth = 106
|
|
||||||
inherited cbBorderColor: TColorButton
|
|
||||||
Left = 68
|
|
||||||
end
|
|
||||||
end
|
|
||||||
inherited gbMargins: TGroupBox
|
|
||||||
AnchorSideBottom.Control = ShapeBrushPenMarginsFrame1
|
|
||||||
Height = 96
|
|
||||||
Width = 235
|
|
||||||
ClientHeight = 76
|
|
||||||
ClientWidth = 231
|
|
||||||
inherited seTopMargin: TSpinEdit
|
|
||||||
Left = 90
|
|
||||||
end
|
|
||||||
inherited seBottomMargin: TSpinEdit
|
|
||||||
Left = 90
|
|
||||||
Top = 45
|
|
||||||
end
|
|
||||||
inherited seLeftMargin: TSpinEdit
|
|
||||||
Left = 32
|
|
||||||
Top = 23
|
|
||||||
end
|
|
||||||
inherited seRightMargin: TSpinEdit
|
|
||||||
Left = 148
|
|
||||||
Top = 23
|
|
||||||
end
|
|
||||||
inherited Bevel2: TBevel
|
|
||||||
Left = 90
|
|
||||||
Height = 14
|
|
||||||
end
|
|
||||||
end
|
|
||||||
inherited Bevel1: TBevel
|
|
||||||
Left = 117
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
object gbFont: TGroupBox
|
object gbFont: TGroupBox
|
||||||
|
AnchorSideLeft.Control = rgAlignment
|
||||||
|
AnchorSideTop.Control = rgAlignment
|
||||||
|
AnchorSideTop.Side = asrBottom
|
||||||
|
AnchorSideRight.Control = rgAlignment
|
||||||
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 106
|
Height = 61
|
||||||
Top = 88
|
Top = 75
|
||||||
Width = 264
|
Width = 211
|
||||||
|
Anchors = [akTop, akLeft, akRight]
|
||||||
|
BorderSpacing.Top = 24
|
||||||
Caption = 'Font'
|
Caption = 'Font'
|
||||||
ClientHeight = 86
|
|
||||||
ClientWidth = 260
|
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
inline FontFrame1: TFontFrame
|
|
||||||
Left = 8
|
|
||||||
Height = 78
|
|
||||||
Width = 244
|
|
||||||
Align = alClient
|
|
||||||
BorderSpacing.Left = 8
|
|
||||||
BorderSpacing.Right = 8
|
|
||||||
BorderSpacing.Bottom = 8
|
|
||||||
ClientHeight = 78
|
|
||||||
ClientWidth = 244
|
|
||||||
inherited cmbFontName: TComboBox
|
|
||||||
AnchorSideLeft.Control = FontFrame1
|
|
||||||
AnchorSideTop.Control = FontFrame1
|
|
||||||
AnchorSideRight.Control = FontFrame1
|
|
||||||
Width = 244
|
|
||||||
end
|
|
||||||
inherited cbFontColor: TColorButton
|
|
||||||
AnchorSideRight.Control = FontFrame1
|
|
||||||
Left = 212
|
|
||||||
end
|
|
||||||
inherited cbBold: TCheckBox
|
|
||||||
AnchorSideLeft.Control = FontFrame1
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object MemoPanel: TPanel
|
object MemoPanel: TPanel
|
||||||
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 159
|
Height = 81
|
||||||
Top = 33
|
Top = 33
|
||||||
Width = 545
|
Width = 545
|
||||||
Align = alClient
|
Align = alClient
|
||||||
BorderSpacing.Left = 8
|
BorderSpacing.Left = 8
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
ClientHeight = 159
|
ClientHeight = 81
|
||||||
ClientWidth = 545
|
ClientWidth = 545
|
||||||
Constraints.MinHeight = 100
|
Constraints.MinHeight = 80
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object lblText: TLabel
|
object lblText: TLabel
|
||||||
AnchorSideLeft.Control = MemoPanel
|
AnchorSideLeft.Control = MemoPanel
|
||||||
@ -212,7 +139,7 @@ object TitleFootEditor: TTitleFootEditor
|
|||||||
AnchorSideBottom.Control = MemoPanel
|
AnchorSideBottom.Control = MemoPanel
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 140
|
Height = 62
|
||||||
Top = 19
|
Top = 19
|
||||||
Width = 545
|
Width = 545
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
|
@ -16,7 +16,6 @@ type
|
|||||||
TTitleFootEditor = class(TForm)
|
TTitleFootEditor = class(TForm)
|
||||||
ButtonPanel: TButtonPanel;
|
ButtonPanel: TButtonPanel;
|
||||||
cbShow: TCheckBox;
|
cbShow: TCheckBox;
|
||||||
FontFrame1: TFontFrame;
|
|
||||||
gbShapeBrushPenMargins: TGroupBox;
|
gbShapeBrushPenMargins: TGroupBox;
|
||||||
gbFont: TGroupBox;
|
gbFont: TGroupBox;
|
||||||
lblText: TLabel;
|
lblText: TLabel;
|
||||||
@ -25,8 +24,8 @@ type
|
|||||||
PanelTop: TPanel;
|
PanelTop: TPanel;
|
||||||
ParamsPanel: TPanel;
|
ParamsPanel: TPanel;
|
||||||
rgAlignment: TRadioGroup;
|
rgAlignment: TRadioGroup;
|
||||||
ShapeBrushPenMarginsFrame1: TShapeBrushPenMarginsFrame;
|
|
||||||
procedure cbShowChange(Sender: TObject);
|
procedure cbShowChange(Sender: TObject);
|
||||||
|
procedure FormActivate(Sender: TObject);
|
||||||
procedure FormCloseQuery(Sender: TObject; var CanClose: boolean);
|
procedure FormCloseQuery(Sender: TObject; var CanClose: boolean);
|
||||||
procedure FormCreate(Sender: TObject);
|
procedure FormCreate(Sender: TObject);
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
@ -37,10 +36,13 @@ type
|
|||||||
private
|
private
|
||||||
FTitle: TChartTitle;
|
FTitle: TChartTitle;
|
||||||
FSavedTitle: TChartTitle;
|
FSavedTitle: TChartTitle;
|
||||||
|
FFontFrame: TFontFrame;
|
||||||
|
FShapeBrushPenMarginsFrame: TShapeBrushPenMarginsFrame;
|
||||||
FOKClicked: boolean;
|
FOKClicked: boolean;
|
||||||
procedure ChangedHandler(Sender: TObject);
|
procedure ChangedHandler(Sender: TObject);
|
||||||
function GetAlignment: TAlignment;
|
function GetAlignment: TAlignment;
|
||||||
procedure SetAlignment(AValue: TAlignment);
|
procedure SetAlignment(AValue: TAlignment);
|
||||||
|
procedure ShapeChangedHandler(AShape: TChartLabelShape);
|
||||||
protected
|
protected
|
||||||
function GetChart: TChart;
|
function GetChart: TChart;
|
||||||
public
|
public
|
||||||
@ -69,6 +71,21 @@ begin
|
|||||||
gbFont.Visible := cbShow.Checked;
|
gbFont.Visible := cbShow.Checked;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TTitleFootEditor.FormActivate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
Constraints.MinHeight := PanelTop.Height +
|
||||||
|
MemoPanel.Constraints.MinHeight +
|
||||||
|
ParamsPanel.Height + ParamsPanel.BorderSpacing.Around*2 +
|
||||||
|
ButtonPanel.Height + ButtonPanel.BorderSpacing.Around*2;
|
||||||
|
|
||||||
|
Constraints.MinWidth := gbFont.Width +
|
||||||
|
gbShapeBrushPenMargins.Width + gbShapeBrushPenMargins.BorderSpacing.Left +
|
||||||
|
ParamsPanel.BorderSpacing.Around * 2;
|
||||||
|
|
||||||
|
Width := 1; // Enforce the constraints.
|
||||||
|
Height := 1;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TTitleFootEditor.ChangedHandler(Sender: TObject);
|
procedure TTitleFootEditor.ChangedHandler(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
GetChart.Invalidate;
|
GetChart.Invalidate;
|
||||||
@ -88,9 +105,30 @@ end;
|
|||||||
|
|
||||||
procedure TTitleFootEditor.FormCreate(Sender: TObject);
|
procedure TTitleFootEditor.FormCreate(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
// Insert frames at runtime - this makes life much easier...
|
||||||
|
FFontFrame := TFontFrame.Create(self);
|
||||||
|
FFontFrame.Parent := gbFont;
|
||||||
|
FFontFrame.Align := alClient;
|
||||||
|
FFontFrame.BorderSpacing.Left := 8;
|
||||||
|
FFontFrame.BorderSpacing.Right := 8;
|
||||||
|
FFontFrame.BorderSpacing.Bottom := 0;//8;
|
||||||
|
FFontFrame.OnChange := @ChangedHandler;
|
||||||
|
gbFont.AutoSize := true;
|
||||||
|
|
||||||
|
FShapeBrushPenMarginsFrame := TShapeBrushPenMarginsFrame.Create(self);
|
||||||
|
FShapeBrushPenMarginsFrame.Parent := gbShapeBrushPenMargins;
|
||||||
|
FShapeBrushPenMarginsFrame.Align := alClient;
|
||||||
|
FShapeBrushPenMarginsFrame.BorderSpacing.Left := 8;
|
||||||
|
FShapeBrushPenMarginsFrame.BorderSpacing.Right := 8;
|
||||||
|
FShapeBrushPenMarginsFrame.BorderSpacing.Bottom := 8;
|
||||||
|
FShapeBrushPenMarginsFrame.Constraints.MinWidth := 230;
|
||||||
|
FShapeBrushPenMarginsFrame.OnChange := @ChangedHandler;
|
||||||
|
FShapeBrushPenMarginsFrame.OnShapeChange := @ShapeChangedHandler;
|
||||||
|
gbShapeBrushPenMargins.AutoSize := true;
|
||||||
|
|
||||||
BoldHeaders(Self);
|
BoldHeaders(Self);
|
||||||
FontFrame1.OnChange := @ChangedHandler;
|
|
||||||
ShapeBrushPenMarginsFrame1.OnChange := @ChangedHandler;
|
ParamsPanel.AutoSize := true;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TTitleFootEditor.FormDestroy(Sender: TObject);
|
procedure TTitleFootEditor.FormDestroy(Sender: TObject);
|
||||||
@ -100,12 +138,14 @@ end;
|
|||||||
|
|
||||||
procedure TTitleFootEditor.FormShow(Sender: TObject);
|
procedure TTitleFootEditor.FormShow(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
(*
|
||||||
if cbShow.Checked then begin
|
if cbShow.Checked then begin
|
||||||
AutoSize := true;
|
AutoSize := true;
|
||||||
Constraints.MinWidth := Width;
|
Constraints.MinWidth := Width;
|
||||||
Constraints.MinHeight := Height;
|
Constraints.MinHeight := Height;
|
||||||
AutoSize := false;
|
AutoSize := false;
|
||||||
end;
|
end;
|
||||||
|
*)
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TTitleFootEditor.mmoTextChange(Sender: TObject);
|
procedure TTitleFootEditor.mmoTextChange(Sender: TObject);
|
||||||
@ -145,8 +185,9 @@ begin
|
|||||||
SetAlignment(ATitle.Alignment);
|
SetAlignment(ATitle.Alignment);
|
||||||
|
|
||||||
mmoText.Font.Assign(ATitle.Font);
|
mmoText.Font.Assign(ATitle.Font);
|
||||||
FontFrame1.Prepare(ATitle.Font, false);
|
mmoText.Font.Orientation := 0;
|
||||||
ShapeBrushPenMarginsFrame1.Prepare(ATitle.Shape, ATitle.Brush, ATitle.Frame, ATitle.Margins);
|
FFontFrame.Prepare(ATitle.Font, false);
|
||||||
|
FShapeBrushPenMarginsFrame.Prepare(ATitle.Shape, ATitle.Brush, ATitle.Frame, ATitle.Margins);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TTitleFootEditor.rgAlignmentClick(Sender: TObject);
|
procedure TTitleFootEditor.rgAlignmentClick(Sender: TObject);
|
||||||
@ -161,5 +202,10 @@ begin
|
|||||||
rgAlignment.ItemIndex := ALIGNMENTS[AValue];
|
rgAlignment.ItemIndex := ALIGNMENTS[AValue];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TTitleFootEditor.ShapeChangedHandler(AShape: TChartLabelShape);
|
||||||
|
begin
|
||||||
|
FTitle.Shape := AShape;
|
||||||
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user