mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-22 13:39:30 +02:00
VirtualTreeView: Improve Advanced sample project
This commit is contained in:
parent
d5040729df
commit
76d430baad
@ -9,6 +9,7 @@
|
|||||||
<CompatibilityMode Value="True"/>
|
<CompatibilityMode Value="True"/>
|
||||||
</Flags>
|
</Flags>
|
||||||
<SessionStorage Value="InProjectDir"/>
|
<SessionStorage Value="InProjectDir"/>
|
||||||
|
<Scaled Value="True"/>
|
||||||
<ResourceType Value="res"/>
|
<ResourceType Value="res"/>
|
||||||
<UseXPManifest Value="True"/>
|
<UseXPManifest Value="True"/>
|
||||||
<XPManifest>
|
<XPManifest>
|
||||||
|
@ -25,7 +25,8 @@ uses
|
|||||||
{$R extraresources.res}
|
{$R extraresources.res}
|
||||||
|
|
||||||
begin
|
begin
|
||||||
Application.Title:='';
|
Application.Scaled := True;
|
||||||
|
Application.Title := '';
|
||||||
Application.Initialize;
|
Application.Initialize;
|
||||||
Application.CreateForm(TMainForm, MainForm);
|
Application.CreateForm(TMainForm, MainForm);
|
||||||
Application.CreateForm(TStateForm, StateForm);
|
Application.CreateForm(TStateForm, StateForm);
|
||||||
|
@ -3,43 +3,41 @@ object GeneralForm: TGeneralForm
|
|||||||
Height = 536
|
Height = 536
|
||||||
Top = 185
|
Top = 185
|
||||||
Width = 804
|
Width = 804
|
||||||
ActiveControl = BitBtn1
|
ActiveControl = TreeFontButton
|
||||||
Caption = 'GeneralForm'
|
Caption = 'GeneralForm'
|
||||||
ClientHeight = 536
|
ClientHeight = 536
|
||||||
ClientWidth = 804
|
ClientWidth = 804
|
||||||
KeyPreview = True
|
KeyPreview = True
|
||||||
OnCreate = FormCreate
|
|
||||||
ShowHint = True
|
ShowHint = True
|
||||||
LCLVersion = '2.1.0.0'
|
LCLVersion = '3.99.0.0'
|
||||||
object Label18: TLabel
|
OnCreate = FormCreate
|
||||||
AnchorSideLeft.Control = RadioGroup2
|
object SwitchCheckImagesLabel: TLabel
|
||||||
AnchorSideTop.Control = RadioGroup2
|
AnchorSideLeft.Control = DrawSelectionModeRadioGroup
|
||||||
|
AnchorSideTop.Control = DrawSelectionModeRadioGroup
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 576
|
Left = 575
|
||||||
Height = 15
|
Height = 15
|
||||||
Top = 374
|
Top = 387
|
||||||
Width = 113
|
Width = 113
|
||||||
Anchors = [akTop, akRight]
|
BorderSpacing.Top = 10
|
||||||
BorderSpacing.Top = 20
|
|
||||||
Caption = 'Switch check images:'
|
Caption = 'Switch check images:'
|
||||||
ParentColor = False
|
ParentColor = False
|
||||||
end
|
end
|
||||||
object Label19: TLabel
|
object SwitchMainColumnLabel: TLabel
|
||||||
AnchorSideLeft.Control = CheckMarkCombo
|
AnchorSideLeft.Control = CheckMarkCombo
|
||||||
AnchorSideTop.Control = CheckMarkCombo
|
AnchorSideTop.Control = CheckMarkCombo
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 572
|
Left = 575
|
||||||
Height = 15
|
Height = 15
|
||||||
Top = 434
|
Top = 437
|
||||||
Width = 112
|
Width = 112
|
||||||
Anchors = [akTop, akRight]
|
BorderSpacing.Top = 10
|
||||||
BorderSpacing.Top = 20
|
|
||||||
Caption = 'Switch main column:'
|
Caption = 'Switch main column:'
|
||||||
ParentColor = False
|
ParentColor = False
|
||||||
end
|
end
|
||||||
object Label8: TLabel
|
object Label8: TLabel
|
||||||
AnchorSideLeft.Control = BitBtn1
|
AnchorSideLeft.Control = TreeFontButton
|
||||||
AnchorSideTop.Control = BitBtn1
|
AnchorSideTop.Control = TreeFontButton
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = SaveButton
|
AnchorSideRight.Control = SaveButton
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
@ -54,13 +52,15 @@ object GeneralForm: TGeneralForm
|
|||||||
WordWrap = True
|
WordWrap = True
|
||||||
end
|
end
|
||||||
object VST2: TLazVirtualStringTree
|
object VST2: TLazVirtualStringTree
|
||||||
|
AnchorSideRight.Control = Label8
|
||||||
Left = 5
|
Left = 5
|
||||||
Height = 523
|
Height = 523
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 556
|
Width = 562
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
AutoExpandDelay = 300
|
AutoExpandDelay = 300
|
||||||
ButtonFillMode = fmWindowColor
|
BorderSpacing.Right = 8
|
||||||
|
ButtonFillMode = fmTransparent
|
||||||
CheckImageKind = ckDarkTick
|
CheckImageKind = ckDarkTick
|
||||||
ClipboardFormats.Strings = (
|
ClipboardFormats.Strings = (
|
||||||
'HTML Format'
|
'HTML Format'
|
||||||
@ -72,7 +72,7 @@ object GeneralForm: TGeneralForm
|
|||||||
Colors.DropTargetBorderColor = clActiveCaption
|
Colors.DropTargetBorderColor = clActiveCaption
|
||||||
Colors.HotColor = clBlack
|
Colors.HotColor = clBlack
|
||||||
Colors.UnfocusedSelectionBorderColor = clBtnShadow
|
Colors.UnfocusedSelectionBorderColor = clBtnShadow
|
||||||
DefaultNodeHeight = 24
|
DefaultNodeHeight = 25
|
||||||
DefaultText = 'Node'
|
DefaultText = 'Node'
|
||||||
DragCursor = crHelp
|
DragCursor = crHelp
|
||||||
DrawSelectionMode = smBlendedRectangle
|
DrawSelectionMode = smBlendedRectangle
|
||||||
@ -93,7 +93,7 @@ object GeneralForm: TGeneralForm
|
|||||||
Options = [coEnabled, coParentBidiMode, coVisible]
|
Options = [coEnabled, coParentBidiMode, coVisible]
|
||||||
Position = 0
|
Position = 0
|
||||||
Spacing = 0
|
Spacing = 0
|
||||||
Width = 22
|
Width = 15
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
BiDiMode = bdLeftToRight
|
BiDiMode = bdLeftToRight
|
||||||
@ -104,14 +104,13 @@ object GeneralForm: TGeneralForm
|
|||||||
Text = 'Language column'
|
Text = 'Language column'
|
||||||
Width = 300
|
Width = 300
|
||||||
end>
|
end>
|
||||||
Header.DefaultHeight = 17
|
|
||||||
Header.Height = 45
|
|
||||||
Header.Options = [hoColumnResize, hoDblClickResize, hoDrag, hoHotTrack, hoShowHint, hoVisible]
|
Header.Options = [hoColumnResize, hoDblClickResize, hoDrag, hoHotTrack, hoShowHint, hoVisible]
|
||||||
Header.ParentFont = True
|
Header.ParentFont = True
|
||||||
Header.Style = hsFlatButtons
|
Header.Style = hsFlatButtons
|
||||||
HintMode = hmTooltip
|
HintMode = hmTooltip
|
||||||
HotCursor = crHandPoint
|
HotCursor = crHandPoint
|
||||||
Images = TreeImages
|
Images = TreeImages
|
||||||
|
ParentBiDiMode = False
|
||||||
ParentFont = False
|
ParentFont = False
|
||||||
RootNodeCount = 5
|
RootNodeCount = 5
|
||||||
ScrollBarOptions.VerticalIncrement = 19
|
ScrollBarOptions.VerticalIncrement = 19
|
||||||
@ -136,12 +135,12 @@ object GeneralForm: TGeneralForm
|
|||||||
OnStateChange = VST2StateChange
|
OnStateChange = VST2StateChange
|
||||||
end
|
end
|
||||||
object CheckMarkCombo: TComboBox
|
object CheckMarkCombo: TComboBox
|
||||||
AnchorSideLeft.Control = RadioGroup2
|
AnchorSideLeft.Control = DrawSelectionModeRadioGroup
|
||||||
AnchorSideTop.Control = Label18
|
AnchorSideTop.Control = SwitchCheckImagesLabel
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 575
|
Left = 575
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 391
|
Top = 404
|
||||||
Width = 211
|
Width = 211
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
BorderSpacing.Top = 2
|
BorderSpacing.Top = 2
|
||||||
@ -157,31 +156,30 @@ object GeneralForm: TGeneralForm
|
|||||||
'System flat check images'
|
'System flat check images'
|
||||||
'System default check images'
|
'System default check images'
|
||||||
)
|
)
|
||||||
OnChange = CheckMarkComboChange
|
|
||||||
PopupMenu = PopupMenu1
|
PopupMenu = PopupMenu1
|
||||||
Style = csDropDownList
|
Style = csDropDownList
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
|
OnChange = CheckMarkComboChange
|
||||||
end
|
end
|
||||||
object MainColumnUpDown: TUpDown
|
object MainColumnUpDown: TUpDown
|
||||||
AnchorSideLeft.Control = Label19
|
AnchorSideLeft.Control = SwitchMainColumnLabel
|
||||||
AnchorSideTop.Control = Label19
|
AnchorSideTop.Control = SwitchMainColumnLabel
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 572
|
Left = 575
|
||||||
Height = 16
|
Height = 21
|
||||||
Top = 451
|
Top = 454
|
||||||
Width = 35
|
Width = 41
|
||||||
Anchors = [akTop, akLeft, akRight]
|
|
||||||
BorderSpacing.Top = 2
|
BorderSpacing.Top = 2
|
||||||
Increment = 2
|
Increment = 2
|
||||||
Max = 2
|
Max = 2
|
||||||
Min = 0
|
Min = 0
|
||||||
OnChanging = MainColumnUpDownChanging
|
|
||||||
Orientation = udHorizontal
|
Orientation = udHorizontal
|
||||||
Position = 2
|
Position = 2
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
Wrap = True
|
Wrap = True
|
||||||
|
OnChanging = MainColumnUpDownChanging
|
||||||
end
|
end
|
||||||
object BitBtn1: TBitBtn
|
object TreeFontButton: TBitBtn
|
||||||
AnchorSideTop.Control = Owner
|
AnchorSideTop.Control = Owner
|
||||||
AnchorSideRight.Control = SaveButton
|
AnchorSideRight.Control = SaveButton
|
||||||
Left = 575
|
Left = 575
|
||||||
@ -209,17 +207,17 @@ object GeneralForm: TGeneralForm
|
|||||||
33333300C000CC0333333333333330CCCCCCCC03333333333333300000000033
|
33333300C000CC0333333333333330CCCCCCCC03333333333333300000000033
|
||||||
3333333333333333333333333333333333333333333333333333
|
3333333333333333333333333333333333333333333333333333
|
||||||
}
|
}
|
||||||
OnClick = BitBtn1Click
|
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
|
OnClick = TreeFontButtonClick
|
||||||
end
|
end
|
||||||
object RadioGroup1: TRadioGroup
|
object TreeButtonLookRadioGroup: TRadioGroup
|
||||||
AnchorSideLeft.Control = ThemeRadioGroup
|
AnchorSideLeft.Control = ThemeRadioGroup
|
||||||
AnchorSideTop.Control = ThemeRadioGroup
|
AnchorSideTop.Control = ThemeRadioGroup
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = ThemeRadioGroup
|
AnchorSideRight.Control = ThemeRadioGroup
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 575
|
Left = 575
|
||||||
Height = 70
|
Height = 93
|
||||||
Top = 204
|
Top = 204
|
||||||
Width = 221
|
Width = 221
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
@ -235,25 +233,44 @@ object GeneralForm: TGeneralForm
|
|||||||
ChildSizing.ShrinkVertical = crsScaleChilds
|
ChildSizing.ShrinkVertical = crsScaleChilds
|
||||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||||
ChildSizing.ControlsPerLine = 1
|
ChildSizing.ControlsPerLine = 1
|
||||||
ClientHeight = 50
|
ClientHeight = 73
|
||||||
ClientWidth = 217
|
ClientWidth = 217
|
||||||
ItemIndex = 0
|
ItemIndex = 0
|
||||||
Items.Strings = (
|
Items.Strings = (
|
||||||
'Usual +/- buttons and lines'
|
'Usual +/- buttons and lines'
|
||||||
'Little triangles without lines'
|
'Little triangles without lines'
|
||||||
)
|
)
|
||||||
OnClick = RadioGroup1Click
|
|
||||||
TabOrder = 4
|
TabOrder = 4
|
||||||
|
OnClick = TreeButtonLookRadioGroupClick
|
||||||
|
object ButtonFillModeCombo: TComboBox
|
||||||
|
Left = 6
|
||||||
|
Height = 23
|
||||||
|
Hint = 'Applies only to +/- buttons'
|
||||||
|
Top = 44
|
||||||
|
Width = 205
|
||||||
|
ItemHeight = 15
|
||||||
|
ItemIndex = 0
|
||||||
|
Items.Strings = (
|
||||||
|
'tree''s background color'
|
||||||
|
'clWindow'
|
||||||
|
'color gradient, Windows XP style (legacy code, use toThemeAware on Windows XP instead)'
|
||||||
|
'transparent color'
|
||||||
|
)
|
||||||
|
Style = csDropDownList
|
||||||
|
TabOrder = 3
|
||||||
|
Text = 'tree''s background color'
|
||||||
|
OnChange = ButtonFillModeComboChange
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object RadioGroup2: TRadioGroup
|
object DrawSelectionModeRadioGroup: TRadioGroup
|
||||||
AnchorSideLeft.Control = RadioGroup1
|
AnchorSideLeft.Control = TreeButtonLookRadioGroup
|
||||||
AnchorSideTop.Control = RadioGroup1
|
AnchorSideTop.Control = TreeButtonLookRadioGroup
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = RadioGroup1
|
AnchorSideRight.Control = TreeButtonLookRadioGroup
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 575
|
Left = 575
|
||||||
Height = 70
|
Height = 70
|
||||||
Top = 284
|
Top = 307
|
||||||
Width = 221
|
Width = 221
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
AutoFill = True
|
AutoFill = True
|
||||||
@ -275,11 +292,11 @@ object GeneralForm: TGeneralForm
|
|||||||
'Dotted rectangle'
|
'Dotted rectangle'
|
||||||
'Alpha blended rectangle'
|
'Alpha blended rectangle'
|
||||||
)
|
)
|
||||||
OnClick = RadioGroup2Click
|
|
||||||
TabOrder = 5
|
TabOrder = 5
|
||||||
|
OnClick = DrawSelectionModeRadioGroupClick
|
||||||
end
|
end
|
||||||
object ThemeRadioGroup: TRadioGroup
|
object ThemeRadioGroup: TRadioGroup
|
||||||
AnchorSideLeft.Control = BitBtn1
|
AnchorSideLeft.Control = TreeFontButton
|
||||||
AnchorSideTop.Control = Label8
|
AnchorSideTop.Control = Label8
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = SaveButton
|
AnchorSideRight.Control = SaveButton
|
||||||
@ -307,14 +324,14 @@ object GeneralForm: TGeneralForm
|
|||||||
'Theme aware'
|
'Theme aware'
|
||||||
'Not theme aware'
|
'Not theme aware'
|
||||||
)
|
)
|
||||||
OnClick = ThemeRadioGroupClick
|
|
||||||
TabOrder = 6
|
TabOrder = 6
|
||||||
|
OnClick = ThemeRadioGroupClick
|
||||||
end
|
end
|
||||||
object SaveButton: TBitBtn
|
object SaveButton: TBitBtn
|
||||||
AnchorSideTop.Control = BitBtn1
|
AnchorSideTop.Control = TreeFontButton
|
||||||
AnchorSideRight.Control = Owner
|
AnchorSideRight.Control = Owner
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
AnchorSideBottom.Control = BitBtn1
|
AnchorSideBottom.Control = TreeFontButton
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 700
|
Left = 700
|
||||||
Height = 34
|
Height = 34
|
||||||
@ -324,12 +341,24 @@ object GeneralForm: TGeneralForm
|
|||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Right = 8
|
BorderSpacing.Right = 8
|
||||||
Caption = 'Save as text...'
|
Caption = 'Save as text...'
|
||||||
OnClick = SaveButtonClick
|
|
||||||
TabOrder = 7
|
TabOrder = 7
|
||||||
|
OnClick = SaveButtonClick
|
||||||
|
end
|
||||||
|
object MainColumnLabel: TLabel
|
||||||
|
AnchorSideLeft.Control = MainColumnUpDown
|
||||||
|
AnchorSideLeft.Side = asrBottom
|
||||||
|
AnchorSideTop.Control = MainColumnUpDown
|
||||||
|
AnchorSideTop.Side = asrCenter
|
||||||
|
Left = 624
|
||||||
|
Height = 15
|
||||||
|
Top = 457
|
||||||
|
Width = 98
|
||||||
|
BorderSpacing.Left = 8
|
||||||
|
Caption = 'MainColumnLabel'
|
||||||
end
|
end
|
||||||
object TreeImages: TImageList
|
object TreeImages: TImageList
|
||||||
Left = 22
|
Left = 168
|
||||||
Top = 148
|
Top = 232
|
||||||
Bitmap = {
|
Bitmap = {
|
||||||
4C7A120000001000000010000000200400000000000078DAED9A8B9283200C45
|
4C7A120000001000000010000000200400000000000078DAED9A8B9283200C45
|
||||||
F3F17CDBFE16BB6E4B1B631E37C1BA75AD338C7D7812406E0828D13B1CAD2F65
|
F3F17CDBFE16BB6E4B1B631E37C1BA75AD338C7D7812406E0828D13B1CAD2F65
|
||||||
@ -372,11 +401,11 @@ object GeneralForm: TGeneralForm
|
|||||||
Font.Name = 'MS Sans Serif'
|
Font.Name = 'MS Sans Serif'
|
||||||
MinFontSize = 0
|
MinFontSize = 0
|
||||||
MaxFontSize = 0
|
MaxFontSize = 0
|
||||||
Left = 84
|
Left = 240
|
||||||
Top = 148
|
Top = 88
|
||||||
end
|
end
|
||||||
object PopupMenu1: TPopupMenu
|
object PopupMenu1: TPopupMenu
|
||||||
Left = 116
|
Left = 168
|
||||||
Top = 148
|
Top = 148
|
||||||
object Onemenuitem1: TMenuItem
|
object Onemenuitem1: TMenuItem
|
||||||
Caption = 'Menu items'
|
Caption = 'Menu items'
|
||||||
@ -391,14 +420,14 @@ object GeneralForm: TGeneralForm
|
|||||||
object SaveDialog: TSaveDialog
|
object SaveDialog: TSaveDialog
|
||||||
Filter = 'HTML file in UTF-8 (*.htm; *.html)|*.htm;*.html|Unicode UTF-16 text file (*.uni)|*.uni|Rich text UTF-16 file (*.rtf)|*.rtf|Comma separated values ANSI text file (*.csv)|*.csv|Unicode UTF-8 text file (*.txt)|*.txt|Plain ANSI text file (*.txt)|*.txt'
|
Filter = 'HTML file in UTF-8 (*.htm; *.html)|*.htm;*.html|Unicode UTF-16 text file (*.uni)|*.uni|Rich text UTF-16 file (*.rtf)|*.rtf|Comma separated values ANSI text file (*.csv)|*.csv|Unicode UTF-8 text file (*.txt)|*.txt|Plain ANSI text file (*.txt)|*.txt'
|
||||||
Options = [ofOverwritePrompt, ofHideReadOnly, ofExtensionDifferent, ofEnableSizing]
|
Options = [ofOverwritePrompt, ofHideReadOnly, ofExtensionDifferent, ofEnableSizing]
|
||||||
Left = 148
|
Left = 240
|
||||||
Top = 148
|
Top = 148
|
||||||
end
|
end
|
||||||
object ImageList1: TImageList
|
object ImageList1: TImageList
|
||||||
Height = 24
|
Height = 24
|
||||||
Width = 24
|
Width = 24
|
||||||
Left = 32
|
Left = 168
|
||||||
Top = 200
|
Top = 296
|
||||||
Bitmap = {
|
Bitmap = {
|
||||||
4C7A510000001800000018000000B5DD00000000000078DAEC9D075814D7D7FF
|
4C7A510000001800000018000000B5DD00000000000078DAEC9D075814D7D7FF
|
||||||
2355EC3DD19898C4C49698A8D1A8A996148D89D1C498C4184D31F6167B8935C6
|
2355EC3DD19898C4C49698A8D1A8A996148D89D1C498C4184D31F6167B8935C6
|
||||||
|
@ -25,12 +25,14 @@ uses
|
|||||||
|
|
||||||
type
|
type
|
||||||
TGeneralForm = class(TForm)
|
TGeneralForm = class(TForm)
|
||||||
|
ButtonFillModeCombo: TComboBox;
|
||||||
|
MainColumnLabel: TLabel;
|
||||||
VST2: TLazVirtualStringTree;
|
VST2: TLazVirtualStringTree;
|
||||||
CheckMarkCombo: TComboBox;
|
CheckMarkCombo: TComboBox;
|
||||||
Label18: TLabel;
|
SwitchCheckImagesLabel: TLabel;
|
||||||
MainColumnUpDown: TUpDown;
|
MainColumnUpDown: TUpDown;
|
||||||
Label19: TLabel;
|
SwitchMainColumnLabel: TLabel;
|
||||||
BitBtn1: TBitBtn;
|
TreeFontButton: TBitBtn;
|
||||||
Label8: TLabel;
|
Label8: TLabel;
|
||||||
TreeImages: TImageList;
|
TreeImages: TImageList;
|
||||||
FontDialog1: TFontDialog;
|
FontDialog1: TFontDialog;
|
||||||
@ -38,14 +40,15 @@ type
|
|||||||
Onemenuitem1: TMenuItem;
|
Onemenuitem1: TMenuItem;
|
||||||
forrightclickselection1: TMenuItem;
|
forrightclickselection1: TMenuItem;
|
||||||
withpopupmenu1: TMenuItem;
|
withpopupmenu1: TMenuItem;
|
||||||
RadioGroup1: TRadioGroup;
|
TreeButtonLookRadioGroup: TRadioGroup;
|
||||||
RadioGroup2: TRadioGroup;
|
DrawSelectionModeRadioGroup: TRadioGroup;
|
||||||
VTHPopup: TLazVTHeaderPopupMenu;
|
VTHPopup: TLazVTHeaderPopupMenu;
|
||||||
ThemeRadioGroup: TRadioGroup;
|
ThemeRadioGroup: TRadioGroup;
|
||||||
SaveButton: TBitBtn;
|
SaveButton: TBitBtn;
|
||||||
SaveDialog: TSaveDialog;
|
SaveDialog: TSaveDialog;
|
||||||
ImageList1: TImageList;
|
ImageList1: TImageList;
|
||||||
procedure BitBtn1Click(Sender: TObject);
|
procedure TreeFontButtonClick(Sender: TObject);
|
||||||
|
procedure ButtonFillModeComboChange(Sender: TObject);
|
||||||
procedure VST2InitNode(Sender: TBaseVirtualTree; ParentNode, Node: PVirtualNode;
|
procedure VST2InitNode(Sender: TBaseVirtualTree; ParentNode, Node: PVirtualNode;
|
||||||
var InitialStates: TVirtualNodeInitStates);
|
var InitialStates: TVirtualNodeInitStates);
|
||||||
procedure VST2InitChildren(Sender: TBaseVirtualTree; Node: PVirtualNode; var ChildCount: Cardinal);
|
procedure VST2InitChildren(Sender: TBaseVirtualTree; Node: PVirtualNode; var ChildCount: Cardinal);
|
||||||
@ -62,10 +65,10 @@ type
|
|||||||
var AskParent: Boolean; var PopupMenu: TPopupMenu);
|
var AskParent: Boolean; var PopupMenu: TPopupMenu);
|
||||||
procedure VST2KeyDown(Sender: TObject; var Key: Word;
|
procedure VST2KeyDown(Sender: TObject; var Key: Word;
|
||||||
Shift: TShiftState);
|
Shift: TShiftState);
|
||||||
procedure RadioGroup1Click(Sender: TObject);
|
procedure TreeButtonLookRadioGroupClick(Sender: TObject);
|
||||||
procedure VST2FocusChanging(Sender: TBaseVirtualTree; OldNode, NewNode: PVirtualNode; OldColumn,
|
procedure VST2FocusChanging(Sender: TBaseVirtualTree; OldNode, NewNode: PVirtualNode; OldColumn,
|
||||||
NewColumn: TColumnIndex; var Allowed: Boolean);
|
NewColumn: TColumnIndex; var Allowed: Boolean);
|
||||||
procedure RadioGroup2Click(Sender: TObject);
|
procedure DrawSelectionModeRadioGroupClick(Sender: TObject);
|
||||||
procedure ThemeRadioGroupClick(Sender: TObject);
|
procedure ThemeRadioGroupClick(Sender: TObject);
|
||||||
procedure SaveButtonClick(Sender: TObject);
|
procedure SaveButtonClick(Sender: TObject);
|
||||||
procedure VST2StateChange(Sender: TBaseVirtualTree; Enter,
|
procedure VST2StateChange(Sender: TBaseVirtualTree; Enter,
|
||||||
@ -116,7 +119,7 @@ var
|
|||||||
begin
|
begin
|
||||||
// Determine if we are running on Windows XP.
|
// Determine if we are running on Windows XP.
|
||||||
{$ifdef LCLWin32}
|
{$ifdef LCLWin32}
|
||||||
ThemeRadioGroup.Enabled := (Win32MajorVersion >= 5) and (Win32MinorVersion >= 1);
|
ThemeRadioGroup.Enabled := CheckWin32Version(5, 1);
|
||||||
{$else}
|
{$else}
|
||||||
ThemeRadioGroup.Enabled := False;
|
ThemeRadioGroup.Enabled := False;
|
||||||
{$endif}
|
{$endif}
|
||||||
@ -124,6 +127,8 @@ begin
|
|||||||
ThemeRadioGroup.ItemIndex := 0;
|
ThemeRadioGroup.ItemIndex := 0;
|
||||||
|
|
||||||
CheckMarkCombo.ItemIndex := 3;
|
CheckMarkCombo.ItemIndex := 3;
|
||||||
|
ButtonFillModeCombo.ItemIndex := ord(VST2.ButtonFillMode);
|
||||||
|
MainColumnLabel.Caption := IntToStr(VST2.Header.MainColumn);
|
||||||
|
|
||||||
// Add a second line of hint text for column headers (not possible in the object inspector).
|
// Add a second line of hint text for column headers (not possible in the object inspector).
|
||||||
with VST2.Header do
|
with VST2.Header do
|
||||||
@ -341,7 +346,7 @@ end;
|
|||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
procedure TGeneralForm.BitBtn1Click(Sender: TObject);
|
procedure TGeneralForm.TreeFontButtonClick(Sender: TObject);
|
||||||
|
|
||||||
begin
|
begin
|
||||||
with FontDialog1 do
|
with FontDialog1 do
|
||||||
@ -352,6 +357,11 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TGeneralForm.ButtonFillModeComboChange(Sender: TObject);
|
||||||
|
begin
|
||||||
|
VST2.ButtonFillMode := TVTButtonFillMode(ButtonFillModeCombo.ItemIndex);
|
||||||
|
end;
|
||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
procedure TGeneralForm.CheckMarkComboChange(Sender: TObject);
|
procedure TGeneralForm.CheckMarkComboChange(Sender: TObject);
|
||||||
@ -366,6 +376,7 @@ procedure TGeneralForm.MainColumnUpDownChanging(Sender: TObject; var AllowChange
|
|||||||
|
|
||||||
begin
|
begin
|
||||||
VST2.Header.MainColumn := MainColumnUpDown.Position;
|
VST2.Header.MainColumn := MainColumnUpDown.Position;
|
||||||
|
MainColumnLabel.Caption := IntToStr(VST2.Header.MainColumn);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
@ -407,7 +418,7 @@ end;
|
|||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
procedure TGeneralForm.RadioGroup1Click(Sender: TObject);
|
procedure TGeneralForm.TreeButtonLookRadioGroupClick(Sender: TObject);
|
||||||
|
|
||||||
begin
|
begin
|
||||||
with Sender as TRadioGroup do
|
with Sender as TRadioGroup do
|
||||||
@ -434,7 +445,7 @@ end;
|
|||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
procedure TGeneralForm.RadioGroup2Click(Sender: TObject);
|
procedure TGeneralForm.DrawSelectionModeRadioGroupClick(Sender: TObject);
|
||||||
|
|
||||||
begin
|
begin
|
||||||
with Sender as TRadioGroup do
|
with Sender as TRadioGroup do
|
||||||
@ -459,9 +470,9 @@ begin
|
|||||||
else
|
else
|
||||||
PaintOptions := PaintOptions - [toThemeAware];
|
PaintOptions := PaintOptions - [toThemeAware];
|
||||||
|
|
||||||
RadioGroup1.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
TreeButtonLookRadioGroup.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
||||||
RadioGroup2.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
DrawSelectionModeRadioGroup.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
||||||
Label18.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
SwitchCheckImagesLabel.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
||||||
CheckMarkCombo.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
CheckMarkCombo.Enabled := ThemeRadioGroup.ItemIndex = 1;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user