mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-06 00:58:04 +02:00
minimap: clean up and use default synedit font name
This commit is contained in:
parent
dd066409f4
commit
d7bacb390f
@ -14,7 +14,8 @@ unit CtrlMiniMap;
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, Graphics, IDEOptEditorIntf, SrcEditorIntf, LazConfigStorage, pnlMiniMap;
|
||||
Classes, SysUtils, Graphics, IDEOptEditorIntf, SrcEditorIntf, LazConfigStorage, LazLogger,
|
||||
pnlMiniMap;
|
||||
|
||||
const
|
||||
DefaultEnabled = True;
|
||||
@ -214,7 +215,7 @@ begin
|
||||
aPanel.Width:=MapWidth;
|
||||
aPanel.ViewWindowColor:=ViewWindowColor;
|
||||
aPanel.ViewWindowTextColor:=ViewWindowTextColor;
|
||||
If aFull then
|
||||
if aFull then
|
||||
aPanel.ViewFontSize:=InitialViewFontSize;
|
||||
end;
|
||||
|
||||
@ -230,7 +231,6 @@ begin
|
||||
Enabled:=True;
|
||||
end;
|
||||
|
||||
|
||||
destructor TMinimapController.Destroy;
|
||||
begin
|
||||
if FNeedSave then
|
||||
|
@ -15,7 +15,7 @@ interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, Forms, Controls, StdCtrls, ColorBox, Dialogs, SpinEx,
|
||||
IDEOptionsIntf, IDEOptEditorIntf, IDEUtils, IDEDialogs;
|
||||
IDEOptionsIntf, IDEOptEditorIntf;
|
||||
|
||||
type
|
||||
|
||||
|
@ -15,7 +15,7 @@ interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, Controls, ExtCtrls, SynEdit, SrcEditorIntf, Graphics, lclType,
|
||||
SynEditMarkupSpecialLine, SynEditTypes, SynEditMiscClasses, SynEditMarkupBracket;
|
||||
SynEditMarkupSpecialLine, SynEditTypes, SynEditMiscClasses, SynEditMarkupBracket, LazLogger;
|
||||
|
||||
Const
|
||||
DefaultViewFontSize = 3;
|
||||
@ -45,15 +45,15 @@ Type
|
||||
Protected
|
||||
// Event handlers
|
||||
procedure HandleLineMarkup(Sender: TObject; Line: integer; var Special: boolean; Markup: TSynSelectedColor); virtual;
|
||||
procedure HandleStatusChange(Sender: TObject; Changes: TSynStatusChanges); virtual;
|
||||
Procedure HandleClick(aSender : TObject); virtual;
|
||||
procedure HandleStatusChange(Sender: TObject; {%H-}Changes: TSynStatusChanges); virtual;
|
||||
Procedure HandleClick({%H-}aSender : TObject); virtual;
|
||||
procedure HandleEditorDestroy(Sender: TObject); virtual;
|
||||
Procedure SyncViewWindow;
|
||||
Property MiniSynEdit : TSynEdit Read FMiniSynEdit;
|
||||
Property SourceSynEdit : TCustomSynEdit Read FSourceSynEdit;
|
||||
Public
|
||||
constructor create(aOwner : TComponent); override;
|
||||
destructor destroy; override;
|
||||
constructor Create(aOwner : TComponent); override;
|
||||
destructor Destroy; override;
|
||||
Procedure Reconfigure;
|
||||
Property SourceEditor: TSourceEditorInterface Read FSourceEditor Write SetSourceEditor;
|
||||
Property ViewWindowColor : TColor Read FViewWindowColor Write SetViewWindowColor;
|
||||
@ -186,7 +186,7 @@ begin
|
||||
ParentColor:=False;
|
||||
ParentFont:=False;
|
||||
|
||||
Font.Name := 'Courier New';
|
||||
Font.Name := SynDefaultFontName;
|
||||
Font.Pitch := fpFixed;
|
||||
Font.Quality := fqNonAntialiased;
|
||||
Gutter.Visible := False;
|
||||
@ -247,7 +247,7 @@ begin
|
||||
Unhook;
|
||||
end;
|
||||
|
||||
constructor TMiniMapControl.create(aOwner: TComponent);
|
||||
constructor TMiniMapControl.Create(aOwner: TComponent);
|
||||
begin
|
||||
Inherited;
|
||||
BevelInner:=bvNone;
|
||||
@ -274,7 +274,7 @@ begin
|
||||
FSourceEditor:=nil;
|
||||
end;
|
||||
|
||||
destructor TMiniMapControl.destroy;
|
||||
destructor TMiniMapControl.Destroy;
|
||||
begin
|
||||
Unhook;
|
||||
inherited destroy;
|
||||
|
@ -7,7 +7,7 @@ interface
|
||||
uses
|
||||
CtrlMiniMap, Forms;
|
||||
|
||||
procedure register;
|
||||
procedure Register;
|
||||
|
||||
implementation
|
||||
|
||||
@ -16,7 +16,7 @@ uses fraMiniMapConfig, IDEOptionsIntf, IDEOptEditorIntf;
|
||||
var
|
||||
MiniMapOptionsFrameID : integer = 2100;
|
||||
|
||||
procedure register;
|
||||
procedure Register;
|
||||
|
||||
begin
|
||||
MiniMapController:=TMinimapController.Create(Application);
|
||||
|
Loading…
Reference in New Issue
Block a user