mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-08 01:18:07 +02:00
started separate code templates dialog
git-svn-id: trunk@7600 -
This commit is contained in:
parent
747e74d401
commit
cf73b83525
2
.gitattributes
vendored
2
.gitattributes
vendored
@ -794,6 +794,8 @@ ide/codeexplorer.lfm svneol=native#text/plain
|
||||
ide/codeexplorer.lrs svneol=native#text/pascal
|
||||
ide/codeexplorer.pas svneol=native#text/pascal
|
||||
ide/codetemplatedialog.pp svneol=native#text/pascal
|
||||
ide/codetemplatesdlg.lfm svneol=native#text/plain
|
||||
ide/codetemplatesdlg.lrs svneol=native#text/plain
|
||||
ide/codetoolsdefines.lrs svneol=native#text/pascal
|
||||
ide/codetoolsdefines.pas svneol=native#text/pascal
|
||||
ide/codetoolsdefpreview.lfm svneol=native#text/plain
|
||||
|
@ -31,10 +31,41 @@ unit CodeTemplateDialog;
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, LCLIntf, LResources, Forms, Buttons, Controls,
|
||||
SynEditAutoComplete, LazarusIDEStrConsts, StdCtrls, SynEditKeyCmds, Dialogs;
|
||||
Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs,
|
||||
LazarusIDEStrConsts, StdCtrls, Buttons, SynEdit, SynHighlighterPas, ExtCtrls,
|
||||
EditorOptions, SynCompletion;
|
||||
|
||||
type
|
||||
|
||||
{ TCodeTemplateDialog }
|
||||
|
||||
TCodeTemplateDialog = class(TForm)
|
||||
AddButton: TButton;
|
||||
EditButton: TButton;
|
||||
DeleteButton: TButton;
|
||||
CancelButton: TButton;
|
||||
TemplateListBox: TListBox;
|
||||
TemplateSplitter: TSplitter;
|
||||
TemplateSynEdit: TSynEdit;
|
||||
ASynPasSyn: TSynPasSyn;
|
||||
TemplateGroupBox: TGroupBox;
|
||||
OkButton: TButton;
|
||||
FilenameButton: TButton;
|
||||
FilenameEdit: TEdit;
|
||||
FilenameGroupBox: TGroupBox;
|
||||
procedure AddButtonClick(Sender: TObject);
|
||||
procedure DeleteButtonClick(Sender: TObject);
|
||||
procedure EditButtonClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TemplateListBoxSelectionChange(Sender: TObject; User: boolean);
|
||||
private
|
||||
SynAutoComplete: TSynEditAutoComplete;
|
||||
public
|
||||
procedure FillCodeTemplateListBox;
|
||||
procedure ShowCurCodeTemplate;
|
||||
procedure SaveCurCodeTemplate;
|
||||
end;
|
||||
|
||||
TCodeTemplateEditForm = class(TForm)
|
||||
TokenLabel:TLabel;
|
||||
TokenEdit:TEdit;
|
||||
@ -50,6 +81,8 @@ type
|
||||
TemplateIndex:integer;
|
||||
end;
|
||||
|
||||
function ShowCodeTemplateDialog: TModalResult;
|
||||
|
||||
function AddCodeTemplate(ASynAutoComplete:TSynEditAutoComplete;
|
||||
var Token,Comment:ansistring):TModalResult;
|
||||
function EditCodeTemplate(ASynAutoComplete:TSynEditAutoComplete;
|
||||
@ -57,6 +90,15 @@ function EditCodeTemplate(ASynAutoComplete:TSynEditAutoComplete;
|
||||
|
||||
implementation
|
||||
|
||||
function ShowCodeTemplateDialog: TModalResult;
|
||||
var
|
||||
CodeTemplateDialog: TCodeTemplateDialog;
|
||||
begin
|
||||
CodeTemplateDialog:=TCodeTemplateDialog.Create(nil);
|
||||
Result:=CodeTemplateDialog.ShowModal;
|
||||
CodeTemplateDialog.Free;
|
||||
end;
|
||||
|
||||
function AddCodeTemplate(ASynAutoComplete:TSynEditAutoComplete;
|
||||
var Token,Comment:ansistring):TModalResult;
|
||||
var
|
||||
@ -247,4 +289,164 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
{ TCodeTemplateDialog }
|
||||
|
||||
procedure TCodeTemplateDialog.FormCreate(Sender: TObject);
|
||||
begin
|
||||
SynAutoComplete:=TSynEditAutoComplete.Create(Self);
|
||||
|
||||
AddButton.Caption:=lisCodeTemplAdd;
|
||||
EditButton.Caption:=lisCodeToolsDefsEdit;
|
||||
DeleteButton.Caption:=dlgEdDelete;
|
||||
CancelButton.Caption:=dlgCancel;
|
||||
TemplateGroupBox.Caption:=lisCTDTemplates;
|
||||
OkButton.Caption:=lisLazBuildOk;
|
||||
FilenameGroupBox.Caption:=lisToDoLFile;
|
||||
|
||||
FilenameEdit.Text:=EditorOpts.CodeTemplateFileName;
|
||||
|
||||
TemplateSynEdit.Gutter.Visible:=false;
|
||||
with SynAutoComplete do begin
|
||||
s:=EditorOpts.CodeTemplateFileName;
|
||||
if FileExists(s) then
|
||||
try
|
||||
AutoCompleteList.LoadFromFile(s);
|
||||
except
|
||||
DebugLn('NOTE: unable to read code template file ''',s,'''');
|
||||
end;
|
||||
end;
|
||||
FillCodeTemplateListBox;
|
||||
with CodeTemplateListBox do
|
||||
if Items.Count>0 then begin
|
||||
Selected[0]:=true;
|
||||
ShowCurCodeTemplate;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.AddButtonClick(Sender: TObject);
|
||||
var
|
||||
Token: String;
|
||||
Comment: String;
|
||||
begin
|
||||
SaveCurCodeTemplate;
|
||||
Token:='new';
|
||||
Comment:='(custom)';
|
||||
if AddCodeTemplate(SynAutoComplete,Token,Comment)=mrOk then begin
|
||||
SynAutoComplete.AddCompletion(Token, '', Comment);
|
||||
FillCodeTemplateListBox;
|
||||
Index:=SynAutoComplete.Completions.IndexOf(Token);
|
||||
if (Index>=0) and (Index<TemplateListBox.Items.Count) then begin
|
||||
TemplateListBox.ItemIndex:=Index;
|
||||
end;
|
||||
ShowCurCodeTemplate;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.DeleteButtonClick(Sender: TObject);
|
||||
var
|
||||
i: LongInt;
|
||||
begin
|
||||
i:=TemplateListBox.ItemIndex;
|
||||
if i<0 then exit;
|
||||
if MessageDlg(dlgDelTemplate
|
||||
+'"'+SynAutoComplete.Completions[i]+' - '
|
||||
+SynAutoComplete.CompletionComments[i]+'"'
|
||||
+'?',mtConfirmation,[mbOk,mbCancel],0)=mrOK then begin
|
||||
SynAutoComplete.DeleteCompletion(i);
|
||||
FillCodeTemplateListBox;
|
||||
if (i>=0) and (i<CodeTemplateListBox.Items.Count) then begin
|
||||
CodeTemplateListBox.ItemIndex:=i;
|
||||
end;
|
||||
ShowCurCodeTemplate;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.EditButtonClick(Sender: TObject);
|
||||
begin
|
||||
i:=TemplateListBox.ItemIndex;
|
||||
if i<0 then exit;
|
||||
if EditCodeTemplate(SynAutoComplete,i)=mrOk then begin
|
||||
CodeTemplateListBox.Items[i]:=
|
||||
SynAutoComplete.Completions[i]
|
||||
+' - "'+SynAutoComplete.CompletionComments[i]+'"';
|
||||
ShowCurCodeTemplate;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.TemplateListBoxSelectionChange(Sender: TObject;
|
||||
User: boolean);
|
||||
begin
|
||||
SaveCurCodeTemplate;
|
||||
ShowCurCodeTemplate;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.FillCodeTemplateListBox;
|
||||
var a:integer;
|
||||
begin
|
||||
with TemplateListBox do begin
|
||||
Items.BeginUpdate;
|
||||
Items.Clear;
|
||||
for a:=0 to SynAutoComplete.Completions.Count-1 do begin
|
||||
Items.Add(SynAutoComplete.Completions[a]
|
||||
+' - "'+SynAutoComplete.CompletionComments[a]+'"');
|
||||
end;
|
||||
Items.EndUpdate;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.ShowCurCodeTemplate;
|
||||
var
|
||||
i, sp, ep: integer;
|
||||
s: string;
|
||||
begin
|
||||
TemplateSynEdit.Lines.BeginUpdate;
|
||||
TemplateSynEdit.Lines.Clear;
|
||||
i:=TemplateListBox.ItemIndex;
|
||||
if i>=0 then begin
|
||||
CurCodeTemplate:=i;
|
||||
s:=SynAutoComplete.CompletionValues[i];
|
||||
sp:=1;
|
||||
ep:=1;
|
||||
while ep<=length(s) do begin
|
||||
if s[ep] in [#10,#13] then begin
|
||||
TemplateSynEdit.Lines.Add(copy(s,sp,ep-sp));
|
||||
inc(ep);
|
||||
if (ep<=length(s)) and (s[ep] in [#10,#13]) and (s[ep-1]<>s[ep]) then
|
||||
inc(ep);
|
||||
sp:=ep;
|
||||
end else inc(ep);
|
||||
end;
|
||||
if (ep>sp) or ((s<>'') and (s[length(s)] in [#10,#13])) then
|
||||
TemplateSynEdit.Lines.Add(copy(s,sp,ep-sp));
|
||||
end;
|
||||
TemplateSynEdit.Lines.EndUpdate;
|
||||
TemplateSynEdit.Invalidate;
|
||||
end;
|
||||
|
||||
procedure TCodeTemplateDialog.SaveCurCodeTemplate;
|
||||
var
|
||||
NewValue: string;
|
||||
l: integer;
|
||||
i: LongInt;
|
||||
begin
|
||||
i:=TemplateListBox.ItemIndex;
|
||||
if i<0 then exit;
|
||||
NewValue:=CodeTemplateCodePreview.Lines.Text;
|
||||
// remove last EOL
|
||||
if NewValue<>'' then begin
|
||||
l:=length(NewValue);
|
||||
if NewValue[l] in [#10,#13] then begin
|
||||
dec(l);
|
||||
if (l>0) and (NewValue[l] in [#10,#13])
|
||||
and (NewValue[l]<>NewValue[l+1]) then
|
||||
dec(l);
|
||||
SetLength(NewValue,l);
|
||||
end;
|
||||
end;
|
||||
SynAutoComplete.CompletionValues[i]:=NewValue;
|
||||
end;
|
||||
|
||||
initialization
|
||||
{$I codetemplatesdlg.lrs}
|
||||
|
||||
end.
|
||||
|
492
ide/codetemplatesdlg.lfm
Normal file
492
ide/codetemplatesdlg.lfm
Normal file
@ -0,0 +1,492 @@
|
||||
object CodeTemplateDialog: TCodeTemplateDialog
|
||||
Caption = 'CodeTemplateDialog'
|
||||
ClientHeight = 432
|
||||
ClientWidth = 596
|
||||
OnCreate = FormCreate
|
||||
PixelsPerInch = 112
|
||||
HorzScrollBar.Page = 595
|
||||
VertScrollBar.Page = 431
|
||||
Left = 290
|
||||
Height = 432
|
||||
Top = 163
|
||||
Width = 596
|
||||
object FilenameGroupBox: TGroupBox
|
||||
Align = alTop
|
||||
BorderSpacing.OnChange = nil
|
||||
BorderSpacing.Around = 5
|
||||
Caption = 'FilenameGroupBox'
|
||||
ClientHeight = 42
|
||||
ClientWidth = 582
|
||||
ParentColor = True
|
||||
TabOrder = 0
|
||||
Left = 5
|
||||
Height = 59
|
||||
Top = 5
|
||||
Width = 586
|
||||
object FilenameEdit: TEdit
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.OnChange = nil
|
||||
BorderSpacing.Right = 5
|
||||
TabOrder = 0
|
||||
Text = 'FilenameEdit'
|
||||
AnchorSideRight.Control = FilenameButton
|
||||
Left = 9
|
||||
Height = 23
|
||||
Top = 4
|
||||
Width = 531
|
||||
end
|
||||
object FilenameButton: TButton
|
||||
Anchors = [akTop, akLeft, akBottom]
|
||||
BorderSpacing.OnChange = nil
|
||||
Caption = '...'
|
||||
TabOrder = 1
|
||||
AnchorSideBottom.Control = FilenameEdit
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 545
|
||||
Height = 23
|
||||
Top = 4
|
||||
Width = 30
|
||||
end
|
||||
end
|
||||
object OkButton: TButton
|
||||
Anchors = [akRight, akBottom]
|
||||
AutoSize = True
|
||||
BorderSpacing.OnChange = nil
|
||||
BorderSpacing.Right = 14
|
||||
Caption = 'OkButton'
|
||||
TabOrder = 1
|
||||
AnchorSideRight.Control = CancelButton
|
||||
AnchorSideBottom.Control = CancelButton
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 403
|
||||
Height = 25
|
||||
Top = 397
|
||||
Width = 91
|
||||
end
|
||||
object CancelButton: TButton
|
||||
Anchors = [akRight, akBottom]
|
||||
AutoSize = True
|
||||
BorderSpacing.OnChange = nil
|
||||
Caption = 'CancelButton'
|
||||
ModalResult = 2
|
||||
TabOrder = 2
|
||||
Left = 508
|
||||
Height = 25
|
||||
Top = 397
|
||||
Width = 75
|
||||
end
|
||||
object TemplateGroupBox: TGroupBox
|
||||
Align = alTop
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
BorderSpacing.OnChange = nil
|
||||
BorderSpacing.Around = 5
|
||||
Caption = 'TemplateGroupBox'
|
||||
ClientHeight = 306
|
||||
ClientWidth = 582
|
||||
ParentColor = True
|
||||
TabOrder = 3
|
||||
AnchorSideBottom.Control = CancelButton
|
||||
Left = 5
|
||||
Height = 323
|
||||
Top = 69
|
||||
Width = 586
|
||||
object TemplateListBox: TListBox
|
||||
Align = alLeft
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
BorderSpacing.OnChange = nil
|
||||
OnSelectionChange = TemplateListBoxSelectionChange
|
||||
TabOrder = 0
|
||||
TopIndex = -1
|
||||
Height = 151
|
||||
Width = 447
|
||||
end
|
||||
object TemplateSynEdit: TSynEdit
|
||||
Align = alBottom
|
||||
BorderSpacing.OnChange = nil
|
||||
Font.Height = -18
|
||||
Font.Name = 'courier'
|
||||
Height = 150
|
||||
Name = 'TemplateSynEdit'
|
||||
TabOrder = 1
|
||||
Width = 582
|
||||
BookMarkOptions.OnChange = nil
|
||||
Gutter.OnChange = nil
|
||||
Gutter.CodeFoldingWidth = 14
|
||||
Highlighter = ASynPasSyn
|
||||
Keystrokes = <
|
||||
item
|
||||
Command = 3
|
||||
ShortCut = 38
|
||||
end
|
||||
item
|
||||
Command = 103
|
||||
ShortCut = 8230
|
||||
end
|
||||
item
|
||||
Command = 211
|
||||
ShortCut = 16422
|
||||
end
|
||||
item
|
||||
Command = 4
|
||||
ShortCut = 40
|
||||
end
|
||||
item
|
||||
Command = 104
|
||||
ShortCut = 8232
|
||||
end
|
||||
item
|
||||
Command = 212
|
||||
ShortCut = 16424
|
||||
end
|
||||
item
|
||||
Command = 1
|
||||
ShortCut = 37
|
||||
end
|
||||
item
|
||||
Command = 101
|
||||
ShortCut = 8229
|
||||
end
|
||||
item
|
||||
Command = 5
|
||||
ShortCut = 16421
|
||||
end
|
||||
item
|
||||
Command = 105
|
||||
ShortCut = 24613
|
||||
end
|
||||
item
|
||||
Command = 2
|
||||
ShortCut = 39
|
||||
end
|
||||
item
|
||||
Command = 102
|
||||
ShortCut = 8231
|
||||
end
|
||||
item
|
||||
Command = 6
|
||||
ShortCut = 16423
|
||||
end
|
||||
item
|
||||
Command = 106
|
||||
ShortCut = 24615
|
||||
end
|
||||
item
|
||||
Command = 10
|
||||
ShortCut = 34
|
||||
end
|
||||
item
|
||||
Command = 110
|
||||
ShortCut = 8226
|
||||
end
|
||||
item
|
||||
Command = 14
|
||||
ShortCut = 16418
|
||||
end
|
||||
item
|
||||
Command = 114
|
||||
ShortCut = 24610
|
||||
end
|
||||
item
|
||||
Command = 9
|
||||
ShortCut = 33
|
||||
end
|
||||
item
|
||||
Command = 109
|
||||
ShortCut = 8225
|
||||
end
|
||||
item
|
||||
Command = 13
|
||||
ShortCut = 16417
|
||||
end
|
||||
item
|
||||
Command = 113
|
||||
ShortCut = 24609
|
||||
end
|
||||
item
|
||||
Command = 7
|
||||
ShortCut = 36
|
||||
end
|
||||
item
|
||||
Command = 107
|
||||
ShortCut = 8228
|
||||
end
|
||||
item
|
||||
Command = 15
|
||||
ShortCut = 16420
|
||||
end
|
||||
item
|
||||
Command = 115
|
||||
ShortCut = 24612
|
||||
end
|
||||
item
|
||||
Command = 8
|
||||
ShortCut = 35
|
||||
end
|
||||
item
|
||||
Command = 108
|
||||
ShortCut = 8227
|
||||
end
|
||||
item
|
||||
Command = 16
|
||||
ShortCut = 16419
|
||||
end
|
||||
item
|
||||
Command = 116
|
||||
ShortCut = 24611
|
||||
end
|
||||
item
|
||||
Command = 223
|
||||
ShortCut = 45
|
||||
end
|
||||
item
|
||||
Command = 201
|
||||
ShortCut = 16429
|
||||
end
|
||||
item
|
||||
Command = 604
|
||||
ShortCut = 8237
|
||||
end
|
||||
item
|
||||
Command = 502
|
||||
ShortCut = 46
|
||||
end
|
||||
item
|
||||
Command = 603
|
||||
ShortCut = 8238
|
||||
end
|
||||
item
|
||||
Command = 501
|
||||
ShortCut = 8
|
||||
end
|
||||
item
|
||||
Command = 501
|
||||
ShortCut = 8200
|
||||
end
|
||||
item
|
||||
Command = 504
|
||||
ShortCut = 16392
|
||||
end
|
||||
item
|
||||
Command = 601
|
||||
ShortCut = 32776
|
||||
end
|
||||
item
|
||||
Command = 602
|
||||
ShortCut = 40968
|
||||
end
|
||||
item
|
||||
Command = 509
|
||||
ShortCut = 13
|
||||
end
|
||||
item
|
||||
Command = 199
|
||||
ShortCut = 16449
|
||||
end
|
||||
item
|
||||
Command = 201
|
||||
ShortCut = 16451
|
||||
end
|
||||
item
|
||||
Command = 610
|
||||
ShortCut = 24649
|
||||
end
|
||||
item
|
||||
Command = 509
|
||||
ShortCut = 16461
|
||||
end
|
||||
item
|
||||
Command = 510
|
||||
ShortCut = 16462
|
||||
end
|
||||
item
|
||||
Command = 503
|
||||
ShortCut = 16468
|
||||
end
|
||||
item
|
||||
Command = 611
|
||||
ShortCut = 24661
|
||||
end
|
||||
item
|
||||
Command = 604
|
||||
ShortCut = 16470
|
||||
end
|
||||
item
|
||||
Command = 603
|
||||
ShortCut = 16472
|
||||
end
|
||||
item
|
||||
Command = 507
|
||||
ShortCut = 16473
|
||||
end
|
||||
item
|
||||
Command = 506
|
||||
ShortCut = 24665
|
||||
end
|
||||
item
|
||||
Command = 601
|
||||
ShortCut = 16474
|
||||
end
|
||||
item
|
||||
Command = 602
|
||||
ShortCut = 24666
|
||||
end
|
||||
item
|
||||
Command = 301
|
||||
ShortCut = 16432
|
||||
end
|
||||
item
|
||||
Command = 302
|
||||
ShortCut = 16433
|
||||
end
|
||||
item
|
||||
Command = 303
|
||||
ShortCut = 16434
|
||||
end
|
||||
item
|
||||
Command = 304
|
||||
ShortCut = 16435
|
||||
end
|
||||
item
|
||||
Command = 305
|
||||
ShortCut = 16436
|
||||
end
|
||||
item
|
||||
Command = 306
|
||||
ShortCut = 16437
|
||||
end
|
||||
item
|
||||
Command = 307
|
||||
ShortCut = 16438
|
||||
end
|
||||
item
|
||||
Command = 308
|
||||
ShortCut = 16439
|
||||
end
|
||||
item
|
||||
Command = 309
|
||||
ShortCut = 16440
|
||||
end
|
||||
item
|
||||
Command = 310
|
||||
ShortCut = 16441
|
||||
end
|
||||
item
|
||||
Command = 351
|
||||
ShortCut = 24624
|
||||
end
|
||||
item
|
||||
Command = 352
|
||||
ShortCut = 24625
|
||||
end
|
||||
item
|
||||
Command = 353
|
||||
ShortCut = 24626
|
||||
end
|
||||
item
|
||||
Command = 354
|
||||
ShortCut = 24627
|
||||
end
|
||||
item
|
||||
Command = 355
|
||||
ShortCut = 24628
|
||||
end
|
||||
item
|
||||
Command = 356
|
||||
ShortCut = 24629
|
||||
end
|
||||
item
|
||||
Command = 357
|
||||
ShortCut = 24630
|
||||
end
|
||||
item
|
||||
Command = 358
|
||||
ShortCut = 24631
|
||||
end
|
||||
item
|
||||
Command = 359
|
||||
ShortCut = 24632
|
||||
end
|
||||
item
|
||||
Command = 360
|
||||
ShortCut = 24633
|
||||
end
|
||||
item
|
||||
Command = 231
|
||||
ShortCut = 24654
|
||||
end
|
||||
item
|
||||
Command = 232
|
||||
ShortCut = 24643
|
||||
end
|
||||
item
|
||||
Command = 233
|
||||
ShortCut = 24652
|
||||
end
|
||||
item
|
||||
Command = 612
|
||||
ShortCut = 9
|
||||
end
|
||||
item
|
||||
Command = 613
|
||||
ShortCut = 8201
|
||||
end
|
||||
item
|
||||
Command = 250
|
||||
ShortCut = 24642
|
||||
end>
|
||||
Lines.Strings = (
|
||||
'TemplateSynEdit'
|
||||
)
|
||||
SelectedColor.OnChange = nil
|
||||
Cursor = crIBeam
|
||||
Height = 150
|
||||
Top = 156
|
||||
Width = 582
|
||||
end
|
||||
object TemplateSplitter: TSplitter
|
||||
Align = alBottom
|
||||
Cursor = crVSplit
|
||||
Height = 5
|
||||
ParentColor = True
|
||||
Width = 582
|
||||
Cursor = crVSplit
|
||||
Height = 5
|
||||
Top = 151
|
||||
Width = 582
|
||||
end
|
||||
object AddButton: TButton
|
||||
BorderSpacing.OnChange = nil
|
||||
Caption = 'AddButton'
|
||||
OnClick = AddButtonClick
|
||||
TabOrder = 2
|
||||
Left = 457
|
||||
Height = 32
|
||||
Width = 115
|
||||
end
|
||||
object DeleteButton: TButton
|
||||
BorderSpacing.OnChange = nil
|
||||
Caption = 'DeleteButton'
|
||||
OnClick = DeleteButtonClick
|
||||
TabOrder = 3
|
||||
Left = 457
|
||||
Height = 32
|
||||
Top = 44
|
||||
Width = 115
|
||||
end
|
||||
object EditButton: TButton
|
||||
BorderSpacing.OnChange = nil
|
||||
Caption = 'EditButton'
|
||||
OnClick = EditButtonClick
|
||||
TabOrder = 4
|
||||
Left = 457
|
||||
Height = 32
|
||||
Top = 92
|
||||
Width = 115
|
||||
end
|
||||
end
|
||||
object ASynPasSyn: TSynPasSyn
|
||||
Enabled = False
|
||||
left = 277
|
||||
top = 216
|
||||
end
|
||||
end
|
97
ide/codetemplatesdlg.lrs
Normal file
97
ide/codetemplatesdlg.lrs
Normal file
@ -0,0 +1,97 @@
|
||||
{ This is an automatically generated lazarus resource file }
|
||||
|
||||
LazarusResources.Add('TCodeTemplateDialog','FORMDATA',[
|
||||
'TPF0'#19'TCodeTemplateDialog'#18'CodeTemplateDialog'#7'Caption'#6#18'CodeTem'
|
||||
+'plateDialog'#12'ClientHeight'#3#176#1#11'ClientWidth'#3'T'#2#8'OnCreate'#7
|
||||
+#10'FormCreate'#13'PixelsPerInch'#2'p'#18'HorzScrollBar.Page'#3'S'#2#18'Vert'
|
||||
+'ScrollBar.Page'#3#175#1#4'Left'#3'"'#1#6'Height'#3#176#1#3'Top'#3#163#0#5'W'
|
||||
+'idth'#3'T'#2#0#9'TGroupBox'#16'FilenameGroupBox'#5'Align'#7#5'alTop'#22'Bor'
|
||||
+'derSpacing.OnChange'#13#20'BorderSpacing.Around'#2#5#7'Caption'#6#16'Filena'
|
||||
+'meGroupBox'#12'ClientHeight'#2'*'#11'ClientWidth'#3'F'#2#11'ParentColor'#9#8
|
||||
+'TabOrder'#2#0#4'Left'#2#5#6'Height'#2';'#3'Top'#2#5#5'Width'#3'J'#2#0#5'TEd'
|
||||
+'it'#12'FilenameEdit'#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#0#22'Borde'
|
||||
+'rSpacing.OnChange'#13#19'BorderSpacing.Right'#2#5#8'TabOrder'#2#0#4'Text'#6
|
||||
+#12'FilenameEdit'#23'AnchorSideRight.Control'#7#14'FilenameButton'#4'Left'#2
|
||||
+#9#6'Height'#2#23#3'Top'#2#4#5'Width'#3#19#2#0#0#7'TButton'#14'FilenameButto'
|
||||
+'n'#7'Anchors'#11#5'akTop'#6'akLeft'#8'akBottom'#0#22'BorderSpacing.OnChange'
|
||||
+#13#7'Caption'#6#3'...'#8'TabOrder'#2#1#24'AnchorSideBottom.Control'#7#12'Fi'
|
||||
+'lenameEdit'#21'AnchorSideBottom.Side'#7#9'asrBottom'#4'Left'#3'!'#2#6'Heigh'
|
||||
+'t'#2#23#3'Top'#2#4#5'Width'#2#30#0#0#0#7'TButton'#8'OkButton'#7'Anchors'#11
|
||||
+#7'akRight'#8'akBottom'#0#8'AutoSize'#9#22'BorderSpacing.OnChange'#13#19'Bor'
|
||||
+'derSpacing.Right'#2#14#7'Caption'#6#8'OkButton'#8'TabOrder'#2#1#23'AnchorSi'
|
||||
+'deRight.Control'#7#12'CancelButton'#24'AnchorSideBottom.Control'#7#12'Cance'
|
||||
+'lButton'#21'AnchorSideBottom.Side'#7#9'asrBottom'#4'Left'#3#147#1#6'Height'
|
||||
+#2#25#3'Top'#3#141#1#5'Width'#2'['#0#0#7'TButton'#12'CancelButton'#7'Anchors'
|
||||
+#11#7'akRight'#8'akBottom'#0#8'AutoSize'#9#22'BorderSpacing.OnChange'#13#7'C'
|
||||
+'aption'#6#12'CancelButton'#11'ModalResult'#2#2#8'TabOrder'#2#2#4'Left'#3#252
|
||||
+#1#6'Height'#2#25#3'Top'#3#141#1#5'Width'#2'K'#0#0#9'TGroupBox'#16'TemplateG'
|
||||
+'roupBox'#5'Align'#7#5'alTop'#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#8
|
||||
+'akBottom'#0#22'BorderSpacing.OnChange'#13#20'BorderSpacing.Around'#2#5#7'Ca'
|
||||
+'ption'#6#16'TemplateGroupBox'#12'ClientHeight'#3'2'#1#11'ClientWidth'#3'F'#2
|
||||
+#11'ParentColor'#9#8'TabOrder'#2#3#24'AnchorSideBottom.Control'#7#12'CancelB'
|
||||
+'utton'#4'Left'#2#5#6'Height'#3'C'#1#3'Top'#2'E'#5'Width'#3'J'#2#0#8'TListBo'
|
||||
+'x'#15'TemplateListBox'#5'Align'#7#6'alLeft'#7'Anchors'#11#5'akTop'#6'akLeft'
|
||||
+#7'akRight'#8'akBottom'#0#22'BorderSpacing.OnChange'#13#17'OnSelectionChange'
|
||||
+#7#30'TemplateListBoxSelectionChange'#8'TabOrder'#2#0#8'TopIndex'#2#255#6'He'
|
||||
+'ight'#3#151#0#5'Width'#3#191#1#0#0#8'TSynEdit'#15'TemplateSynEdit'#5'Align'
|
||||
+#7#8'alBottom'#22'BorderSpacing.OnChange'#13#11'Font.Height'#2#238#9'Font.Na'
|
||||
+'me'#6#7'courier'#6'Height'#3#150#0#4'Name'#6#15'TemplateSynEdit'#8'TabOrder'
|
||||
+#2#1#5'Width'#3'F'#2#24'BookMarkOptions.OnChange'#13#15'Gutter.OnChange'#13
|
||||
+#23'Gutter.CodeFoldingWidth'#2#14#11'Highlighter'#7#10'ASynPasSyn'#10'Keystr'
|
||||
+'okes'#14#1#7'Command'#2#3#8'ShortCut'#2'&'#0#1#7'Command'#2'g'#8'ShortCut'#3
|
||||
+'& '#0#1#7'Command'#3#211#0#8'ShortCut'#3'&@'#0#1#7'Command'#2#4#8'ShortCut'
|
||||
+#2'('#0#1#7'Command'#2'h'#8'ShortCut'#3'( '#0#1#7'Command'#3#212#0#8'ShortCu'
|
||||
+'t'#3'(@'#0#1#7'Command'#2#1#8'ShortCut'#2'%'#0#1#7'Command'#2'e'#8'ShortCut'
|
||||
+#3'% '#0#1#7'Command'#2#5#8'ShortCut'#3'%@'#0#1#7'Command'#2'i'#8'ShortCut'#3
|
||||
+'%`'#0#1#7'Command'#2#2#8'ShortCut'#2''''#0#1#7'Command'#2'f'#8'ShortCut'#3
|
||||
+''' '#0#1#7'Command'#2#6#8'ShortCut'#3'''@'#0#1#7'Command'#2'j'#8'ShortCut'#3
|
||||
+'''`'#0#1#7'Command'#2#10#8'ShortCut'#2'"'#0#1#7'Command'#2'n'#8'ShortCut'#3
|
||||
+'" '#0#1#7'Command'#2#14#8'ShortCut'#3'"@'#0#1#7'Command'#2'r'#8'ShortCut'#3
|
||||
+'"`'#0#1#7'Command'#2#9#8'ShortCut'#2'!'#0#1#7'Command'#2'm'#8'ShortCut'#3'!'
|
||||
+' '#0#1#7'Command'#2#13#8'ShortCut'#3'!@'#0#1#7'Command'#2'q'#8'ShortCut'#3
|
||||
+'!`'#0#1#7'Command'#2#7#8'ShortCut'#2'$'#0#1#7'Command'#2'k'#8'ShortCut'#3'$'
|
||||
+' '#0#1#7'Command'#2#15#8'ShortCut'#3'$@'#0#1#7'Command'#2's'#8'ShortCut'#3
|
||||
+'$`'#0#1#7'Command'#2#8#8'ShortCut'#2'#'#0#1#7'Command'#2'l'#8'ShortCut'#3'#'
|
||||
+' '#0#1#7'Command'#2#16#8'ShortCut'#3'#@'#0#1#7'Command'#2't'#8'ShortCut'#3
|
||||
+'#`'#0#1#7'Command'#3#223#0#8'ShortCut'#2'-'#0#1#7'Command'#3#201#0#8'ShortC'
|
||||
+'ut'#3'-@'#0#1#7'Command'#3'\'#2#8'ShortCut'#3'- '#0#1#7'Command'#3#246#1#8
|
||||
+'ShortCut'#2'.'#0#1#7'Command'#3'['#2#8'ShortCut'#3'. '#0#1#7'Command'#3#245
|
||||
+#1#8'ShortCut'#2#8#0#1#7'Command'#3#245#1#8'ShortCut'#3#8' '#0#1#7'Command'#3
|
||||
+#248#1#8'ShortCut'#3#8'@'#0#1#7'Command'#3'Y'#2#8'ShortCut'#4#8#128#0#0#0#1#7
|
||||
+'Command'#3'Z'#2#8'ShortCut'#4#8#160#0#0#0#1#7'Command'#3#253#1#8'ShortCut'#2
|
||||
+#13#0#1#7'Command'#3#199#0#8'ShortCut'#3'A@'#0#1#7'Command'#3#201#0#8'ShortC'
|
||||
+'ut'#3'C@'#0#1#7'Command'#3'b'#2#8'ShortCut'#3'I`'#0#1#7'Command'#3#253#1#8
|
||||
+'ShortCut'#3'M@'#0#1#7'Command'#3#254#1#8'ShortCut'#3'N@'#0#1#7'Command'#3
|
||||
+#247#1#8'ShortCut'#3'T@'#0#1#7'Command'#3'c'#2#8'ShortCut'#3'U`'#0#1#7'Comma'
|
||||
+'nd'#3'\'#2#8'ShortCut'#3'V@'#0#1#7'Command'#3'['#2#8'ShortCut'#3'X@'#0#1#7
|
||||
+'Command'#3#251#1#8'ShortCut'#3'Y@'#0#1#7'Command'#3#250#1#8'ShortCut'#3'Y`'
|
||||
,#0#1#7'Command'#3'Y'#2#8'ShortCut'#3'Z@'#0#1#7'Command'#3'Z'#2#8'ShortCut'#3
|
||||
+'Z`'#0#1#7'Command'#3'-'#1#8'ShortCut'#3'0@'#0#1#7'Command'#3'.'#1#8'ShortCu'
|
||||
+'t'#3'1@'#0#1#7'Command'#3'/'#1#8'ShortCut'#3'2@'#0#1#7'Command'#3'0'#1#8'Sh'
|
||||
+'ortCut'#3'3@'#0#1#7'Command'#3'1'#1#8'ShortCut'#3'4@'#0#1#7'Command'#3'2'#1
|
||||
+#8'ShortCut'#3'5@'#0#1#7'Command'#3'3'#1#8'ShortCut'#3'6@'#0#1#7'Command'#3
|
||||
+'4'#1#8'ShortCut'#3'7@'#0#1#7'Command'#3'5'#1#8'ShortCut'#3'8@'#0#1#7'Comman'
|
||||
+'d'#3'6'#1#8'ShortCut'#3'9@'#0#1#7'Command'#3'_'#1#8'ShortCut'#3'0`'#0#1#7'C'
|
||||
+'ommand'#3'`'#1#8'ShortCut'#3'1`'#0#1#7'Command'#3'a'#1#8'ShortCut'#3'2`'#0#1
|
||||
+#7'Command'#3'b'#1#8'ShortCut'#3'3`'#0#1#7'Command'#3'c'#1#8'ShortCut'#3'4`'
|
||||
+#0#1#7'Command'#3'd'#1#8'ShortCut'#3'5`'#0#1#7'Command'#3'e'#1#8'ShortCut'#3
|
||||
+'6`'#0#1#7'Command'#3'f'#1#8'ShortCut'#3'7`'#0#1#7'Command'#3'g'#1#8'ShortCu'
|
||||
+'t'#3'8`'#0#1#7'Command'#3'h'#1#8'ShortCut'#3'9`'#0#1#7'Command'#3#231#0#8'S'
|
||||
+'hortCut'#3'N`'#0#1#7'Command'#3#232#0#8'ShortCut'#3'C`'#0#1#7'Command'#3#233
|
||||
+#0#8'ShortCut'#3'L`'#0#1#7'Command'#3'd'#2#8'ShortCut'#2#9#0#1#7'Command'#3
|
||||
+'e'#2#8'ShortCut'#3#9' '#0#1#7'Command'#3#250#0#8'ShortCut'#3'B`'#0#0#13'Lin'
|
||||
+'es.Strings'#1#6#15'TemplateSynEdit'#0#22'SelectedColor.OnChange'#13#6'Curso'
|
||||
+'r'#7#7'crIBeam'#6'Height'#3#150#0#3'Top'#3#156#0#5'Width'#3'F'#2#0#0#9'TSpl'
|
||||
+'itter'#16'TemplateSplitter'#5'Align'#7#8'alBottom'#6'Cursor'#7#8'crVSplit'#6
|
||||
+'Height'#2#5#11'ParentColor'#9#5'Width'#3'F'#2#6'Cursor'#7#8'crVSplit'#6'Hei'
|
||||
+'ght'#2#5#3'Top'#3#151#0#5'Width'#3'F'#2#0#0#7'TButton'#9'AddButton'#22'Bord'
|
||||
+'erSpacing.OnChange'#13#7'Caption'#6#9'AddButton'#7'OnClick'#7#14'AddButtonC'
|
||||
+'lick'#8'TabOrder'#2#2#4'Left'#3#201#1#6'Height'#2' '#5'Width'#2's'#0#0#7'TB'
|
||||
+'utton'#12'DeleteButton'#22'BorderSpacing.OnChange'#13#7'Caption'#6#12'Delet'
|
||||
+'eButton'#7'OnClick'#7#17'DeleteButtonClick'#8'TabOrder'#2#3#4'Left'#3#201#1
|
||||
+#6'Height'#2' '#3'Top'#2','#5'Width'#2's'#0#0#7'TButton'#10'EditButton'#22'B'
|
||||
+'orderSpacing.OnChange'#13#7'Caption'#6#10'EditButton'#7'OnClick'#7#15'EditB'
|
||||
+'uttonClick'#8'TabOrder'#2#4#4'Left'#3#201#1#6'Height'#2' '#3'Top'#2'\'#5'Wi'
|
||||
+'dth'#2's'#0#0#0#10'TSynPasSyn'#10'ASynPasSyn'#7'Enabled'#8#4'left'#3#21#1#3
|
||||
+'top'#3#216#0#0#0#0
|
||||
]);
|
Loading…
Reference in New Issue
Block a user