jvcllaz: Improved layout and some cosmetics for JvThumbnail demo

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@6270 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz 2018-03-23 19:44:39 +00:00
parent f90b6958e5
commit 43965baf70
4 changed files with 379 additions and 225 deletions

View File

@ -2,10 +2,10 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
Left = 367 Left = 367
Height = 529 Height = 529
Top = 149 Top = 149
Width = 770 Width = 828
Caption = 'JvThumbNail Demo' Caption = 'JvThumbNail Demo'
ClientHeight = 529 ClientHeight = 529
ClientWidth = 770 ClientWidth = 828
Color = clBtnFace Color = clBtnFace
Font.Color = clWindowText Font.Color = clWindowText
OnShow = FormShow OnShow = FormShow
@ -54,7 +54,7 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
end end
object ShellListView: TShellListView object ShellListView: TShellListView
Left = 1 Left = 1
Height = 168 Height = 162
Top = 147 Top = 147
Width = 236 Width = 236
Align = alClient Align = alClient
@ -69,22 +69,25 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
end end
object Panel8: TPanel object Panel8: TPanel
Left = 1 Left = 1
Height = 213 Height = 219
Top = 315 Top = 309
Width = 236 Width = 236
Align = alBottom Align = alBottom
AutoSize = True
BevelOuter = bvNone BevelOuter = bvNone
ClientHeight = 213 ClientHeight = 219
ClientWidth = 236 ClientWidth = 236
TabOrder = 2 TabOrder = 2
OnResize = Panel8Resize OnResize = Panel8Resize
object Label6: TLabel object LblRed: TLabel
Left = 8 Left = 0
Height = 13 Height = 13
Top = 0 Top = 4
Width = 226 Width = 236
Align = alTop
Alignment = taCenter Alignment = taCenter
AutoSize = False AutoSize = False
BorderSpacing.Top = 4
Caption = 'RED' Caption = 'RED'
Color = clRed Color = clRed
Font.Color = clWhite Font.Color = clWhite
@ -94,13 +97,15 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
ParentFont = False ParentFont = False
Transparent = False Transparent = False
end end
object Label7: TLabel object LblGreen: TLabel
Left = 8 Left = 0
Height = 14 Height = 14
Top = 45 Top = 50
Width = 226 Width = 236
Align = alTop
Alignment = taCenter Alignment = taCenter
AutoSize = False AutoSize = False
BorderSpacing.Top = 4
Caption = 'GREEN' Caption = 'GREEN'
Color = clLime Color = clLime
Font.Color = clBlack Font.Color = clBlack
@ -110,13 +115,15 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
ParentFont = False ParentFont = False
Transparent = False Transparent = False
end end
object Label8: TLabel object LblBlue: TLabel
Left = 7 Left = 0
Height = 14 Height = 14
Top = 89 Top = 98
Width = 226 Width = 236
Align = alTop
Alignment = taCenter Alignment = taCenter
AutoSize = False AutoSize = False
BorderSpacing.Top = 4
Caption = 'BLUE' Caption = 'BLUE'
Color = clBlue Color = clBlue
Font.Color = clWhite Font.Color = clWhite
@ -126,13 +133,19 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
ParentFont = False ParentFont = False
Transparent = False Transparent = False
end end
object Label9: TLabel object LblContrast: TLabel
Left = 6 AnchorSideLeft.Control = ContrastBar
AnchorSideTop.Control = BlueBar
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = ContrastBar
AnchorSideRight.Side = asrBottom
Left = 0
Height = 14 Height = 14
Top = 137 Top = 146
Width = 91 Width = 91
Alignment = taCenter Alignment = taCenter
AutoSize = False AutoSize = False
BorderSpacing.Top = 4
Caption = 'CONTRAST' Caption = 'CONTRAST'
Font.Color = clBlack Font.Color = clBlack
Font.Height = -11 Font.Height = -11
@ -140,12 +153,17 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
ParentColor = False ParentColor = False
ParentFont = False ParentFont = False
end end
object Label1: TLabel object LblLightness: TLabel
Left = 134 AnchorSideLeft.Control = LightnessBar
AnchorSideTop.Control = LblContrast
AnchorSideRight.Control = LightnessBar
AnchorSideRight.Side = asrBottom
Left = 126
Height = 14 Height = 14
Top = 137 Top = 146
Width = 91 Width = 110
Alignment = taCenter Alignment = taCenter
Anchors = [akTop, akLeft, akRight]
AutoSize = False AutoSize = False
Caption = 'LIGHTNESS' Caption = 'LIGHTNESS'
Font.Color = clBlack Font.Color = clBlack
@ -157,77 +175,108 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
object REDBar: TTrackBar object REDBar: TTrackBar
Left = 0 Left = 0
Height = 29 Height = 29
Top = 13 Top = 17
Width = 241 Width = 236
Frequency = 51 Frequency = 51
Max = 255 Max = 255
Min = -255 Min = -255
PageSize = 20 PageSize = 20
Position = 0 Position = 0
TickStyle = tsNone TickStyle = tsNone
Align = alTop
TabOrder = 0 TabOrder = 0
end end
object GreenBar: TTrackBar object GreenBar: TTrackBar
Left = 0 Left = 0
Height = 30 Height = 30
Top = 59 Top = 64
Width = 241 Width = 236
Frequency = 51 Frequency = 51
Max = 255 Max = 255
Min = -255 Min = -255
PageSize = 20 PageSize = 20
Position = 0 Position = 0
TickStyle = tsNone TickStyle = tsNone
Align = alTop
TabOrder = 1 TabOrder = 1
end end
object BlueBar: TTrackBar object BlueBar: TTrackBar
Left = -1 Left = 0
Height = 30 Height = 30
Top = 107 Top = 112
Width = 241 Width = 236
Frequency = 51 Frequency = 51
Max = 255 Max = 255
Min = -255 Min = -255
PageSize = 20 PageSize = 20
Position = 0 Position = 0
TickStyle = tsNone TickStyle = tsNone
Align = alTop
TabOrder = 2 TabOrder = 2
end end
object contrastBar: TTrackBar object ContrastBar: TTrackBar
Left = -1 AnchorSideLeft.Control = Panel8
AnchorSideTop.Control = LblContrast
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = Bevel2
Left = 0
Height = 30 Height = 30
Top = 152 Top = 160
Width = 106 Width = 110
Frequency = 51 Frequency = 51
Max = 100 Max = 100
Min = -100 Min = -100
PageSize = 20 PageSize = 20
Position = 0 Position = 0
TickStyle = tsNone TickStyle = tsNone
Anchors = [akTop, akLeft, akRight]
TabOrder = 3 TabOrder = 3
end end
object Button2: TButton object BtnApply: TButton
Left = 8 AnchorSideLeft.Control = Panel8
AnchorSideTop.Control = ContrastBar
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = Panel8
AnchorSideRight.Side = asrBottom
Left = 4
Height = 25 Height = 25
Top = 184 Top = 190
Width = 225 Width = 225
BorderSpacing.Left = 4
BorderSpacing.Right = 4
BorderSpacing.Bottom = 4
Caption = 'APPLY' Caption = 'APPLY'
OnClick = Button2Click OnClick = BtnApplyClick
TabOrder = 4 TabOrder = 4
end end
object LightnessBar: TTrackBar object LightnessBar: TTrackBar
Left = 127 AnchorSideLeft.Control = Bevel2
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = ContrastBar
AnchorSideRight.Control = Panel8
AnchorSideRight.Side = asrBottom
Left = 126
Height = 30 Height = 30
Top = 152 Top = 160
Width = 106 Width = 110
Frequency = 51 Frequency = 51
Max = 100 Max = 100
Min = -100 Min = -100
PageSize = 20 PageSize = 20
Position = 0 Position = 0
TickStyle = tsNone TickStyle = tsNone
Anchors = [akTop, akLeft, akRight]
TabOrder = 5 TabOrder = 5
end end
object Bevel2: TBevel
AnchorSideLeft.Control = Panel8
AnchorSideLeft.Side = asrCenter
Left = 110
Height = 36
Top = 0
Width = 16
Shape = bsSpacer
end
end end
object Panel10: TPanel object Panel10: TPanel
Left = 1 Left = 1
@ -258,165 +307,111 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
Left = 241 Left = 241
Height = 529 Height = 529
Top = 0 Top = 0
Width = 529 Width = 587
Align = alClient Align = alClient
ClientHeight = 529 ClientHeight = 529
ClientWidth = 529 ClientWidth = 587
TabOrder = 1 TabOrder = 1
object ThumbImage1: TJvThumbImage object ThumbImage: TJvThumbImage
Left = 1 AnchorSideLeft.Control = Panel5
Height = 376 AnchorSideTop.Control = Panel5
Top = 144 AnchorSideTop.Side = asrBottom
Width = 518 AnchorSideRight.Control = Panel5
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = Panel7
AnchorSideBottom.Side = asrBottom
Left = 5
Height = 352
Top = 172
Width = 577
Anchors = [akTop, akLeft, akRight, akBottom]
AutoSize = True AutoSize = True
BorderSpacing.Top = 8
BorderSpacing.Bottom = 4
IgnoreMouse = False IgnoreMouse = False
Angle = AT0 Angle = AT0
Zoom = 0 Zoom = 0
end end
object Panel5: TPanel object Panel5: TPanel
Left = 1 Left = 5
Height = 144 Height = 159
Top = 1 Top = 5
Width = 527 Width = 577
Align = alTop Align = alTop
ClientHeight = 144 AutoSize = True
ClientWidth = 527 BorderSpacing.Around = 4
BevelOuter = bvNone
ClientHeight = 159
ClientWidth = 577
TabOrder = 0 TabOrder = 0
object Bevel1: TBevel object GbThumbImage: TGroupBox
Left = 156 AnchorSideLeft.Control = Panel1
Height = 137 AnchorSideLeft.Side = asrBottom
Top = 3 AnchorSideTop.Control = Panel5
Width = 232 AnchorSideRight.Side = asrBottom
end Left = 430
object Label5: TLabel Height = 78
Left = 161
Height = 13
Hint = 'You can set the thumbnails title to what ever you want it to be '
Top = 100
Width = 193
AutoSize = False
Caption = 'Thumbnails Title'
ParentColor = False
end
object CbAsButton: TCheckBox
Left = 161
Height = 19
Hint = 'This will give a button effect when the thumbnail is clicked '
Top = 7
Width = 69
Caption = 'AsButton'
Checked = True
OnClick = CbAsButtonClick
State = cbChecked
TabOrder = 0
end
object CbAutoLoad: TCheckBox
Left = 161
Height = 19
Hint = 'If AutoLoad = true when you pass a name to the filename it automatically loads it else not(for Future reference where the will be a thumblist file)'
Top = 31
Width = 69
Caption = 'Autoload'
Checked = True
OnClick = CbAutoLoadClick
ParentShowHint = False
ShowHint = True
State = cbChecked
TabOrder = 1
end
object CbMinimizeMem: TCheckBox
Left = 161
Height = 19
Hint = 'This will forse the thumbimage to convert all the thumbs in BMP and reduce memory usage us much as possible'
Top = 55
Width = 114
Caption = 'MinimizeMemory'
Checked = True
OnClick = CbMinimizeMemClick
ParentShowHint = False
ShowHint = True
State = cbChecked
TabOrder = 2
end
object GbTitlePlacement: TRadioGroup
Left = 265
Height = 65
Hint = 'The position of the thumbnail''s title'
Top = 9
Width = 113
AutoFill = True
Caption = ' Title Placement '
ChildSizing.LeftRightSpacing = 6
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
ChildSizing.EnlargeVertical = crsHomogenousChildResize
ChildSizing.ShrinkHorizontal = crsScaleChilds
ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 1
ClientHeight = 45
ClientWidth = 109
ItemIndex = 0
Items.Strings = (
'T_UP'
'T_Down'
)
OnClick = GbTitlePlacementClick
ParentShowHint = False
ShowHint = True
TabOrder = 3
end
object Edit1: TEdit
Left = 161
Height = 23
Hint = 'You can set the thumbnails title to what ever you want it to be '
Top = 116
Width = 224
TabOrder = 4
Text = 'Edit1'
end
object GroupBox1: TGroupBox
Left = 390
Height = 75
Top = 0 Top = 0
Width = 125 Width = 127
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Left = 8
BorderSpacing.Right = 8
Caption = 'THUMBIMAGE' Caption = 'THUMBIMAGE'
ClientHeight = 55 ClientHeight = 58
ClientWidth = 121 ClientWidth = 123
TabOrder = 5 TabOrder = 0
object BtnInvert: TButton object BtnInvert: TButton
AnchorSideLeft.Control = GbThumbImage
AnchorSideTop.Control = GbThumbImage
AnchorSideRight.Control = GbThumbImage
AnchorSideRight.Side = asrBottom
Left = 8 Left = 8
Height = 25 Height = 25
Top = 0 Top = 0
Width = 108 Width = 107
Anchors = [akTop, akLeft, akRight]
AutoSize = True
BorderSpacing.Left = 8
BorderSpacing.Right = 8
Caption = 'INVERT' Caption = 'INVERT'
OnClick = BtnInvertClick OnClick = BtnInvertClick
TabOrder = 0 TabOrder = 0
end end
object Button5: TButton object Button5: TButton
AnchorSideLeft.Control = BtnInvert
AnchorSideTop.Control = BtnInvert
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = BtnInvert
AnchorSideRight.Side = asrBottom
Left = 8 Left = 8
Height = 25 Height = 25
Top = 28 Top = 29
Width = 108 Width = 107
Anchors = [akTop, akLeft, akRight]
AutoSize = True
BorderSpacing.Top = 4
BorderSpacing.Bottom = 8
Caption = 'GRAYSCALE' Caption = 'GRAYSCALE'
OnClick = Button5Click OnClick = Button5Click
TabOrder = 1 TabOrder = 1
end end
end end
object BtnExit: TButton
Left = 265
Height = 25
Top = 80
Width = 113
Caption = 'EXIT'
ModalResult = 1
TabOrder = 6
end
object GbAngle: TRadioGroup object GbAngle: TRadioGroup
Left = 390 AnchorSideLeft.Control = GbThumbImage
Height = 60 AnchorSideTop.Control = GbThumbImage
Top = 81 AnchorSideTop.Side = asrBottom
Width = 125 AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = Panel1
AnchorSideBottom.Side = asrBottom
Left = 430
Height = 73
Top = 86
Width = 131
Anchors = [akTop, akLeft, akBottom]
AutoFill = True AutoFill = True
AutoSize = True
BorderSpacing.Top = 8
BorderSpacing.Right = 8
Caption = ' ThumbImage Angle ' Caption = ' ThumbImage Angle '
ChildSizing.LeftRightSpacing = 6 ChildSizing.LeftRightSpacing = 6
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
@ -425,8 +420,8 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
ChildSizing.ShrinkVertical = crsScaleChilds ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 2 ChildSizing.ControlsPerLine = 2
ClientHeight = 40 ClientHeight = 53
ClientWidth = 121 ClientWidth = 127
Columns = 2 Columns = 2
Items.Strings = ( Items.Strings = (
'0' '0'
@ -435,17 +430,24 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
'270' '270'
) )
OnClick = GbAngleClick OnClick = GbAngleClick
TabOrder = 7 TabOrder = 1
end end
object ThumbNail1: TJvThumbnail object ThumbNail: TJvThumbnail
Left = 1 AnchorSideTop.Control = Panel5
Height = 142 AnchorSideBottom.Control = Panel5
Top = 1 AnchorSideBottom.Side = asrBottom
Width = 154 Left = 9
ClientHeight = 119 Height = 159
ClientWidth = 146 Top = 0
TabOrder = 8 Width = 152
OnClick = ThumbNail1Click Anchors = [akTop, akBottom]
BorderSpacing.Left = 2
BorderSpacing.Right = 8
ClientHeight = 136
ClientWidth = 144
Constraints.MinWidth = 152
TabOrder = 2
OnClick = ThumbNailClick
TitleColor = clBtnFace TitleColor = clBtnFace
TitleFont.Color = clWindowText TitleFont.Color = clWindowText
TitleFont.Height = -11 TitleFont.Height = -11
@ -459,6 +461,156 @@ object JvThumbnailChildForm: TJvThumbnailChildForm
ShadowColor = clSilver ShadowColor = clSilver
ShowShadow = False ShowShadow = False
end end
object Panel1: TPanel
AnchorSideLeft.Control = ThumbNail
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = ThumbNail
Left = 169
Height = 159
Top = 0
Width = 253
AutoSize = True
BevelInner = bvRaised
BevelOuter = bvLowered
ClientHeight = 159
ClientWidth = 253
TabOrder = 3
object CbAsButton: TCheckBox
AnchorSideLeft.Control = Panel1
AnchorSideTop.Control = Panel1
Left = 10
Height = 19
Hint = 'This will give a button effect when the thumbnail is clicked '
Top = 8
Width = 69
BorderSpacing.Left = 8
BorderSpacing.Top = 6
Caption = 'AsButton'
Checked = True
OnClick = CbAsButtonClick
State = cbChecked
TabOrder = 0
end
object CbAutoLoad: TCheckBox
AnchorSideLeft.Control = CbAsButton
AnchorSideTop.Control = CbAsButton
AnchorSideTop.Side = asrBottom
Left = 10
Height = 19
Hint = 'If AutoLoad = true when you pass a name to the filename it automatically loads it else not(for Future reference where the will be a thumblist file)'
Top = 31
Width = 69
BorderSpacing.Top = 4
Caption = 'Autoload'
Checked = True
OnClick = CbAutoLoadClick
ParentShowHint = False
ShowHint = True
State = cbChecked
TabOrder = 1
end
object CbMinimizeMem: TCheckBox
AnchorSideLeft.Control = CbAsButton
AnchorSideTop.Control = CbAutoLoad
AnchorSideTop.Side = asrBottom
Left = 10
Height = 19
Hint = 'This will forse the thumbimage to convert all the thumbs in BMP and reduce memory usage us much as possible'
Top = 54
Width = 114
BorderSpacing.Top = 4
BorderSpacing.Right = 12
BorderSpacing.Bottom = 8
Caption = 'MinimizeMemory'
Checked = True
OnClick = CbMinimizeMemClick
ParentShowHint = False
ShowHint = True
State = cbChecked
TabOrder = 2
end
object GbTitlePlacement: TRadioGroup
AnchorSideLeft.Control = CbMinimizeMem
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = Panel1
AnchorSideRight.Side = asrBottom
Left = 136
Height = 58
Hint = 'The position of the thumbnail''s title'
Top = 11
Width = 107
AutoFill = True
AutoSize = True
BorderSpacing.Top = 9
BorderSpacing.Right = 8
Caption = ' Title Placement '
ChildSizing.LeftRightSpacing = 6
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
ChildSizing.EnlargeVertical = crsHomogenousChildResize
ChildSizing.ShrinkHorizontal = crsScaleChilds
ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 1
ClientHeight = 38
ClientWidth = 103
ItemIndex = 0
Items.Strings = (
'T_UP'
'T_Down'
)
OnClick = GbTitlePlacementClick
ParentShowHint = False
ShowHint = True
TabOrder = 3
end
object BtnExit: TButton
AnchorSideLeft.Control = GbTitlePlacement
AnchorSideTop.Control = GbTitlePlacement
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = GbTitlePlacement
AnchorSideRight.Side = asrBottom
Left = 136
Height = 25
Top = 77
Width = 107
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 8
Caption = 'EXIT'
ModalResult = 1
TabOrder = 4
end
object EdThumbTitle: TEdit
AnchorSideLeft.Control = CbAsButton
AnchorSideTop.Control = LblThumbTitle
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = BtnExit
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Side = asrBottom
Left = 10
Height = 23
Hint = 'You can set the thumbnails title to what ever you want it to be '
Top = 126
Width = 233
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Bottom = 8
TabOrder = 5
Text = 'EdThumbTitle'
end
object LblThumbTitle: TLabel
AnchorSideLeft.Control = CbAsButton
AnchorSideTop.Control = BtnExit
AnchorSideTop.Side = asrBottom
Left = 10
Height = 15
Hint = 'You can set the thumbnails title to what ever you want it to be '
Top = 107
Width = 89
BorderSpacing.Top = 5
BorderSpacing.Bottom = 4
Caption = 'Thumbnails Title'
ParentColor = False
end
end
end end
end end
end end

View File

@ -40,42 +40,43 @@ type
{ TJvThumbnailChildForm } { TJvThumbnailChildForm }
TJvThumbnailChildForm = class(TForm) TJvThumbnailChildForm = class(TForm)
Bevel2: TBevel;
Panel1: TPanel;
Splitter2: TSplitter; Splitter2: TSplitter;
Panel6: TPanel; Panel6: TPanel;
Splitter4: TSplitter; Splitter4: TSplitter;
ShellTreeView: TShellTreeView; ShellTreeView: TShellTreeView;
ShellListView: TShellListView; ShellListView: TShellListView;
Panel8: TPanel; Panel8: TPanel;
Label6: TLabel; LblRed: TLabel;
Label7: TLabel; LblGreen: TLabel;
Label8: TLabel; LblBlue: TLabel;
Label9: TLabel; LblContrast: TLabel;
REDBar: TTrackBar; REDBar: TTrackBar;
GreenBar: TTrackBar; GreenBar: TTrackBar;
BlueBar: TTrackBar; BlueBar: TTrackBar;
contrastBar: TTrackBar; ContrastBar: TTrackBar;
Button2: TButton; BtnApply: TButton;
Panel10: TPanel; Panel10: TPanel;
FilterComboBox1: TFilterComboBox; FilterComboBox1: TFilterComboBox;
Panel7: TPanel; Panel7: TPanel;
Panel5: TPanel; Panel5: TPanel;
Label5: TLabel; LblThumbTitle: TLabel;
Bevel1: TBevel;
CbAsButton: TCheckBox; CbAsButton: TCheckBox;
CbAutoLoad: TCheckBox; CbAutoLoad: TCheckBox;
CbMinimizeMem: TCheckBox; CbMinimizeMem: TCheckBox;
GbTitlePlacement: TRadioGroup; GbTitlePlacement: TRadioGroup;
Edit1: TEdit; EdThumbTitle: TEdit;
GroupBox1: TGroupBox; GbThumbImage: TGroupBox;
BtnInvert: TButton; BtnInvert: TButton;
Button5: TButton; Button5: TButton;
Label1: TLabel; LblLightness: TLabel;
LightnessBar: TTrackBar; LightnessBar: TTrackBar;
BtnExit: TButton; BtnExit: TButton;
GbAngle: TRadioGroup; GbAngle: TRadioGroup;
ThumbNail1: TJVThumbNail; ThumbNail: TJVThumbNail;
ThumbImage1: TJvThumbImage; ThumbImage: TJvThumbImage;
procedure Button2Click(Sender: TObject); procedure BtnApplyClick(Sender: TObject);
procedure ShellListViewChange(Sender: TObject); procedure ShellListViewChange(Sender: TObject);
procedure CbAsButtonClick(Sender: TObject); procedure CbAsButtonClick(Sender: TObject);
procedure CbAutoLoadClick(Sender: TObject); procedure CbAutoLoadClick(Sender: TObject);
@ -85,7 +86,7 @@ type
procedure BtnInvertClick(Sender: TObject); procedure BtnInvertClick(Sender: TObject);
procedure Button5Click(Sender: TObject); procedure Button5Click(Sender: TObject);
procedure ShellTreeViewGetImageIndex(Sender: TObject; Node: TTreeNode); procedure ShellTreeViewGetImageIndex(Sender: TObject; Node: TTreeNode);
procedure thumbnail1Click(Sender: TObject); procedure ThumbNailClick(Sender: TObject);
procedure Panel10Resize(Sender: TObject); procedure Panel10Resize(Sender: TObject);
procedure FormShow(Sender: TObject); procedure FormShow(Sender: TObject);
procedure GbAngleClick(Sender: TObject); procedure GbAngleClick(Sender: TObject);
@ -104,11 +105,11 @@ implementation
uses uses
JvThumbnailDatamodule; JvThumbnailDatamodule;
procedure TJvThumbnailChildForm.Button2Click(Sender: TObject); procedure TJvThumbnailChildForm.BtnApplyClick(Sender: TObject);
begin begin
ThumbImage1.ChangeRGB(redbar.Position,greenbar.Position,bluebar.Position); ThumbImage.ChangeRGB(redbar.Position,greenbar.Position,bluebar.Position);
ThumbImage1.Contrast(contrastbar.Position); ThumbImage.Contrast(ContrastBar.Position);
ThumbImage1.Lightness(LightnessBar.Position); ThumbImage.Lightness(LightnessBar.Position);
RedBar.Position := 0; RedBar.Position := 0;
GreenBar.Position :=0; GreenBar.Position :=0;
BlueBar.Position := 0; BlueBar.Position := 0;
@ -122,8 +123,8 @@ var
begin begin
if ShellListView.Selected <> nil then begin if ShellListView.Selected <> nil then begin
fn := ShellListView.GetPathFromItem(ShellListView.Selected); fn := ShellListView.GetPathFromItem(ShellListView.Selected);
Thumbnail1.FileName := fn; ThumbNail.FileName := fn;
ThumbImage1.Loadfromfile(fn); ThumbImage.Loadfromfile(fn);
end; end;
end; end;
@ -138,22 +139,22 @@ end;
procedure TJvThumbnailChildForm.CbAsButtonClick(Sender: TObject); procedure TJvThumbnailChildForm.CbAsButtonClick(Sender: TObject);
begin begin
THumbnail1.Asbutton := CbAsButton.Checked; ThumbNail.Asbutton := CbAsButton.Checked;
end; end;
procedure TJvThumbnailChildForm.CbAutoLoadClick(Sender: TObject); procedure TJvThumbnailChildForm.CbAutoLoadClick(Sender: TObject);
begin begin
thumbnail1.autoload := CbAutoLoad.Checked; ThumbNail.AutoLoad := CbAutoLoad.Checked;
end; end;
procedure TJvThumbnailChildForm.CbMinimizeMemClick(Sender: TObject); procedure TJvThumbnailChildForm.CbMinimizeMemClick(Sender: TObject);
begin begin
thumbnail1.minimizememory:=CbMinimizeMem.Checked; ThumbNail.MinimizeMemory := CbMinimizeMem.Checked;
end; end;
procedure TJvThumbnailChildForm.GbTitlePlacementClick(Sender: TObject); procedure TJvThumbnailChildForm.GbTitlePlacementClick(Sender: TObject);
begin begin
thumbnail1.TitlePlacement := ttitlepos(GbTitlePlacement.ItemIndex); ThumbNail.TitlePlacement := TTitlePos(GbTitlePlacement.ItemIndex);
end; end;
procedure TJvThumbnailChildForm.Panel8Resize(Sender: TObject); procedure TJvThumbnailChildForm.Panel8Resize(Sender: TObject);
@ -163,18 +164,18 @@ end;
procedure TJvThumbnailChildForm.BtnInvertClick(Sender: TObject); procedure TJvThumbnailChildForm.BtnInvertClick(Sender: TObject);
begin begin
ThumbImage1.Invert; ThumbImage.Invert;
end; end;
procedure TJvThumbnailChildForm.Button5Click(Sender: TObject); procedure TJvThumbnailChildForm.Button5Click(Sender: TObject);
begin begin
ThumbImage1.GrayScale; ThumbImage.GrayScale;
end; end;
procedure TJvThumbnailChildForm.thumbnail1Click(Sender: TObject); procedure TJvThumbnailChildForm.ThumbNailClick(Sender: TObject);
begin begin
if thumbnail1.FileName<>'' then if ThumbNail.FileName<>'' then
thumbimage1.Loadfromfile(thumbnail1.FileName); ThumbImage.Loadfromfile(ThumbNail.FileName);
end; end;
procedure TJvThumbnailChildForm.Panel10Resize(Sender: TObject); procedure TJvThumbnailChildForm.Panel10Resize(Sender: TObject);
@ -185,14 +186,14 @@ end;
procedure TJvThumbnailChildForm.FormShow(Sender: TObject); procedure TJvThumbnailChildForm.FormShow(Sender: TObject);
begin begin
//thumbimage1.Picture.Free; //ThumbImage.Picture.Free;
GbTitlePlacement.ItemIndex := integer(thumbnail1.titlePlacement); GbTitlePlacement.ItemIndex := integer(ThumbNail.titlePlacement);
GbAngle.ItemIndex := integer(thumbimage1.angle); GbAngle.ItemIndex := integer(ThumbImage.angle);
end; end;
procedure TJvThumbnailChildForm.GbAngleClick(Sender: TObject); procedure TJvThumbnailChildForm.GbAngleClick(Sender: TObject);
begin begin
thumbimage1.angle := TAngle(GbAngle.ItemIndex) ThumbImage.angle := TAngle(GbAngle.ItemIndex)
end; end;
function TJvThumbnailChildForm.GetfileName: String; function TJvThumbnailChildForm.GetfileName: String;

View File

@ -56,6 +56,7 @@
<Filename Value="jvthumbnaildatamodule.pas"/> <Filename Value="jvthumbnaildatamodule.pas"/>
<IsPartOfProject Value="True"/> <IsPartOfProject Value="True"/>
<ComponentName Value="DataModule1"/> <ComponentName Value="DataModule1"/>
<HasResources Value="True"/>
<ResourceBaseClass Value="DataModule"/> <ResourceBaseClass Value="DataModule"/>
<UnitName Value="JvThumbnailDatamodule"/> <UnitName Value="JvThumbnailDatamodule"/>
</Unit3> </Unit3>

View File

@ -65,7 +65,7 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
AnchorSideTop.Control = Panel1 AnchorSideTop.Control = Panel1
AnchorSideRight.Control = SpinEdit1 AnchorSideRight.Control = SpinEdit1
AnchorSideRight.Side = asrBottom AnchorSideRight.Side = asrBottom
Left = 569 Left = 600
Height = 16 Height = 16
Hint = 'Change the thumbgup to change the space between the thumbnails ' Hint = 'Change the thumbgup to change the space between the thumbnails '
Top = 8 Top = 8
@ -84,7 +84,7 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
AnchorSideTop.Control = Label3 AnchorSideTop.Control = Label3
AnchorSideRight.Control = SpinEdit2 AnchorSideRight.Control = SpinEdit2
AnchorSideRight.Side = asrBottom AnchorSideRight.Side = asrBottom
Left = 649 Left = 680
Height = 16 Height = 16
Hint = 'Change the selected to select the Nth element in the list.' Hint = 'Change the selected to select the Nth element in the list.'
Top = 8 Top = 8
@ -164,7 +164,7 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
AnchorSideLeft.Side = asrBottom AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = Label3 AnchorSideTop.Control = Label3
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 569 Left = 600
Height = 23 Height = 23
Hint = 'Changes the space between the thumbnails ' Hint = 'Changes the space between the thumbnails '
Top = 27 Top = 27
@ -183,7 +183,7 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
AnchorSideLeft.Control = SpinEdit1 AnchorSideLeft.Control = SpinEdit1
AnchorSideLeft.Side = asrBottom AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = SpinEdit1 AnchorSideTop.Control = SpinEdit1
Left = 649 Left = 680
Height = 23 Height = 23
Hint = 'Selects the thumbnail with this index' Hint = 'Selects the thumbnail with this index'
Top = 27 Top = 27
@ -217,9 +217,9 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
Left = 316 Left = 316
Height = 19 Height = 19
Top = 31 Top = 31
Width = 86 Width = 117
BorderSpacing.Left = 16 BorderSpacing.Left = 16
Caption = 'MinMemory' Caption = 'Minimize memory'
Checked = True Checked = True
OnClick = CbMinMemoryClick OnClick = CbMinMemoryClick
ParentShowHint = False ParentShowHint = False
@ -232,7 +232,7 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
AnchorSideTop.Control = Panel1 AnchorSideTop.Control = Panel1
AnchorSideRight.Control = BtnEditSelThumb AnchorSideRight.Control = BtnEditSelThumb
AnchorSideRight.Side = asrBottom AnchorSideRight.Side = asrBottom
Left = 418 Left = 449
Height = 25 Height = 25
Top = 2 Top = 2
Width = 135 Width = 135
@ -249,7 +249,7 @@ object JvThumbnailMainForm: TJvThumbnailMainForm
AnchorSideLeft.Side = asrBottom AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = BtnStopLoading AnchorSideTop.Control = BtnStopLoading
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 418 Left = 449
Height = 25 Height = 25
Top = 29 Top = 29
Width = 135 Width = 135