mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-29 23:10:16 +02:00
MG: added insert Username and Datetime
git-svn-id: trunk@2960 -
This commit is contained in:
parent
4380c9f329
commit
04d5647ca5
@ -225,6 +225,8 @@ type
|
||||
procedure SelectParagraph;
|
||||
function CommentText(const Txt: string; CommentType: TCommentType): string;
|
||||
procedure InsertGPLNotice(CommentType: TCommentType);
|
||||
procedure InsertUsername;
|
||||
procedure InsertDateTime;
|
||||
|
||||
|
||||
// editor commands
|
||||
@ -916,6 +918,12 @@ Begin
|
||||
ecInsertGPLNotice:
|
||||
InsertGPLNotice(comtDefault);
|
||||
|
||||
ecInsertUserName:
|
||||
InsertUsername;
|
||||
|
||||
ecInsertDateTime:
|
||||
InsertDateTime;
|
||||
|
||||
else
|
||||
begin
|
||||
Handled:=false;
|
||||
@ -1148,6 +1156,16 @@ begin
|
||||
FEditor.SelText:=Txt;
|
||||
end;
|
||||
|
||||
procedure TSourceEditor.InsertUsername;
|
||||
begin
|
||||
FEditor.SelText:=GetCurrentUserName;
|
||||
end;
|
||||
|
||||
procedure TSourceEditor.InsertDateTime;
|
||||
begin
|
||||
FEditor.SelText:=DateTimeToStr(now);
|
||||
end;
|
||||
|
||||
procedure TSourceEditor.RemoveBreakPoint(const ABreakPointMark: TSynEditMark);
|
||||
begin
|
||||
if not IsBreakPointMark(ABreakPointMark) then Exit;
|
||||
|
Loading…
Reference in New Issue
Block a user