mirror of https://gitlab.com/basile.b/dexed.git
first run, changed default option + add a runnable
This commit is contained in:
parent
1ff8b9e878
commit
36f199f828
|
@ -165,10 +165,15 @@ begin
|
||||||
inherited;
|
inherited;
|
||||||
//
|
//
|
||||||
fFont := TFont.Create;
|
fFont := TFont.Create;
|
||||||
|
{$IFDEF WINDOWS}
|
||||||
fFont.Name := 'Courier New';
|
fFont.Name := 'Courier New';
|
||||||
|
{$ELSE}
|
||||||
|
fFont.Name := 'DejaVu Sans Mono';
|
||||||
|
{$ENDIF}
|
||||||
fFont.Quality := fqProof;
|
fFont.Quality := fqProof;
|
||||||
fFont.Pitch := fpFixed;
|
fFont.Pitch := fpFixed;
|
||||||
fFont.Size := 10;
|
fFont.Size := 10;
|
||||||
|
fResetFontSize:=true;
|
||||||
//
|
//
|
||||||
fD2Syn := TSynD2Syn.Create(self);
|
fD2Syn := TSynD2Syn.Create(self);
|
||||||
fD2Syn.Assign(D2Syn);
|
fD2Syn.Assign(D2Syn);
|
||||||
|
|
|
@ -202,6 +202,7 @@ type
|
||||||
|
|
||||||
fCovModUt: boolean;
|
fCovModUt: boolean;
|
||||||
fDoc: TCESynMemo;
|
fDoc: TCESynMemo;
|
||||||
|
fFirstTimeCoedit: boolean;
|
||||||
fActionHandler: TCEActionProviderSubject;
|
fActionHandler: TCEActionProviderSubject;
|
||||||
fMultidoc: ICEMultiDocHandler;
|
fMultidoc: ICEMultiDocHandler;
|
||||||
fScCollectCount: Integer;
|
fScCollectCount: Integer;
|
||||||
|
@ -996,7 +997,8 @@ begin
|
||||||
begin
|
begin
|
||||||
fAppliOpts.loadFromFile(fname);
|
fAppliOpts.loadFromFile(fname);
|
||||||
fAppliOpts.assignTo(self);
|
fAppliOpts.assignTo(self);
|
||||||
end;
|
end
|
||||||
|
else fFirstTimeCoedit := true;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCEMainForm.SaveSettings;
|
procedure TCEMainForm.SaveSettings;
|
||||||
|
@ -1175,6 +1177,9 @@ begin
|
||||||
// TODO-cgonnawork: when Laz 1.6 is rlzd, remove etc/anchordocking and use Laz package
|
// TODO-cgonnawork: when Laz 1.6 is rlzd, remove etc/anchordocking and use Laz package
|
||||||
DockMaster.ResetSplitters;
|
DockMaster.ResetSplitters;
|
||||||
|
|
||||||
|
if fFirstTimeCoedit then
|
||||||
|
actFileNewRun.Execute;
|
||||||
|
|
||||||
fFirstShown := true;
|
fFirstShown := true;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
@ -1609,6 +1614,14 @@ begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCEMainForm.actFileNewRunExecute(Sender: TObject);
|
procedure TCEMainForm.actFileNewRunExecute(Sender: TObject);
|
||||||
|
const
|
||||||
|
body: array[boolean] of string =
|
||||||
|
(
|
||||||
|
LineEnding,
|
||||||
|
' // this file can be directly executed using menu file/compile & run' + LineEnding +
|
||||||
|
' // phobos and libman imports are allowed' + LineEnding +
|
||||||
|
' writeln("hello runnable module");' + LineEnding
|
||||||
|
);
|
||||||
begin
|
begin
|
||||||
newFile;
|
newFile;
|
||||||
fDoc.Text :=
|
fDoc.Text :=
|
||||||
|
@ -1618,9 +1631,7 @@ begin
|
||||||
LineEnding +
|
LineEnding +
|
||||||
'void main(string[] args)' + LineEnding +
|
'void main(string[] args)' + LineEnding +
|
||||||
'{' + LineEnding +
|
'{' + LineEnding +
|
||||||
' // this file can be directly executed using menu file/compile & run' + LineEnding +
|
body[fFirstTimeCoedit] +
|
||||||
' // phobos and libman imports are allowed' + LineEnding +
|
|
||||||
' writeln("hello runnable module");' + LineEnding +
|
|
||||||
'}';
|
'}';
|
||||||
fDoc.setFocus;
|
fDoc.setFocus;
|
||||||
end;
|
end;
|
||||||
|
|
|
@ -258,9 +258,10 @@ begin
|
||||||
fRefreshOnFocus := true;
|
fRefreshOnFocus := true;
|
||||||
fShowChildCategories := true;
|
fShowChildCategories := true;
|
||||||
fAutoExpandErrors := true;
|
fAutoExpandErrors := true;
|
||||||
|
fAutoRefresh := true;
|
||||||
fSmartFilter := true;
|
fSmartFilter := true;
|
||||||
fSortSymbols := false;
|
fSortSymbols := false;
|
||||||
fAutoRefreshDelay := 1500;
|
fAutoRefreshDelay := 750;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCESymbolListOptions.Assign(Source: TPersistent);
|
procedure TCESymbolListOptions.Assign(Source: TPersistent);
|
||||||
|
|
Loading…
Reference in New Issue