IDE: find dialog: implemented speedbutton to enable/disable auto completion, bug #12334

git-svn-id: trunk@20947 -
This commit is contained in:
mattias 2009-07-25 15:31:44 +00:00
parent 9c89f78e08
commit 6b224cd088
5 changed files with 188 additions and 128 deletions

View File

@ -28,6 +28,27 @@ object LazFindReplaceDialog: TLazFindReplaceDialog
FocusControl = TextToFindComboBox FocusControl = TextToFindComboBox
ParentColor = False ParentColor = False
end end
object EnableAutoCompleteSpeedButton: TSpeedButton
AnchorSideLeft.Control = TextToFindComboBox
AnchorSideTop.Control = TextToFindComboBox
AnchorSideRight.Control = Owner
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = TextToFindComboBox
AnchorSideBottom.Side = asrBottom
Left = 389
Height = 29
Top = 12
Width = 25
Anchors = [akTop, akRight, akBottom]
AllowAllUp = True
BorderSpacing.Right = 6
Color = clBtnFace
GroupIndex = 1
NumGlyphs = 0
OnClick = EnableAutoCompleteSpeedButtonClick
ShowHint = True
ParentShowHint = False
end
object ReplaceWithCheckbox: TCheckBox object ReplaceWithCheckbox: TCheckBox
AnchorSideLeft.Control = Owner AnchorSideLeft.Control = Owner
AnchorSideTop.Control = ReplaceTextComboBox AnchorSideTop.Control = ReplaceTextComboBox
@ -44,17 +65,15 @@ object LazFindReplaceDialog: TLazFindReplaceDialog
object TextToFindComboBox: TComboBox object TextToFindComboBox: TComboBox
AnchorSideLeft.Control = TextToFindLabel AnchorSideLeft.Control = TextToFindLabel
AnchorSideLeft.Side = asrBottom AnchorSideLeft.Side = asrBottom
AnchorSideRight.Control = Owner AnchorSideRight.Control = EnableAutoCompleteSpeedButton
AnchorSideRight.Side = asrBottom Left = 110
Left = 116
Height = 29 Height = 29
Top = 12 Top = 12
Width = 298 Width = 279
Anchors = [akTop, akLeft, akRight] Anchors = [akTop, akLeft, akRight]
AutoComplete = True AutoComplete = True
AutoCompleteText = [cbactEnabled, cbactEndOfLineComplete, cbactRetainPrefixCase, cbactSearchAscending] AutoCompleteText = [cbactEnabled, cbactEndOfLineComplete, cbactRetainPrefixCase, cbactSearchAscending]
BorderSpacing.Left = 6 BorderSpacing.Left = 6
BorderSpacing.Around = 6
ItemHeight = 0 ItemHeight = 0
OnKeyDown = TextToFindComboboxKeyDown OnKeyDown = TextToFindComboboxKeyDown
TabOrder = 0 TabOrder = 0

View File

@ -1,4 +1,4 @@
{ Das ist eine automatisch erzeugte Lazarus-Ressourcendatei } { This is an automatically generated lazarus resource file }
LazarusResources.Add('TLazFindReplaceDialog','FORMDATA',[ LazarusResources.Add('TLazFindReplaceDialog','FORMDATA',[
'TPF0'#21'TLazFindReplaceDialog'#20'LazFindReplaceDialog'#4'Left'#3'4'#1#6'He' 'TPF0'#21'TLazFindReplaceDialog'#20'LazFindReplaceDialog'#4'Left'#3'4'#1#6'He'
@ -12,122 +12,129 @@ LazarusResources.Add('TLazFindReplaceDialog','FORMDATA',[
+'Side'#7#9'asrCenter'#4'Left'#2#6#6'Height'#2#18#3'Top'#2#17#5'Width'#2'b'#9 +'Side'#7#9'asrCenter'#4'Left'#2#6#6'Height'#2#18#3'Top'#2#17#5'Width'#2'b'#9
+'Alignment'#7#14'taRightJustify'#18'BorderSpacing.Left'#2#6#7'Caption'#6#15 +'Alignment'#7#14'taRightJustify'#18'BorderSpacing.Left'#2#6#7'Caption'#6#15
+'TextToFindLabel'#12'FocusControl'#7#18'TextToFindComboBox'#11'ParentColor'#8 +'TextToFindLabel'#12'FocusControl'#7#18'TextToFindComboBox'#11'ParentColor'#8
+#0#0#9'TCheckBox'#19'ReplaceWithCheckbox'#22'AnchorSideLeft.Control'#7#5'Own' +#0#0#12'TSpeedButton'#29'EnableAutoCompleteSpeedButton'#22'AnchorSideLeft.Co'
+'er'#21'AnchorSideTop.Control'#7#19'ReplaceTextComboBox'#18'AnchorSideTop.Si' +'ntrol'#7#18'TextToFindComboBox'#21'AnchorSideTop.Control'#7#18'TextToFindCo'
+'de'#7#9'asrCenter'#4'Left'#2#6#6'Height'#2#22#3'Top'#2'2'#5'Width'#3#162#0 +'mboBox'#23'AnchorSideRight.Control'#7#5'Owner'#20'AnchorSideRight.Side'#7#9
+#18'BorderSpacing.Left'#2#6#7'Caption'#6#19'ReplaceWithCheckbox'#8'OnChange' +'asrBottom'#24'AnchorSideBottom.Control'#7#18'TextToFindComboBox'#21'AnchorS'
+#7#25'ReplaceWithCheckboxChange'#8'TabOrder'#2#1#0#0#9'TComboBox'#18'TextToF' +'ideBottom.Side'#7#9'asrBottom'#4'Left'#3#133#1#6'Height'#2#29#3'Top'#2#12#5
+'indComboBox'#22'AnchorSideLeft.Control'#7#15'TextToFindLabel'#19'AnchorSide' +'Width'#2#25#7'Anchors'#11#5'akTop'#7'akRight'#8'akBottom'#0#10'AllowAllUp'#9
+'Left.Side'#7#9'asrBottom'#23'AnchorSideRight.Control'#7#5'Owner'#20'AnchorS' +#19'BorderSpacing.Right'#2#6#5'Color'#7#9'clBtnFace'#10'GroupIndex'#2#1#9'Nu'
+'ideRight.Side'#7#9'asrBottom'#4'Left'#2't'#6'Height'#2#29#3'Top'#2#12#5'Wid' +'mGlyphs'#2#0#7'OnClick'#7'"EnableAutoCompleteSpeedButtonClick'#8'ShowHint'#9
+'th'#3'*'#1#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#0#12'AutoComplete'#9 +#14'ParentShowHint'#8#0#0#9'TCheckBox'#19'ReplaceWithCheckbox'#22'AnchorSide'
+'Left.Control'#7#5'Owner'#21'AnchorSideTop.Control'#7#19'ReplaceTextComboBox'
+#18'AnchorSideTop.Side'#7#9'asrCenter'#4'Left'#2#6#6'Height'#2#22#3'Top'#2'2'
+#5'Width'#3#162#0#18'BorderSpacing.Left'#2#6#7'Caption'#6#19'ReplaceWithChec'
+'kbox'#8'OnChange'#7#25'ReplaceWithCheckboxChange'#8'TabOrder'#2#1#0#0#9'TCo'
+'mboBox'#18'TextToFindComboBox'#22'AnchorSideLeft.Control'#7#15'TextToFindLa'
+'bel'#19'AnchorSideLeft.Side'#7#9'asrBottom'#23'AnchorSideRight.Control'#7#29
+'EnableAutoCompleteSpeedButton'#4'Left'#2'n'#6'Height'#2#29#3'Top'#2#12#5'Wi'
+'dth'#3#23#1#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#0#12'AutoComplete'#9
+#16'AutoCompleteText'#11#12'cbactEnabled'#22'cbactEndOfLineComplete'#21'cbac' +#16'AutoCompleteText'#11#12'cbactEnabled'#22'cbactEndOfLineComplete'#21'cbac'
+'tRetainPrefixCase'#20'cbactSearchAscending'#0#18'BorderSpacing.Left'#2#6#20 +'tRetainPrefixCase'#20'cbactSearchAscending'#0#18'BorderSpacing.Left'#2#6#10
+'BorderSpacing.Around'#2#6#10'ItemHeight'#2#0#9'OnKeyDown'#7#25'TextToFindCo' +'ItemHeight'#2#0#9'OnKeyDown'#7#25'TextToFindComboboxKeyDown'#8'TabOrder'#2#0
+'mboboxKeyDown'#8'TabOrder'#2#0#4'Text'#6#18'TextToFindComboBox'#0#0#9'TComb' +#4'Text'#6#18'TextToFindComboBox'#0#0#9'TComboBox'#19'ReplaceTextComboBox'#22
+'oBox'#19'ReplaceTextComboBox'#22'AnchorSideLeft.Control'#7#19'ReplaceWithCh' +'AnchorSideLeft.Control'#7#19'ReplaceWithCheckbox'#19'AnchorSideLeft.Side'#7
+'eckbox'#19'AnchorSideLeft.Side'#7#9'asrBottom'#21'AnchorSideTop.Control'#7 +#9'asrBottom'#21'AnchorSideTop.Control'#7#18'TextToFindComboBox'#18'AnchorSi'
+#18'TextToFindComboBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#23'AnchorSideR' +'deTop.Side'#7#9'asrBottom'#23'AnchorSideRight.Control'#7#5'Owner'#20'Anchor'
+'ight.Control'#7#5'Owner'#20'AnchorSideRight.Side'#7#9'asrBottom'#4'Left'#3 +'SideRight.Side'#7#9'asrBottom'#4'Left'#3#180#0#6'Height'#2#29#3'Top'#2'/'#5
+#180#0#6'Height'#2#29#3'Top'#2'/'#5'Width'#3#234#0#7'Anchors'#11#5'akTop'#6 +'Width'#3#234#0#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#0#12'AutoComplet'
+'akLeft'#7'akRight'#0#12'AutoComplete'#9#16'AutoCompleteText'#11#12'cbactEna' +'e'#9#16'AutoCompleteText'#11#12'cbactEnabled'#22'cbactEndOfLineComplete'#21
+'bled'#22'cbactEndOfLineComplete'#21'cbactRetainPrefixCase'#20'cbactSearchAs' +'cbactRetainPrefixCase'#20'cbactSearchAscending'#0#18'BorderSpacing.Left'#2#6
+'cending'#0#18'BorderSpacing.Left'#2#6#20'BorderSpacing.Around'#2#6#10'ItemH' +#20'BorderSpacing.Around'#2#6#10'ItemHeight'#2#0#9'OnKeyDown'#7#25'TextToFin'
+'eight'#2#0#9'OnKeyDown'#7#25'TextToFindComboboxKeyDown'#8'TabOrder'#2#2#4'T' +'dComboboxKeyDown'#8'TabOrder'#2#2#4'Text'#6#19'ReplaceTextComboBox'#0#0#9'T'
+'ext'#6#19'ReplaceTextComboBox'#0#0#9'TGroupBox'#15'OptionsGroupBox'#22'Anch' +'GroupBox'#15'OptionsGroupBox'#22'AnchorSideLeft.Control'#7#5'Owner'#21'Anch'
+'orSideLeft.Control'#7#5'Owner'#21'AnchorSideTop.Control'#7#19'ReplaceTextCo' +'orSideTop.Control'#7#19'ReplaceTextComboBox'#18'AnchorSideTop.Side'#7#9'asr'
+'mboBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#24'AnchorSideBottom.Control'#7 +'Bottom'#24'AnchorSideBottom.Control'#7#8'BtnPanel'#4'Left'#2#6#6'Height'#3
+#8'BtnPanel'#4'Left'#2#6#6'Height'#3#237#0#3'Top'#2'R'#5'Width'#3#199#0#7'An' +#237#0#3'Top'#2'R'#5'Width'#3#199#0#7'Anchors'#11#5'akTop'#6'akLeft'#8'akBot'
+'chors'#11#5'akTop'#6'akLeft'#8'akBottom'#0#18'BorderSpacing.Left'#2#6#17'Bo' +'tom'#0#18'BorderSpacing.Left'#2#6#17'BorderSpacing.Top'#2#6#20'BorderSpacin'
+'rderSpacing.Top'#2#6#20'BorderSpacing.Bottom'#2#6#7'Caption'#6#15'OptionsGr' +'g.Bottom'#2#6#7'Caption'#6#15'OptionsGroupBox'#12'ClientHeight'#3#218#0#11
+'oupBox'#12'ClientHeight'#3#218#0#11'ClientWidth'#3#195#0#8'TabOrder'#2#3#8 +'ClientWidth'#3#195#0#8'TabOrder'#2#3#8'OnResize'#7#21'OptionsGroupBoxResize'
+'OnResize'#7#21'OptionsGroupBoxResize'#0#9'TCheckBox'#23'PromptOnReplaceChec' +#0#9'TCheckBox'#23'PromptOnReplaceCheckBox'#18'AnchorSideTop.Side'#7#9'asrBo'
+'kBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2#22#3'To' +'ttom'#4'Left'#2#6#6'Height'#2#22#3'Top'#3#148#0#5'Width'#3#183#0#5'Align'#7
+'p'#3#148#0#5'Width'#3#183#0#5'Align'#7#5'alTop'#17'BorderSpacing.Top'#2#6#20 +#5'alTop'#17'BorderSpacing.Top'#2#6#20'BorderSpacing.Around'#2#6#7'Caption'#6
+'BorderSpacing.Around'#2#6#7'Caption'#6#23'PromptOnReplaceCheckBox'#7'Checke' +#23'PromptOnReplaceCheckBox'#7'Checked'#9#14'ParentShowHint'#8#8'ShowHint'#9
+'d'#9#14'ParentShowHint'#8#8'ShowHint'#9#5'State'#7#9'cbChecked'#8'TabOrder' +#5'State'#7#9'cbChecked'#8'TabOrder'#2#4#0#0#9'TCheckBox'#17'MultiLineCheckB'
+#2#4#0#0#9'TCheckBox'#17'MultiLineCheckBox'#18'AnchorSideTop.Side'#7#9'asrBo' +'ox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2#22#3'Top'
+'ttom'#4'Left'#2#6#6'Height'#2#22#3'Top'#2'r'#5'Width'#3#183#0#5'Align'#7#5 +#2'r'#5'Width'#3#183#0#5'Align'#7#5'alTop'#17'BorderSpacing.Top'#2#6#20'Bord'
+'alTop'#17'BorderSpacing.Top'#2#6#20'BorderSpacing.Around'#2#6#7'Caption'#6 +'erSpacing.Around'#2#6#7'Caption'#6#17'MultiLineCheckBox'#14'ParentShowHint'
+#17'MultiLineCheckBox'#14'ParentShowHint'#8#8'ShowHint'#9#8'TabOrder'#2#3#0#0 +#8#8'ShowHint'#9#8'TabOrder'#2#3#0#0#9'TCheckBox'#26'RegularExpressionsCheck'
+#9'TCheckBox'#26'RegularExpressionsCheckBox'#18'AnchorSideTop.Side'#7#9'asrB' +'Box'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2#22#3'Top'
+'ottom'#4'Left'#2#6#6'Height'#2#22#3'Top'#2'P'#5'Width'#3#183#0#5'Align'#7#5 +#2'P'#5'Width'#3#183#0#5'Align'#7#5'alTop'#17'BorderSpacing.Top'#2#6#20'Bord'
+'alTop'#17'BorderSpacing.Top'#2#6#20'BorderSpacing.Around'#2#6#7'Caption'#6 +'erSpacing.Around'#2#6#7'Caption'#6#26'RegularExpressionsCheckBox'#14'Parent'
+#26'RegularExpressionsCheckBox'#14'ParentShowHint'#8#8'ShowHint'#9#8'TabOrde' +'ShowHint'#8#8'ShowHint'#9#8'TabOrder'#2#2#0#0#9'TCheckBox'#22'WholeWordsOnl'
+'r'#2#2#0#0#9'TCheckBox'#22'WholeWordsOnlyCheckBox'#18'AnchorSideTop.Side'#7 +'yCheckBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2#22
+#9'asrBottom'#4'Left'#2#6#6'Height'#2#22#3'Top'#2'.'#5'Width'#3#183#0#5'Alig' +#3'Top'#2'.'#5'Width'#3#183#0#5'Align'#7#5'alTop'#17'BorderSpacing.Top'#2#6
+'n'#7#5'alTop'#17'BorderSpacing.Top'#2#6#20'BorderSpacing.Around'#2#6#7'Capt' +#20'BorderSpacing.Around'#2#6#7'Caption'#6#22'WholeWordsOnlyCheckBox'#14'Par'
+'ion'#6#22'WholeWordsOnlyCheckBox'#14'ParentShowHint'#8#8'ShowHint'#9#8'TabO' ,'entShowHint'#8#8'ShowHint'#9#8'TabOrder'#2#1#0#0#9'TCheckBox'#21'CaseSensit'
+'rder'#2#1#0#0#9'TCheckBox'#21'CaseSensitiveCheckBox'#18'AnchorSideTop.Side' +'iveCheckBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2
+#7#9'asrBottom'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#12#5'Width'#3#183#0#5'Al' +#22#3'Top'#2#12#5'Width'#3#183#0#5'Align'#7#5'alTop'#17'BorderSpacing.Top'#2
+'ign'#7#5'alTop'#17'BorderSpacing.Top'#2#6#20'BorderSpacing.Around'#2#6#7'Ca' +#6#20'BorderSpacing.Around'#2#6#7'Caption'#6#21'CaseSensitiveCheckBox'#14'Pa'
+'ption'#6#21'CaseSensitiveCheckBox'#14'ParentShowHint'#8#8'ShowHint'#9#8'Tab' +'rentShowHint'#8#8'ShowHint'#9#8'TabOrder'#2#0#0#0#0#9'TGroupBox'#13'ScopeGr'
+'Order'#2#0#0#0#0#9'TGroupBox'#13'ScopeGroupBox'#22'AnchorSideLeft.Control'#7 +'oupBox'#22'AnchorSideLeft.Control'#7#15'OptionsGroupBox'#19'AnchorSideLeft.'
+#15'OptionsGroupBox'#19'AnchorSideLeft.Side'#7#9'asrBottom'#21'AnchorSideTop' +'Side'#7#9'asrBottom'#21'AnchorSideTop.Control'#7#14'OriginGroupBox'#18'Anch'
+'.Control'#7#14'OriginGroupBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left' +'orSideTop.Side'#7#9'asrBottom'#4'Left'#3#211#0#6'Height'#2'J'#3'Top'#3#162#0
,#3#211#0#6'Height'#2'J'#3'Top'#3#162#0#5'Width'#3#199#0#20'BorderSpacing.Aro' +#5'Width'#3#199#0#20'BorderSpacing.Around'#2#6#7'Caption'#6#13'ScopeGroupBox'
+'und'#2#6#7'Caption'#6#13'ScopeGroupBox'#28'ChildSizing.LeftRightSpacing'#2#6 +#28'ChildSizing.LeftRightSpacing'#2#6#29'ChildSizing.EnlargeHorizontal'#7#24
+#29'ChildSizing.EnlargeHorizontal'#7#24'crsHomogenousChildResize'#27'ChildSi' +'crsHomogenousChildResize'#27'ChildSizing.EnlargeVertical'#7#24'crsHomogenou'
+'zing.EnlargeVertical'#7#24'crsHomogenousSpaceResize'#28'ChildSizing.ShrinkH' +'sSpaceResize'#28'ChildSizing.ShrinkHorizontal'#7#24'crsHomogenousSpaceResiz'
+'orizontal'#7#24'crsHomogenousSpaceResize'#26'ChildSizing.ShrinkVertical'#7 +'e'#26'ChildSizing.ShrinkVertical'#7#24'crsHomogenousSpaceResize'#18'ChildSi'
+#24'crsHomogenousSpaceResize'#18'ChildSizing.Layout'#7#29'cclLeftToRightThen' +'zing.Layout'#7#29'cclLeftToRightThenTopToBottom'#27'ChildSizing.ControlsPer'
+'TopToBottom'#27'ChildSizing.ControlsPerLine'#2#1#12'ClientHeight'#2'7'#11'C' +'Line'#2#1#12'ClientHeight'#2'7'#11'ClientWidth'#3#195#0#8'TabOrder'#2#5#0#12
+'lientWidth'#3#195#0#8'TabOrder'#2#5#0#12'TRadioButton'#19'SelectedRadioButt' +'TRadioButton'#19'SelectedRadioButton'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#4
+'on'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#4#5'Width'#3#183#0#7'Caption'#6#19 +#5'Width'#3#183#0#7'Caption'#6#19'SelectedRadioButton'#8'TabOrder'#2#0#7'Tab'
+'SelectedRadioButton'#8'TabOrder'#2#0#7'TabStop'#8#0#0#12'TRadioButton'#17'G' +'Stop'#8#0#0#12'TRadioButton'#17'GlobalRadioButton'#4'Left'#2#6#6'Height'#2
+'lobalRadioButton'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#30#5'Width'#3#183#0#7 +#22#3'Top'#2#30#5'Width'#3#183#0#7'Caption'#6#17'GlobalRadioButton'#7'Checke'
+'Caption'#6#17'GlobalRadioButton'#7'Checked'#9#5'State'#7#9'cbChecked'#8'Tab' +'d'#9#5'State'#7#9'cbChecked'#8'TabOrder'#2#1#0#0#0#9'TGroupBox'#17'Directio'
+'Order'#2#1#0#0#0#9'TGroupBox'#17'DirectionGroupBox'#22'AnchorSideLeft.Contr' +'nGroupBox'#22'AnchorSideLeft.Control'#7#15'OptionsGroupBox'#19'AnchorSideLe'
+'ol'#7#15'OptionsGroupBox'#19'AnchorSideLeft.Side'#7#9'asrBottom'#21'AnchorS' +'ft.Side'#7#9'asrBottom'#21'AnchorSideTop.Control'#7#13'ScopeGroupBox'#18'An'
+'ideTop.Control'#7#13'ScopeGroupBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4 +'chorSideTop.Side'#7#9'asrBottom'#4'Left'#3#211#0#6'Height'#2'J'#3'Top'#3#242
+'Left'#3#211#0#6'Height'#2'J'#3'Top'#3#242#0#5'Width'#3#199#0#20'BorderSpaci' +#0#5'Width'#3#199#0#20'BorderSpacing.Around'#2#6#7'Caption'#6#17'DirectionGr'
+'ng.Around'#2#6#7'Caption'#6#17'DirectionGroupBox'#28'ChildSizing.LeftRightS' +'oupBox'#28'ChildSizing.LeftRightSpacing'#2#6#29'ChildSizing.EnlargeHorizont'
+'pacing'#2#6#29'ChildSizing.EnlargeHorizontal'#7#24'crsHomogenousChildResize' +'al'#7#24'crsHomogenousChildResize'#27'ChildSizing.EnlargeVertical'#7#24'crs'
+#27'ChildSizing.EnlargeVertical'#7#24'crsHomogenousSpaceResize'#28'ChildSizi' +'HomogenousSpaceResize'#28'ChildSizing.ShrinkHorizontal'#7#24'crsHomogenousS'
+'ng.ShrinkHorizontal'#7#24'crsHomogenousSpaceResize'#26'ChildSizing.ShrinkVe' +'paceResize'#26'ChildSizing.ShrinkVertical'#7#24'crsHomogenousSpaceResize'#18
+'rtical'#7#24'crsHomogenousSpaceResize'#18'ChildSizing.Layout'#7#29'cclLeftT' +'ChildSizing.Layout'#7#29'cclLeftToRightThenTopToBottom'#27'ChildSizing.Cont'
+'oRightThenTopToBottom'#27'ChildSizing.ControlsPerLine'#2#1#12'ClientHeight' +'rolsPerLine'#2#1#12'ClientHeight'#2'7'#11'ClientWidth'#3#195#0#8'TabOrder'#2
+#2'7'#11'ClientWidth'#3#195#0#8'TabOrder'#2#6#0#12'TRadioButton'#19'Backward' +#6#0#12'TRadioButton'#19'BackwardRadioButton'#4'Left'#2#6#6'Height'#2#22#3'T'
+'RadioButton'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#4#5'Width'#3#183#0#7'Capti' +'op'#2#4#5'Width'#3#183#0#7'Caption'#6#19'BackwardRadioButton'#8'TabOrder'#2
+'on'#6#19'BackwardRadioButton'#8'TabOrder'#2#0#7'TabStop'#8#0#0#12'TRadioBut' +#0#7'TabStop'#8#0#0#12'TRadioButton'#18'ForwardRadioButton'#4'Left'#2#6#6'He'
+'ton'#18'ForwardRadioButton'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#30#5'Width' +'ight'#2#22#3'Top'#2#30#5'Width'#3#183#0#7'Caption'#6#18'ForwardRadioButton'
+#3#183#0#7'Caption'#6#18'ForwardRadioButton'#7'Checked'#9#5'State'#7#9'cbChe' +#7'Checked'#9#5'State'#7#9'cbChecked'#8'TabOrder'#2#1#0#0#0#9'TGroupBox'#14
+'cked'#8'TabOrder'#2#1#0#0#0#9'TGroupBox'#14'OriginGroupBox'#22'AnchorSideLe' +'OriginGroupBox'#22'AnchorSideLeft.Control'#7#15'OptionsGroupBox'#19'AnchorS'
+'ft.Control'#7#15'OptionsGroupBox'#19'AnchorSideLeft.Side'#7#9'asrBottom'#21 +'ideLeft.Side'#7#9'asrBottom'#21'AnchorSideTop.Control'#7#19'ReplaceTextComb'
+'AnchorSideTop.Control'#7#19'ReplaceTextComboBox'#18'AnchorSideTop.Side'#7#9 +'oBox'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#3#211#0#6'Height'#2'J'#3
+'asrBottom'#4'Left'#3#211#0#6'Height'#2'J'#3'Top'#2'R'#5'Width'#3#199#0#20'B' +'Top'#2'R'#5'Width'#3#199#0#20'BorderSpacing.Around'#2#6#7'Caption'#6#14'Ori'
+'orderSpacing.Around'#2#6#7'Caption'#6#14'OriginGroupBox'#28'ChildSizing.Lef' +'ginGroupBox'#28'ChildSizing.LeftRightSpacing'#2#6#29'ChildSizing.EnlargeHor'
+'tRightSpacing'#2#6#29'ChildSizing.EnlargeHorizontal'#7#24'crsHomogenousChil' +'izontal'#7#24'crsHomogenousChildResize'#27'ChildSizing.EnlargeVertical'#7#24
+'dResize'#27'ChildSizing.EnlargeVertical'#7#24'crsHomogenousSpaceResize'#28 +'crsHomogenousSpaceResize'#28'ChildSizing.ShrinkHorizontal'#7#24'crsHomogeno'
+'ChildSizing.ShrinkHorizontal'#7#24'crsHomogenousSpaceResize'#26'ChildSizing' +'usSpaceResize'#26'ChildSizing.ShrinkVertical'#7#24'crsHomogenousSpaceResize'
+'.ShrinkVertical'#7#24'crsHomogenousSpaceResize'#18'ChildSizing.Layout'#7#29 +#18'ChildSizing.Layout'#7#29'cclLeftToRightThenTopToBottom'#27'ChildSizing.C'
+'cclLeftToRightThenTopToBottom'#27'ChildSizing.ControlsPerLine'#2#1#12'Clien' +'ontrolsPerLine'#2#1#12'ClientHeight'#2'7'#11'ClientWidth'#3#195#0#8'TabOrde'
+'tHeight'#2'7'#11'ClientWidth'#3#195#0#8'TabOrder'#2#4#0#12'TRadioButton'#21 +'r'#2#4#0#12'TRadioButton'#21'FromCursorRadioButton'#4'Left'#2#6#6'Height'#2
+'FromCursorRadioButton'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#4#5'Width'#3#183 +#22#3'Top'#2#4#5'Width'#3#183#0#8'AutoSize'#8#7'Caption'#6#21'FromCursorRadi'
+#0#8'AutoSize'#8#7'Caption'#6#21'FromCursorRadioButton'#7'Checked'#9#5'State' +'oButton'#7'Checked'#9#5'State'#7#9'cbChecked'#8'TabOrder'#2#0#0#0#12'TRadio'
+#7#9'cbChecked'#8'TabOrder'#2#0#0#0#12'TRadioButton'#22'EntireScopeRadioButt' +'Button'#22'EntireScopeRadioButton'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#30#5
+'on'#4'Left'#2#6#6'Height'#2#22#3'Top'#2#30#5'Width'#3#183#0#8'AutoSize'#8#7 +'Width'#3#183#0#8'AutoSize'#8#7'Caption'#6#22'EntireScopeRadioButton'#8'TabO'
+'Caption'#6#22'EntireScopeRadioButton'#8'TabOrder'#2#1#7'TabStop'#8#0#0#0#6 +'rder'#2#1#7'TabStop'#8#0#0#0#6'TPanel'#8'BtnPanel'#4'Left'#2#0#6'Height'#2
+'TPanel'#8'BtnPanel'#4'Left'#2#0#6'Height'#2'0'#3'Top'#3'E'#1#5'Width'#3#164 +'0'#3'Top'#3'E'#1#5'Width'#3#164#1#5'Align'#7#8'alBottom'#8'AutoSize'#9#10'B'
+#1#5'Align'#7#8'alBottom'#8'AutoSize'#9#10'BevelOuter'#7#6'bvNone'#12'Client' +'evelOuter'#7#6'bvNone'#12'ClientHeight'#2'0'#11'ClientWidth'#3#164#1#8'TabO'
+'Height'#2'0'#11'ClientWidth'#3#164#1#8'TabOrder'#2#7#0#7'TBitBtn'#16'Replac' +'rder'#2#7#0#7'TBitBtn'#16'ReplaceAllButton'#21'AnchorSideBottom.Side'#7#9'a'
+'eAllButton'#21'AnchorSideBottom.Side'#7#9'asrBottom'#4'Left'#3#213#0#6'Heig' +'srBottom'#4'Left'#3#213#0#6'Height'#2'$'#3'Top'#2#6#5'Width'#2'6'#5'Align'#7
+'ht'#2'$'#3'Top'#2#6#5'Width'#2'6'#5'Align'#7#7'alRight'#8'AutoSize'#9#20'Bo' +#7'alRight'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#4'&All'#4
+'rderSpacing.Around'#2#6#7'Caption'#6#4'&All'#4'Kind'#7#5'bkAll'#9'NumGlyphs' +'Kind'#7#5'bkAll'#9'NumGlyphs'#2#0#7'OnClick'#7#21'ReplaceAllButtonClick'#8
+#2#0#7'OnClick'#7#21'ReplaceAllButtonClick'#8'TabOrder'#2#0#0#0#7'TBitBtn'#8 +'TabOrder'#2#0#0#0#7'TBitBtn'#8'OKButton'#21'AnchorSideBottom.Side'#7#9'asrB'
+'OKButton'#21'AnchorSideBottom.Side'#7#9'asrBottom'#4'Left'#3#17#1#6'Height' +'ottom'#4'Left'#3#17#1#6'Height'#2'$'#3'Top'#2#6#5'Width'#2'9'#5'Align'#7#7
+#2'$'#3'Top'#2#6#5'Width'#2'9'#5'Align'#7#7'alRight'#8'AutoSize'#9#20'Border' +'alRight'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#3'&OK'#7'D'
+'Spacing.Around'#2#6#7'Caption'#6#3'&OK'#7'Default'#9#4'Kind'#7#4'bkOK'#9'Nu' +'efault'#9#4'Kind'#7#4'bkOK'#9'NumGlyphs'#2#0#7'OnClick'#7#13'OkButtonClick'
+'mGlyphs'#2#0#7'OnClick'#7#13'OkButtonClick'#8'TabOrder'#2#1#0#0#7'TBitBtn' +#8'TabOrder'#2#1#0#0#7'TBitBtn'#12'CancelButton'#20'AnchorSideRight.Side'#7#9
+#12'CancelButton'#20'AnchorSideRight.Side'#7#9'asrBottom'#21'AnchorSideBotto' +'asrBottom'#21'AnchorSideBottom.Side'#7#9'asrBottom'#4'Left'#3'P'#1#6'Height'
+'m.Side'#7#9'asrBottom'#4'Left'#3'P'#1#6'Height'#2'$'#3'Top'#2#6#5'Width'#2 +#2'$'#3'Top'#2#6#5'Width'#2'N'#5'Align'#7#7'alRight'#8'AutoSize'#9#20'Border'
+'N'#5'Align'#7#7'alRight'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#6'Cance' ,'Spacing.Around'#2#6#6'Cancel'#9#7'Caption'#6#6'Cancel'#4'Kind'#7#8'bkCancel'
+'l'#9#7'Caption'#6#6'Cancel'#4'Kind'#7#8'bkCancel'#11'ModalResult'#2#2#9'Num' +#11'ModalResult'#2#2#9'NumGlyphs'#2#0#7'OnClick'#7#17'CancelButtonClick'#8'T'
+'Glyphs'#2#0#7'OnClick'#7#17'CancelButtonClick'#8'TabOrder'#2#2#0#0#7'TBitBt' +'abOrder'#2#2#0#0#7'TBitBtn'#10'HelpButton'#22'AnchorSideLeft.Control'#7#8'B'
+'n'#10'HelpButton'#22'AnchorSideLeft.Control'#7#8'BtnPanel'#24'AnchorSideBot' +'tnPanel'#24'AnchorSideBottom.Control'#7#8'BtnPanel'#21'AnchorSideBottom.Sid'
+'tom.Control'#7#8'BtnPanel'#21'AnchorSideBottom.Side'#7#9'asrBottom'#4'Left' +'e'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2'"'#3'Top'#2#8#5'Width'#2'B'#7'Anc'
+#2#6#6'Height'#2'"'#3'Top'#2#8#5'Width'#2'B'#7'Anchors'#11#6'akLeft'#8'akBot' +'hors'#11#6'akLeft'#8'akBottom'#0#8'AutoSize'#9#20'BorderSpacing.Around'#2#6
+'tom'#0#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#5'&Help'#4'K' +#7'Caption'#6#5'&Help'#4'Kind'#7#6'bkHelp'#9'NumGlyphs'#2#0#7'OnClick'#7#15
+'ind'#7#6'bkHelp'#9'NumGlyphs'#2#0#7'OnClick'#7#15'HelpButtonClick'#8'TabOrd' +'HelpButtonClick'#8'TabOrder'#2#3#0#0#0#0
,'er'#2#3#0#0#0#0
]); ]);

View File

@ -71,9 +71,11 @@ type
ReplaceWithCheckbox: TCheckBox; ReplaceWithCheckbox: TCheckBox;
ScopeGroupBox: TGroupBox; ScopeGroupBox: TGroupBox;
SelectedRadioButton: TRadioButton; SelectedRadioButton: TRadioButton;
EnableAutoCompleteSpeedButton: TSpeedButton;
TextToFindComboBox: TComboBox; TextToFindComboBox: TComboBox;
TextToFindLabel: TLabel; TextToFindLabel: TLabel;
WholeWordsOnlyCheckBox: TCheckBox; WholeWordsOnlyCheckBox: TCheckBox;
procedure EnableAutoCompleteSpeedButtonClick(Sender: TObject);
procedure FormChangeBounds(Sender: TObject); procedure FormChangeBounds(Sender: TObject);
procedure FormClose(Sender: TObject; var CloseAction: TCloseAction); procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
procedure HelpButtonClick(Sender: TObject); procedure HelpButtonClick(Sender: TObject);
@ -90,7 +92,9 @@ type
RegExpr: TRegExpr; RegExpr: TRegExpr;
function CheckInput: boolean; function CheckInput: boolean;
function GetComponentText(c: TFindDlgComponent): string; function GetComponentText(c: TFindDlgComponent): string;
function GetEnableAutoComplete: boolean;
procedure SetComponentText(c: TFindDlgComponent; const AValue: string); procedure SetComponentText(c: TFindDlgComponent; const AValue: string);
procedure SetEnableAutoComplete(const AValue: boolean);
procedure SetOnKey(const AValue: TOnFindDlgKey); procedure SetOnKey(const AValue: TOnFindDlgKey);
procedure SetOptions(NewOptions: TSynSearchOptions); procedure SetOptions(NewOptions: TSynSearchOptions);
function GetOptions: TSynSearchOptions; function GetOptions: TSynSearchOptions;
@ -104,6 +108,8 @@ type
destructor Destroy; override; destructor Destroy; override;
public public
property Options: TSynSearchOptions read GetOptions write SetOptions; property Options: TSynSearchOptions read GetOptions write SetOptions;
property EnableAutoComplete: boolean read GetEnableAutoComplete
write SetEnableAutoComplete;
property FindText:AnsiString read GetFindText write SetFindText; property FindText:AnsiString read GetFindText write SetFindText;
property ReplaceText:AnsiString read GetReplaceText write SetReplaceText; property ReplaceText:AnsiString read GetReplaceText write SetReplaceText;
property OnKey: TOnFindDlgKey read FOnKey write SetOnKey; property OnKey: TOnFindDlgKey read FOnKey write SetOnKey;
@ -254,6 +260,13 @@ begin
EnableAlign; EnableAlign;
end; end;
procedure TLazFindReplaceDialog.EnableAutoCompleteSpeedButtonClick(
Sender: TObject);
begin
TextToFindComboBox.AutoComplete:=EnableAutoCompleteSpeedButton.Down;
ReplaceTextComboBox.AutoComplete:=EnableAutoCompleteSpeedButton.Down;
end;
procedure TLazFindReplaceDialog.OkButtonClick(Sender:TObject); procedure TLazFindReplaceDialog.OkButtonClick(Sender:TObject);
begin begin
if not CheckInput then exit; if not CheckInput then exit;
@ -314,6 +327,11 @@ begin
end; end;
end; end;
function TLazFindReplaceDialog.GetEnableAutoComplete: boolean;
begin
Result:=EnableAutoCompleteSpeedButton.Down;
end;
procedure TLazFindReplaceDialog.SetComponentText(c: TFindDlgComponent; procedure TLazFindReplaceDialog.SetComponentText(c: TFindDlgComponent;
const AValue: string); const AValue: string);
begin begin
@ -324,6 +342,13 @@ begin
end; end;
end; end;
procedure TLazFindReplaceDialog.SetEnableAutoComplete(const AValue: boolean);
begin
EnableAutoCompleteSpeedButton.Down:=AValue;
TextToFindComboBox.AutoComplete:=AValue;
ReplaceTextComboBox.AutoComplete:=AValue;
end;
procedure TLazFindReplaceDialog.SetOnKey(const AValue: TOnFindDlgKey); procedure TLazFindReplaceDialog.SetOnKey(const AValue: TOnFindDlgKey);
begin begin
FOnKey:=AValue; FOnKey:=AValue;

View File

@ -180,6 +180,7 @@ type
// Find- and replace-history // Find- and replace-history
FFindHistory: TStringList; FFindHistory: TStringList;
FFindInFilesSearchOptions: TLazFindInFileSearchOptions; FFindInFilesSearchOptions: TLazFindInFileSearchOptions;
FFindAutoComplete: boolean;
FLastConvertDelphiPackage: string; FLastConvertDelphiPackage: string;
FLastConvertDelphiProject: string; FLastConvertDelphiProject: string;
FLastConvertDelphiUnit: string; FLastConvertDelphiUnit: string;
@ -247,6 +248,8 @@ type
write FFindInFilesMaskHistory; write FFindInFilesMaskHistory;
property FindInFilesSearchOptions: TLazFindInFileSearchOptions property FindInFilesSearchOptions: TLazFindInFileSearchOptions
read FFindInFilesSearchOptions write FFindInFilesSearchOptions; read FFindInFilesSearchOptions write FFindInFilesSearchOptions;
property FindAutoComplete: boolean read FFindAutoComplete
write FFindAutoComplete;
// Unit dependencies // Unit dependencies
property UnitDependenciesHistory: TStringList read FUnitDependenciesHistory; property UnitDependenciesHistory: TStringList read FUnitDependenciesHistory;
@ -323,6 +326,7 @@ begin
// Find- and replace-history // Find- and replace-history
FMaxFindHistory:=20; FMaxFindHistory:=20;
FFindAutoComplete:=true;
FFindHistory:=TStringList.Create; FFindHistory:=TStringList.Create;
FReplaceHistory:=TStringList.Create; FReplaceHistory:=TStringList.Create;
FFindInFilesPathHistory:=TStringList.Create; FFindInFilesPathHistory:=TStringList.Create;
@ -391,6 +395,7 @@ var
begin begin
// Find- and replace-history // Find- and replace-history
FMaxFindHistory:=XMLConfig.GetValue(Path+'Find/History/Max',FMaxFindHistory); FMaxFindHistory:=XMLConfig.GetValue(Path+'Find/History/Max',FMaxFindHistory);
FFindAutoComplete:=XMLConfig.GetValue(Path+'Find/AutoComplete/Value',FFindAutoComplete);
LoadRecentList(XMLConfig,FFindHistory,Path+'Find/History/Find/'); LoadRecentList(XMLConfig,FFindHistory,Path+'Find/History/Find/');
LoadRecentList(XMLConfig,FReplaceHistory,Path+'Find/History/Replace/'); LoadRecentList(XMLConfig,FReplaceHistory,Path+'Find/History/Replace/');
LoadRecentList(XMLConfig,FFindInFilesPathHistory,Path+ LoadRecentList(XMLConfig,FFindInFilesPathHistory,Path+
@ -448,6 +453,7 @@ var
begin begin
// Find- and replace-history // Find- and replace-history
XMLConfig.SetDeleteValue(Path+'Find/History/Max',FMaxFindHistory,20); XMLConfig.SetDeleteValue(Path+'Find/History/Max',FMaxFindHistory,20);
XMLConfig.SetDeleteValue(Path+'Find/AutoComplete/Value',FFindAutoComplete,true);
SaveRecentList(XMLConfig,FFindHistory,Path+'Find/History/Find/'); SaveRecentList(XMLConfig,FFindHistory,Path+'Find/History/Find/');
SaveRecentList(XMLConfig,FReplaceHistory,Path+'Find/History/Replace/'); SaveRecentList(XMLConfig,FReplaceHistory,Path+'Find/History/Replace/');
SaveRecentList(XMLConfig,FFindInFilesPathHistory,Path+ SaveRecentList(XMLConfig,FFindInFilesPathHistory,Path+

View File

@ -1212,6 +1212,7 @@ end;
procedure TSourceEditor.StartFindAndReplace(Replace:boolean); procedure TSourceEditor.StartFindAndReplace(Replace:boolean);
var ALeft,ATop:integer; var ALeft,ATop:integer;
bSelectedTextOption: Boolean; bSelectedTextOption: Boolean;
DlgResult: TModalResult;
begin begin
if SourceNotebook<>nil then if SourceNotebook<>nil then
SourceNotebook.InitFindDialog; SourceNotebook.InitFindDialog;
@ -1242,10 +1243,11 @@ begin
//debugln('TSourceEditor.StartFindAndReplace B not FindTextAtCursor'); //debugln('TSourceEditor.StartFindAndReplace B not FindTextAtCursor');
LazFindReplaceDialog.FindText:=''; LazFindReplaceDialog.FindText:='';
end; end;
// if there is no FindText, use the most recently used FindText
if (LazFindReplaceDialog.FindText='') and (InputHistories.FindHistory.Count > 0) then
LazFindReplaceDialog.FindText:=InputHistories.FindHistory[0]
end; end;
LazFindReplaceDialog.EnableAutoComplete:=InputHistories.FindAutoComplete;
// if there is no FindText, use the most recently used FindText
if (LazFindReplaceDialog.FindText='') and (InputHistories.FindHistory.Count > 0) then
LazFindReplaceDialog.FindText:=InputHistories.FindHistory[0];
GetDialogPosition(LazFindReplaceDialog.Width,LazFindReplaceDialog.Height,ALeft,ATop); GetDialogPosition(LazFindReplaceDialog.Width,LazFindReplaceDialog.Height,ALeft,ATop);
LazFindReplaceDialog.Left:=ALeft; LazFindReplaceDialog.Left:=ALeft;
@ -1258,9 +1260,10 @@ begin
and (EditorComponent.BlockBegin.Y<>EditorComponent.BlockEnd.Y) then and (EditorComponent.BlockBegin.Y<>EditorComponent.BlockEnd.Y) then
LazFindReplaceDialog.Options := LazFindReplaceDialog.Options + [ssoSelectedOnly]; LazFindReplaceDialog.Options := LazFindReplaceDialog.Options + [ssoSelectedOnly];
if (LazFindReplaceDialog.ShowModal = mrCancel) then begin DlgResult:=LazFindReplaceDialog.ShowModal;
InputHistories.FindAutoComplete:=LazFindReplaceDialog.EnableAutoComplete;
if DlgResult = mrCancel then
exit; exit;
end;
//debugln('TSourceEditor.StartFindAndReplace B LazFindReplaceDialog.FindText="',dbgstr(LazFindReplaceDialog.FindText),'"'); //debugln('TSourceEditor.StartFindAndReplace B LazFindReplaceDialog.FindText="',dbgstr(LazFindReplaceDialog.FindText),'"');
Replace:=ssoReplace in LazFindReplaceDialog.Options; Replace:=ssoReplace in LazFindReplaceDialog.Options;