mirror of https://gitlab.com/basile.b/dexed.git
Merge branch 'a12_2_a13'
This commit is contained in:
commit
7794eb0242
|
|
@ -274,7 +274,7 @@ begin
|
||||||
|
|
||||||
fFoldKinds := [fkBrackets];
|
fFoldKinds := [fkBrackets];
|
||||||
|
|
||||||
WordBreakChars := WordBreakChars + ['&', '~', '`'];
|
WordBreakChars := WordBreakChars - ['@'];
|
||||||
|
|
||||||
fWhiteAttrib := TSynHighlighterAttributes.Create('White','White');
|
fWhiteAttrib := TSynHighlighterAttributes.Create('White','White');
|
||||||
fNumbrAttrib := TSynHighlighterAttributes.Create('Number','Number');
|
fNumbrAttrib := TSynHighlighterAttributes.Create('Number','Number');
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,7 @@ type
|
||||||
fSelCol: TSynSelectedColor;
|
fSelCol: TSynSelectedColor;
|
||||||
fFoldedColor: TSynSelectedColor;
|
fFoldedColor: TSynSelectedColor;
|
||||||
fMouseLinkColor: TSynSelectedColor;
|
fMouseLinkColor: TSynSelectedColor;
|
||||||
|
fBracketMatchColor: TSynSelectedColor;
|
||||||
fFont: TFont;
|
fFont: TFont;
|
||||||
//
|
//
|
||||||
fTabWidth: Integer;
|
fTabWidth: Integer;
|
||||||
|
|
@ -48,9 +49,11 @@ type
|
||||||
procedure setSelCol(aValue: TSynSelectedColor);
|
procedure setSelCol(aValue: TSynSelectedColor);
|
||||||
procedure setFoldedColor(aValue: TSynSelectedColor);
|
procedure setFoldedColor(aValue: TSynSelectedColor);
|
||||||
procedure setMouseLinkColor(aValue: TSynSelectedColor);
|
procedure setMouseLinkColor(aValue: TSynSelectedColor);
|
||||||
|
procedure setBracketMatchColor(aValue: TSynSelectedColor);
|
||||||
procedure setD2Syn(aValue: TPersistent);
|
procedure setD2Syn(aValue: TPersistent);
|
||||||
procedure setTxtSyn(aValue: TPersistent);
|
procedure setTxtSyn(aValue: TPersistent);
|
||||||
published
|
published
|
||||||
|
property bracketMatchColor: TSynSelectedColor read fBracketMatchColor write setBracketMatchColor;
|
||||||
property mouseLinkColor: TSynSelectedColor read fMouseLinkColor write setMouseLinkColor;
|
property mouseLinkColor: TSynSelectedColor read fMouseLinkColor write setMouseLinkColor;
|
||||||
property selectedColor: TSynSelectedColor read fSelCol write setSelCol;
|
property selectedColor: TSynSelectedColor read fSelCol write setSelCol;
|
||||||
property foldedColor: TSynSelectedColor read fFoldedColor write setFoldedColor;
|
property foldedColor: TSynSelectedColor read fFoldedColor write setFoldedColor;
|
||||||
|
|
@ -128,6 +131,7 @@ begin
|
||||||
fSelCol := TSynSelectedColor.Create;
|
fSelCol := TSynSelectedColor.Create;
|
||||||
fFoldedColor := TSynSelectedColor.Create;
|
fFoldedColor := TSynSelectedColor.Create;
|
||||||
fMouseLinkColor := TSynSelectedColor.Create;
|
fMouseLinkColor := TSynSelectedColor.Create;
|
||||||
|
fBracketMatchColor := TSynSelectedColor.Create;
|
||||||
//
|
//
|
||||||
// note: default values come from TSynEditFoldedView ctor.
|
// note: default values come from TSynEditFoldedView ctor.
|
||||||
fFoldedColor.Background := clNone;
|
fFoldedColor.Background := clNone;
|
||||||
|
|
@ -139,6 +143,9 @@ begin
|
||||||
fMouseLinkColor.Foreground := clNone;
|
fMouseLinkColor.Foreground := clNone;
|
||||||
fMouseLinkColor.Background := clNone;
|
fMouseLinkColor.Background := clNone;
|
||||||
//
|
//
|
||||||
|
fBracketMatchColor.Foreground:= clRed;
|
||||||
|
fBracketMatchColor.Background:= clNone;
|
||||||
|
//
|
||||||
rightEdge := 80;
|
rightEdge := 80;
|
||||||
tabulationWidth := 4;
|
tabulationWidth := 4;
|
||||||
blockIdentation := 4;
|
blockIdentation := 4;
|
||||||
|
|
@ -161,6 +168,7 @@ begin
|
||||||
fSelCol.Free;
|
fSelCol.Free;
|
||||||
fFoldedColor.Free;
|
fFoldedColor.Free;
|
||||||
fMouseLinkColor.Free;
|
fMouseLinkColor.Free;
|
||||||
|
fBracketMatchColor.Free;
|
||||||
inherited;
|
inherited;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
@ -176,6 +184,7 @@ begin
|
||||||
fSelCol.Assign(srcopt.fSelCol);
|
fSelCol.Assign(srcopt.fSelCol);
|
||||||
fFoldedColor.Assign(srcopt.fFoldedColor);
|
fFoldedColor.Assign(srcopt.fFoldedColor);
|
||||||
fMouseLinkColor.Assign(srcopt.fMouseLinkColor);
|
fMouseLinkColor.Assign(srcopt.fMouseLinkColor);
|
||||||
|
fBracketMatchColor.Assign(srcopt.fBracketMatchColor);
|
||||||
fD2Syn.Assign(srcopt.fD2Syn);
|
fD2Syn.Assign(srcopt.fD2Syn);
|
||||||
fTxtSyn.Assign(srcopt.fTxtSyn);
|
fTxtSyn.Assign(srcopt.fTxtSyn);
|
||||||
background := srcopt.background;
|
background := srcopt.background;
|
||||||
|
|
@ -212,6 +221,11 @@ begin
|
||||||
fMouseLinkColor.Assign(aValue);
|
fMouseLinkColor.Assign(aValue);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TCEEditorOptionsBase.setBracketMatchColor(aValue: TSynSelectedColor);
|
||||||
|
begin
|
||||||
|
fBracketMatchColor.Assign(aValue);
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TCEEditorOptionsBase.setD2Syn(aValue: TPersistent);
|
procedure TCEEditorOptionsBase.setD2Syn(aValue: TPersistent);
|
||||||
begin
|
begin
|
||||||
D2Syn.Assign(aValue);
|
D2Syn.Assign(aValue);
|
||||||
|
|
@ -330,6 +344,7 @@ begin
|
||||||
anEditor.SelectedColor.Assign(fSelCol);
|
anEditor.SelectedColor.Assign(fSelCol);
|
||||||
anEditor.FoldedCodeColor.Assign(fFoldedColor);
|
anEditor.FoldedCodeColor.Assign(fFoldedColor);
|
||||||
anEditor.MouseLinkColor.Assign(fMouseLinkColor);
|
anEditor.MouseLinkColor.Assign(fMouseLinkColor);
|
||||||
|
anEditor.BracketMatchColor.Assign(fBracketMatchColor);
|
||||||
anEditor.TabWidth := tabulationWidth;
|
anEditor.TabWidth := tabulationWidth;
|
||||||
anEditor.BlockIndent := blockIdentation;
|
anEditor.BlockIndent := blockIdentation;
|
||||||
anEditor.ExtraLineSpacing := lineSpacing;
|
anEditor.ExtraLineSpacing := lineSpacing;
|
||||||
|
|
|
||||||
|
|
@ -128,50 +128,62 @@ inherited CESearchWidget: TCESearchWidget
|
||||||
Align = alClient
|
Align = alClient
|
||||||
BorderSpacing.Around = 4
|
BorderSpacing.Around = 4
|
||||||
Caption = 'Options'
|
Caption = 'Options'
|
||||||
ClientHeight = 79
|
ClientHeight = 77
|
||||||
ClientWidth = 382
|
ClientWidth = 382
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
object chkWWord: TCheckBox
|
object chkWWord: TCheckBox
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 19
|
Height = 21
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 82
|
Width = 84
|
||||||
Caption = 'whole word'
|
Caption = 'whole word'
|
||||||
|
Checked = True
|
||||||
|
State = cbChecked
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
end
|
end
|
||||||
object chkBack: TCheckBox
|
object chkBack: TCheckBox
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 19
|
Height = 21
|
||||||
Top = 24
|
Top = 24
|
||||||
Width = 71
|
Width = 73
|
||||||
Caption = 'backward'
|
Caption = 'backward'
|
||||||
TabOrder = 1
|
TabOrder = 2
|
||||||
end
|
end
|
||||||
object chkFromCur: TCheckBox
|
object chkFromCur: TCheckBox
|
||||||
Left = 8
|
Left = 8
|
||||||
Height = 19
|
Height = 21
|
||||||
Top = 48
|
Top = 48
|
||||||
Width = 82
|
Width = 84
|
||||||
Caption = 'from cursor'
|
Caption = 'from cursor'
|
||||||
Checked = True
|
Checked = True
|
||||||
State = cbChecked
|
State = cbChecked
|
||||||
TabOrder = 2
|
TabOrder = 3
|
||||||
end
|
end
|
||||||
object chkCaseSens: TCheckBox
|
object chkCaseSens: TCheckBox
|
||||||
Left = 128
|
Left = 128
|
||||||
Height = 19
|
Height = 21
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 91
|
Width = 93
|
||||||
Caption = 'case sensitive'
|
Caption = 'case sensitive'
|
||||||
TabOrder = 3
|
TabOrder = 4
|
||||||
end
|
end
|
||||||
object chkPrompt: TCheckBox
|
object chkPrompt: TCheckBox
|
||||||
Left = 128
|
Left = 128
|
||||||
Height = 19
|
Height = 21
|
||||||
Top = 24
|
Top = 24
|
||||||
Width = 60
|
Width = 62
|
||||||
Caption = 'prompt'
|
Caption = 'prompt'
|
||||||
TabOrder = 4
|
TabOrder = 1
|
||||||
|
end
|
||||||
|
object chkRegex: TCheckBox
|
||||||
|
Left = 128
|
||||||
|
Height = 21
|
||||||
|
Top = 48
|
||||||
|
Width = 117
|
||||||
|
Caption = 'regular expression'
|
||||||
|
Checked = True
|
||||||
|
State = cbChecked
|
||||||
|
TabOrder = 5
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object btnReplaceAll: TBitBtn[4]
|
object btnReplaceAll: TBitBtn[4]
|
||||||
|
|
@ -232,25 +244,25 @@ inherited CESearchWidget: TCESearchWidget
|
||||||
ClientWidth = 386
|
ClientWidth = 386
|
||||||
TabOrder = 5
|
TabOrder = 5
|
||||||
object cbReplaceWth: TComboBox
|
object cbReplaceWth: TComboBox
|
||||||
Left = 90
|
Left = 92
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 296
|
Width = 294
|
||||||
Align = alClient
|
Align = alClient
|
||||||
Anchors = [akTop, akLeft, akBottom]
|
Anchors = [akTop, akLeft, akBottom]
|
||||||
ItemHeight = 15
|
ItemHeight = 15
|
||||||
OnChange = cbReplaceWthChange
|
OnChange = cbReplaceWthChange
|
||||||
TabOrder = 0
|
TabOrder = 1
|
||||||
end
|
end
|
||||||
object chkEnableRep: TCheckBox
|
object chkEnableRep: TCheckBox
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 23
|
Height = 23
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 90
|
Width = 92
|
||||||
Align = alLeft
|
Align = alLeft
|
||||||
Caption = 'Replace with '
|
Caption = 'Replace with '
|
||||||
OnChange = chkEnableRepChange
|
OnChange = chkEnableRepChange
|
||||||
TabOrder = 1
|
TabOrder = 0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,12 @@ interface
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ExtCtrls,
|
Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ExtCtrls,
|
||||||
Menus, StdCtrls, actnList, Buttons, SynEdit, SynEditSearch, SynEditTypes, ce_common,
|
Menus, StdCtrls, actnList, Buttons, SynEdit, SynEditSearch, SynEditTypes, ce_common,
|
||||||
ce_widget, ce_synmemo, ce_interfaces, ce_observer;
|
ce_widget, ce_synmemo, ce_interfaces, ce_observer, SynEditHighlighter;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
|
{ TCESearchWidget }
|
||||||
|
|
||||||
TCESearchWidget = class(TCEWidget, ICEMultiDocObserver)
|
TCESearchWidget = class(TCEWidget, ICEMultiDocObserver)
|
||||||
btnFind: TBitBtn;
|
btnFind: TBitBtn;
|
||||||
btnReplace: TBitBtn;
|
btnReplace: TBitBtn;
|
||||||
|
|
@ -18,6 +21,7 @@ type
|
||||||
cbReplaceWth: TComboBox;
|
cbReplaceWth: TComboBox;
|
||||||
chkEnableRep: TCheckBox;
|
chkEnableRep: TCheckBox;
|
||||||
chkPrompt: TCheckBox;
|
chkPrompt: TCheckBox;
|
||||||
|
chkRegex: TCheckBox;
|
||||||
chkWWord: TCheckBox;
|
chkWWord: TCheckBox;
|
||||||
chkBack: TCheckBox;
|
chkBack: TCheckBox;
|
||||||
chkFromCur: TCheckBox;
|
chkFromCur: TCheckBox;
|
||||||
|
|
@ -156,11 +160,12 @@ end;
|
||||||
|
|
||||||
function TCESearchWidget.getOptions: TSynSearchOptions;
|
function TCESearchWidget.getOptions: TSynSearchOptions;
|
||||||
begin
|
begin
|
||||||
result := [ssoRegExpr];
|
result := [];
|
||||||
if chkWWord.Checked then result += [ssoWholeWord];
|
if chkRegex.Checked then result += [ssoRegExpr];
|
||||||
if chkBack.Checked then result += [ssoBackwards];
|
if chkWWord.Checked then result += [ssoWholeWord];
|
||||||
if chkCaseSens.Checked then result += [ssoMatchCase];
|
if chkBack.Checked then result += [ssoBackwards];
|
||||||
if chkPrompt.Checked then result += [ssoPrompt];
|
if chkCaseSens.Checked then result += [ssoMatchCase];
|
||||||
|
if chkPrompt.Checked then result += [ssoPrompt];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function dlgReplaceAll: TModalResult;
|
function dlgReplaceAll: TModalResult;
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,7 @@ type
|
||||||
fParameters: TStringList;
|
fParameters: TStringList;
|
||||||
fToolAlias: string;
|
fToolAlias: string;
|
||||||
fQueryParams: boolean;
|
fQueryParams: boolean;
|
||||||
|
fClearMessages: boolean;
|
||||||
fChainBefore: TStringList;
|
fChainBefore: TStringList;
|
||||||
fChainAfter: TStringList;
|
fChainAfter: TStringList;
|
||||||
fShortcut: TShortcut;
|
fShortcut: TShortcut;
|
||||||
|
|
@ -37,6 +38,7 @@ type
|
||||||
property parameters: TStringList read fParameters write setParameters;
|
property parameters: TStringList read fParameters write setParameters;
|
||||||
property showWindows: TShowWindowOptions read fShowWin write fShowWin;
|
property showWindows: TShowWindowOptions read fShowWin write fShowWin;
|
||||||
property queryParameters: boolean read fQueryParams write fQueryParams;
|
property queryParameters: boolean read fQueryParams write fQueryParams;
|
||||||
|
property clearMessages: boolean read fClearMessages write fClearMessages;
|
||||||
property chainBefore: TStringList read fChainBefore write setchainBefore;
|
property chainBefore: TStringList read fChainBefore write setchainBefore;
|
||||||
property chainAfter: TStringList read fChainAfter write setChainAfter;
|
property chainAfter: TStringList read fChainAfter write setChainAfter;
|
||||||
property shortcut: TShortcut read fShortcut write fShortcut;
|
property shortcut: TShortcut read fShortcut write fShortcut;
|
||||||
|
|
@ -135,6 +137,9 @@ var
|
||||||
begin
|
begin
|
||||||
killProcess(fProcess);
|
killProcess(fProcess);
|
||||||
//
|
//
|
||||||
|
if fClearMessages then
|
||||||
|
getMessageDisplay(fMsgs).clearByContext(amcMisc);
|
||||||
|
//
|
||||||
fProcess := TCheckedAsyncProcess.Create(nil);
|
fProcess := TCheckedAsyncProcess.Create(nil);
|
||||||
fProcess.OnReadData:= @processOutput;
|
fProcess.OnReadData:= @processOutput;
|
||||||
fProcess.OnTerminate:= @processOutput;
|
fProcess.OnTerminate:= @processOutput;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue