File tree Expand file tree Collapse file tree 3 files changed +14
-1
lines changed Expand file tree Collapse file tree 3 files changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -671,7 +671,7 @@ function TCompileForm.InitializeMemoBase(const Memo: TCompScintEdit; const Popup
671
671
Memo.Align := alClient;
672
672
Memo.AutoCompleteFontName := Font.Name ;
673
673
Memo.AutoCompleteFontSize := Font.Size;
674
- Memo.Font.Name := ' Courier New ' ;
674
+ Memo.Font.Name := GetPreferredMemoFont ;
675
675
Memo.Font.Size := 10 ;
676
676
Memo.ShowHint := True;
677
677
Memo.Styler := FMemosStyler;
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ function ReadScriptLines(const ALines: TStringList; const ReadFromFile: Boolean;
71
71
function CreateBitmapInfo (const Width, Height, BitCount: Integer): TBitmapInfo;
72
72
function GetWordOccurrenceFindOptions : TScintFindOptions;
73
73
function GetSelTextOccurrenceFindOptions : TScintFindOptions;
74
+ function GetPreferredMemoFont : String;
74
75
75
76
implementation
76
77
@@ -725,10 +726,21 @@ function GetSelTextOccurrenceFindOptions: TScintFindOptions;
725
726
Result := [];
726
727
end ;
727
728
729
+ var
730
+ PreferredMemoFont: String;
731
+
732
+ function GetPreferredMemoFont : String;
733
+ begin
734
+ Result := PreferredMemoFont;
735
+ end ;
736
+
728
737
initialization
729
738
var OSVersionInfo: TOSVersionInfo;
730
739
OSVersionInfo.dwOSVersionInfoSize := SizeOf(OSVersionInfo);
731
740
GetVersionEx(OSVersionInfo);
732
741
WindowsVersion := (Byte(OSVersionInfo.dwMajorVersion) shl 24 ) or (Byte(OSVersionInfo.dwMinorVersion) shl 16 ) or Word(OSVersionInfo.dwBuildNumber);
742
+ PreferredMemoFont := ' Consolas' ;
743
+ if not FontExists(PreferredMemoFont) then
744
+ PreferredMemoFont := ' Courier New' ;
733
745
734
746
end .
Original file line number Diff line number Diff line change 45
45
</ ul >
46
46
< p > Other changes:</ p >
47
47
< ul >
48
+ < li > The editor's font now defaults to Consolas if available, consistent with most other editors.</ li >
48
49
< li > Added shortcuts to move selected lines up or down (Alt+Up and Alt+Down).</ li >
49
50
< li > Added a right-click popup menu to the editor's gutter column for breakpoints.</ li >
50
51
< li > Minor tweaks and documentation improvements.</ li >
You can’t perform that action at this time.
0 commit comments