mirror of
				https://gitlab.com/freepascal.org/lazarus/lazarus.git
				synced 2025-11-04 10:19:52 +01:00 
			
		
		
		
	IDE, SynEdit: Add options for the editor gutter layout. Issue #40170
This commit is contained in:
		
							parent
							
								
									69a432d864
								
							
						
					
					
						commit
						b1847337ca
					
				@ -453,7 +453,7 @@ type
 | 
				
			|||||||
  private
 | 
					  private
 | 
				
			||||||
    FOwner: TSynObjectList;
 | 
					    FOwner: TSynObjectList;
 | 
				
			||||||
    function GetIndex: Integer;
 | 
					    function GetIndex: Integer;
 | 
				
			||||||
    procedure SetIndex(const AValue: Integer);
 | 
					    procedure SetIndex(AValue: Integer);
 | 
				
			||||||
  protected
 | 
					  protected
 | 
				
			||||||
    function Compare(Other: TSynObjectListItem): Integer; virtual;
 | 
					    function Compare(Other: TSynObjectListItem): Integer; virtual;
 | 
				
			||||||
    function GetDisplayName: String; virtual;
 | 
					    function GetDisplayName: String; virtual;
 | 
				
			||||||
@ -1898,8 +1898,10 @@ begin
 | 
				
			|||||||
  //
 | 
					  //
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
procedure TSynObjectListItem.SetIndex(const AValue: Integer);
 | 
					procedure TSynObjectListItem.SetIndex(AValue: Integer);
 | 
				
			||||||
begin
 | 
					begin
 | 
				
			||||||
 | 
					  if AValue < 0 then AValue := 0;
 | 
				
			||||||
 | 
					  if AValue >= Owner.Count then AValue := Owner.Count - 1;
 | 
				
			||||||
  Owner.Move(GetIndex, AValue);
 | 
					  Owner.Move(GetIndex, AValue);
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -443,11 +443,11 @@ begin
 | 
				
			|||||||
  Canvas.FillRect(AClip);
 | 
					  Canvas.FillRect(AClip);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  if FLineOnRight then begin
 | 
					  if FLineOnRight then begin
 | 
				
			||||||
    AClip.Right := Min(AClip.Right, Left + Width - FLineOffset);
 | 
					    AClip.Right := Min(AClip.Right, Left + LeftOffset + Width - FLineOffset);
 | 
				
			||||||
    AClip.Left  := Max(AClip.Left,  Left + Width - FLineOffset  - FLineWidth);
 | 
					    AClip.Left  := Max(AClip.Left,  Left + LeftOffset + Width - FLineOffset  - FLineWidth);
 | 
				
			||||||
  end else begin
 | 
					  end else begin
 | 
				
			||||||
    AClip.Left  := Max(AClip.Left,  Left + FLineOffset);
 | 
					    AClip.Left  := Max(AClip.Left,  Left + LeftOffset + FLineOffset);
 | 
				
			||||||
    AClip.Right := Min(AClip.Right, Left + FLineOffset  + FLineWidth);
 | 
					    AClip.Right := Min(AClip.Right, Left + LeftOffset + FLineOffset  + FLineWidth);
 | 
				
			||||||
  end;
 | 
					  end;
 | 
				
			||||||
  if AClip.Right > AClip.Left then begin
 | 
					  if AClip.Right > AClip.Left then begin
 | 
				
			||||||
    Canvas.Brush.Color := MarkupInfo.Foreground;
 | 
					    Canvas.Brush.Color := MarkupInfo.Foreground;
 | 
				
			||||||
 | 
				
			|||||||
@ -1405,7 +1405,7 @@ var
 | 
				
			|||||||
begin
 | 
					begin
 | 
				
			||||||
  inherited DoResize(Sender);
 | 
					  inherited DoResize(Sender);
 | 
				
			||||||
  if (not SynEdit.HandleAllocated) or (not Self.Visible) then exit;
 | 
					  if (not SynEdit.HandleAllocated) or (not Self.Visible) then exit;
 | 
				
			||||||
  FWinControl.BoundsRect := Bounds(Left,Top,Width,Height);
 | 
					  FWinControl.BoundsRect := Bounds(Left+LeftOffset,Top,Width,Height);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  {$IFDEF DARWIN}
 | 
					  {$IFDEF DARWIN}
 | 
				
			||||||
  FLineMarks.PixelHeight := Height;
 | 
					  FLineMarks.PixelHeight := Height;
 | 
				
			||||||
 | 
				
			|||||||
@ -16,6 +16,7 @@ type
 | 
				
			|||||||
  TSynGutterMarks = class(TSynGutterPartBase)
 | 
					  TSynGutterMarks = class(TSynGutterPartBase)
 | 
				
			||||||
  private
 | 
					  private
 | 
				
			||||||
    FColumnCount: Integer;
 | 
					    FColumnCount: Integer;
 | 
				
			||||||
 | 
					    FWantedColumns: integer;
 | 
				
			||||||
    FColumnWidth: Integer;
 | 
					    FColumnWidth: Integer;
 | 
				
			||||||
    FDebugMarksImageIndex: Integer;
 | 
					    FDebugMarksImageIndex: Integer;
 | 
				
			||||||
    FInternalImage: TSynInternalImage;
 | 
					    FInternalImage: TSynInternalImage;
 | 
				
			||||||
@ -32,14 +33,15 @@ type
 | 
				
			|||||||
                       var aFirstCustomColumnIdx: integer): Boolean;
 | 
					                       var aFirstCustomColumnIdx: integer): Boolean;
 | 
				
			||||||
    Procedure PaintLine(aScreenLine: Integer; Canvas : TCanvas; AClip : TRect); virtual;
 | 
					    Procedure PaintLine(aScreenLine: Integer; Canvas : TCanvas; AClip : TRect); virtual;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    property ColumnWidth: Integer read FColumnWidth; // initialized in Paint
 | 
					 | 
				
			||||||
    property ColumnCount: Integer read FColumnCount;
 | 
					 | 
				
			||||||
  public
 | 
					  public
 | 
				
			||||||
    constructor Create(AOwner: TComponent); override;
 | 
					    constructor Create(AOwner: TComponent); override;
 | 
				
			||||||
    destructor Destroy; override;
 | 
					    destructor Destroy; override;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    procedure Paint(Canvas: TCanvas; AClip: TRect; FirstLine, LastLine: integer); override;
 | 
					    procedure Paint(Canvas: TCanvas; AClip: TRect; FirstLine, LastLine: integer); override;
 | 
				
			||||||
 | 
					    procedure SetWidthForColumns(AValue: Integer);
 | 
				
			||||||
    property DebugMarksImageIndex: Integer read FDebugMarksImageIndex write FDebugMarksImageIndex;
 | 
					    property DebugMarksImageIndex: Integer read FDebugMarksImageIndex write FDebugMarksImageIndex;
 | 
				
			||||||
 | 
					    property ColumnWidth: Integer read FColumnWidth; // initialized in Paint
 | 
				
			||||||
 | 
					    property ColumnCount: Integer read FColumnCount;
 | 
				
			||||||
  end;
 | 
					  end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
implementation
 | 
					implementation
 | 
				
			||||||
@ -62,7 +64,13 @@ end;
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
function TSynGutterMarks.PreferedWidth: Integer;
 | 
					function TSynGutterMarks.PreferedWidth: Integer;
 | 
				
			||||||
begin
 | 
					begin
 | 
				
			||||||
  Result := 22 + FBookMarkOpt.LeftMargin
 | 
					  Result := 22 + FBookMarkOpt.LeftMargin;
 | 
				
			||||||
 | 
					  if FWantedColumns > 0 then begin
 | 
				
			||||||
 | 
					    if assigned(FBookMarkOpt) and assigned(FBookMarkOpt.BookmarkImages) then begin
 | 
				
			||||||
 | 
					      FColumnWidth := GetImgListRes(FriendEdit.Canvas, FBookMarkOpt.BookmarkImages).Width;
 | 
				
			||||||
 | 
					      Result := FWantedColumns*FColumnWidth;
 | 
				
			||||||
 | 
					    end;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function TSynGutterMarks.LeftMarginAtCurrentPPI: Integer;
 | 
					function TSynGutterMarks.LeftMarginAtCurrentPPI: Integer;
 | 
				
			||||||
@ -245,5 +253,16 @@ begin
 | 
				
			|||||||
  end;
 | 
					  end;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TSynGutterMarks.SetWidthForColumns(AValue: Integer);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if FWantedColumns = AValue then
 | 
				
			||||||
 | 
					    exit;
 | 
				
			||||||
 | 
					  FWantedColumns := AValue;
 | 
				
			||||||
 | 
					  if not AutoSize then
 | 
				
			||||||
 | 
					    AutoSize := True
 | 
				
			||||||
 | 
					  else
 | 
				
			||||||
 | 
					    DoAutoSize;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
end.
 | 
					end.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -63,7 +63,7 @@ uses
 | 
				
			|||||||
  SynHighlighterIni, SynHighlighterPo, SynHighlighterPike, SynPluginMultiCaret,
 | 
					  SynHighlighterIni, SynHighlighterPo, SynHighlighterPike, SynPluginMultiCaret,
 | 
				
			||||||
  SynEditMarkupFoldColoring, SynEditMarkup, SynGutterLineOverview,
 | 
					  SynEditMarkupFoldColoring, SynEditMarkup, SynGutterLineOverview,
 | 
				
			||||||
  SynBeautifierPascal, SynEditTextDynTabExpander, SynEditTextTabExpander,
 | 
					  SynBeautifierPascal, SynEditTextDynTabExpander, SynEditTextTabExpander,
 | 
				
			||||||
  SynTextMateSyn, SynEditStrConst, SynHighlighterPosition,
 | 
					  SynTextMateSyn, SynEditStrConst, SynHighlighterPosition, SynGutterMarks,
 | 
				
			||||||
  // codetools
 | 
					  // codetools
 | 
				
			||||||
  LinkScanner, CodeToolManager,
 | 
					  LinkScanner, CodeToolManager,
 | 
				
			||||||
  // BuildIntf
 | 
					  // BuildIntf
 | 
				
			||||||
@ -1467,6 +1467,48 @@ type
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  TEditorOptsScrollPastEolMode = (optScrollFixed, optScrollPage, optScrollNone);
 | 
					  TEditorOptsScrollPastEolMode = (optScrollFixed, optScrollPage, optScrollNone);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  { TEditorSynGutterOptions }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  TEditorSynGutterOptions = class(TPersistent)
 | 
				
			||||||
 | 
					  private
 | 
				
			||||||
 | 
					    FDefaults: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGClass: TSynGutterPartBaseClass;
 | 
				
			||||||
 | 
					    FIndex: integer;
 | 
				
			||||||
 | 
					    FOffsetLeft: integer;
 | 
				
			||||||
 | 
					    FOffsetRight: integer;
 | 
				
			||||||
 | 
					    FVisible: boolean;
 | 
				
			||||||
 | 
					    FWidth: integer;
 | 
				
			||||||
 | 
					  protected
 | 
				
			||||||
 | 
					    constructor DoCreate(AIdx: Integer; AGClass: TSynGutterPartBaseClass);
 | 
				
			||||||
 | 
					  public
 | 
				
			||||||
 | 
					    constructor Create(AIdx: Integer; AGClass: TSynGutterPartBaseClass);
 | 
				
			||||||
 | 
					    destructor Destroy; override;
 | 
				
			||||||
 | 
					    procedure Assign(Source: TPersistent); override;
 | 
				
			||||||
 | 
					    procedure ApplyTo(AGutterPart: TSynGutterPartBase);
 | 
				
			||||||
 | 
					    procedure ApplyIndexTo(AGutterPart: TSynGutterPartBase);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    property Defaults: TEditorSynGutterOptions read FDefaults;
 | 
				
			||||||
 | 
					    property GClass: TSynGutterPartBaseClass read FGClass;
 | 
				
			||||||
 | 
					  published
 | 
				
			||||||
 | 
					    property Visible: boolean read FVisible write FVisible;
 | 
				
			||||||
 | 
					    property Index: integer read FIndex write FIndex;
 | 
				
			||||||
 | 
					    property Width: integer read FWidth write FWidth;
 | 
				
			||||||
 | 
					    property OffsetLeft: integer read FOffsetLeft write FOffsetLeft;
 | 
				
			||||||
 | 
					    property OffsetRight: integer read FOffsetRight write FOffsetRight;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  { TEditorSynGutterOptionsList }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  TEditorSynGutterOptionsList = class(specialize TFPGObjectList<TEditorSynGutterOptions>)
 | 
				
			||||||
 | 
					  private
 | 
				
			||||||
 | 
					    function GetByClass(AIndex: TSynGutterPartBaseClass): TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					  public
 | 
				
			||||||
 | 
					    procedure Assign(Source: TEditorSynGutterOptionsList);
 | 
				
			||||||
 | 
					    procedure AssignItems(Source: TEditorSynGutterOptionsList);
 | 
				
			||||||
 | 
					    procedure Sort;
 | 
				
			||||||
 | 
					    property ByClass[AIndex: TSynGutterPartBaseClass]: TEditorSynGutterOptions read GetByClass;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  { TEditorOptionsBase }
 | 
					  { TEditorOptionsBase }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  TEditorOptionsBase = class(TIDEEditorOptions)
 | 
					  TEditorOptionsBase = class(TIDEEditorOptions)
 | 
				
			||||||
@ -1485,7 +1527,14 @@ type
 | 
				
			|||||||
    fMultiLineTab: Boolean;
 | 
					    fMultiLineTab: Boolean;
 | 
				
			||||||
    fTabPosition: TTabPosition;
 | 
					    fTabPosition: TTabPosition;
 | 
				
			||||||
    // Display options
 | 
					    // Display options
 | 
				
			||||||
    fShowOverviewGutter: boolean;
 | 
					    FGutterPartMarks: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGutterPartChange: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGutterPartFold: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGutterPartLine: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGutterPartOver: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGutterPartSep: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FGutterPartList: TEditorSynGutterOptionsList;
 | 
				
			||||||
 | 
					    FGutterRightPartList: TEditorSynGutterOptionsList;
 | 
				
			||||||
    fTopInfoView: boolean;
 | 
					    fTopInfoView: boolean;
 | 
				
			||||||
    // Code tools options
 | 
					    // Code tools options
 | 
				
			||||||
    fDbgHintAutoTypeCastClass: Boolean;
 | 
					    fDbgHintAutoTypeCastClass: Boolean;
 | 
				
			||||||
@ -1540,6 +1589,16 @@ type
 | 
				
			|||||||
  public
 | 
					  public
 | 
				
			||||||
    constructor Create;
 | 
					    constructor Create;
 | 
				
			||||||
    destructor Destroy; override;
 | 
					    destructor Destroy; override;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    // Display
 | 
				
			||||||
 | 
					    property GutterPartMarks: TEditorSynGutterOptions read FGutterPartMarks;
 | 
				
			||||||
 | 
					    property GutterPartLine: TEditorSynGutterOptions read FGutterPartLine;
 | 
				
			||||||
 | 
					    property GutterPartChange: TEditorSynGutterOptions read FGutterPartChange;
 | 
				
			||||||
 | 
					    property GutterPartSep: TEditorSynGutterOptions read FGutterPartSep;
 | 
				
			||||||
 | 
					    property GutterPartFold: TEditorSynGutterOptions read FGutterPartFold;
 | 
				
			||||||
 | 
					    property GutterPartOver: TEditorSynGutterOptions read FGutterPartOver;
 | 
				
			||||||
 | 
					    property GutterPartList: TEditorSynGutterOptionsList read FGutterPartList;
 | 
				
			||||||
 | 
					    property GutterRightPartList: TEditorSynGutterOptionsList read FGutterRightPartList;
 | 
				
			||||||
  published { use RTTIConf}
 | 
					  published { use RTTIConf}
 | 
				
			||||||
    // general options
 | 
					    // general options
 | 
				
			||||||
    property MultiLineTab: Boolean read fMultiLineTab write fMultiLineTab default False;
 | 
					    property MultiLineTab: Boolean read fMultiLineTab write fMultiLineTab default False;
 | 
				
			||||||
@ -1559,8 +1618,7 @@ type
 | 
				
			|||||||
    property ExportHtmlWithBackground: Boolean
 | 
					    property ExportHtmlWithBackground: Boolean
 | 
				
			||||||
      read fExportHtmlWithBackground write fExportHtmlWithBackground default False;
 | 
					      read fExportHtmlWithBackground write fExportHtmlWithBackground default False;
 | 
				
			||||||
    // Display
 | 
					    // Display
 | 
				
			||||||
    property ShowOverviewGutter: boolean
 | 
					
 | 
				
			||||||
      read fShowOverviewGutter write fShowOverviewGutter default True;
 | 
					 | 
				
			||||||
    property TopInfoView: boolean read fTopInfoView write fTopInfoView default True;
 | 
					    property TopInfoView: boolean read fTopInfoView write fTopInfoView default True;
 | 
				
			||||||
    // Code Folding
 | 
					    // Code Folding
 | 
				
			||||||
    property ReverseFoldPopUpOrder: Boolean
 | 
					    property ReverseFoldPopUpOrder: Boolean
 | 
				
			||||||
@ -1677,10 +1735,8 @@ type
 | 
				
			|||||||
    // Display options
 | 
					    // Display options
 | 
				
			||||||
    fVisibleRightMargin: Boolean;
 | 
					    fVisibleRightMargin: Boolean;
 | 
				
			||||||
    fVisibleGutter: Boolean;
 | 
					    fVisibleGutter: Boolean;
 | 
				
			||||||
    fShowLineNumbers: Boolean;
 | 
					 | 
				
			||||||
    fShowOnlyLineNumbersMultiplesOf: integer;
 | 
					    fShowOnlyLineNumbersMultiplesOf: integer;
 | 
				
			||||||
    fGutterWidth: Integer;
 | 
					    fGutterWidth: Integer;
 | 
				
			||||||
    fGutterSeparatorIndex: Integer;
 | 
					 | 
				
			||||||
    fRightMargin: Integer;
 | 
					    fRightMargin: Integer;
 | 
				
			||||||
    fEditorFont:  String;
 | 
					    fEditorFont:  String;
 | 
				
			||||||
    fEditorFontSize:   Integer;
 | 
					    fEditorFontSize:   Integer;
 | 
				
			||||||
@ -1801,13 +1857,9 @@ type
 | 
				
			|||||||
    property VisibleRightMargin: Boolean
 | 
					    property VisibleRightMargin: Boolean
 | 
				
			||||||
      read fVisibleRightMargin write fVisibleRightMargin default True;
 | 
					      read fVisibleRightMargin write fVisibleRightMargin default True;
 | 
				
			||||||
    property VisibleGutter: Boolean read fVisibleGutter write fVisibleGutter default True;
 | 
					    property VisibleGutter: Boolean read fVisibleGutter write fVisibleGutter default True;
 | 
				
			||||||
    property ShowLineNumbers: Boolean read fShowLineNumbers
 | 
					 | 
				
			||||||
      write fShowLineNumbers default False;
 | 
					 | 
				
			||||||
    property ShowOnlyLineNumbersMultiplesOf: integer read fShowOnlyLineNumbersMultiplesOf
 | 
					    property ShowOnlyLineNumbersMultiplesOf: integer read fShowOnlyLineNumbersMultiplesOf
 | 
				
			||||||
      write fShowOnlyLineNumbersMultiplesOf;
 | 
					      write fShowOnlyLineNumbersMultiplesOf;
 | 
				
			||||||
    property GutterWidth: Integer read fGutterWidth write fGutterWidth default 30;
 | 
					    property GutterWidth: Integer read fGutterWidth write fGutterWidth default 30;
 | 
				
			||||||
    property GutterSeparatorIndex: Integer read FGutterSeparatorIndex
 | 
					 | 
				
			||||||
      write FGutterSeparatorIndex default 3;
 | 
					 | 
				
			||||||
    property RightMargin: Integer read fRightMargin write fRightMargin default 80;
 | 
					    property RightMargin: Integer read fRightMargin write fRightMargin default 80;
 | 
				
			||||||
    property EditorFont: String read fEditorFont write fEditorFont;
 | 
					    property EditorFont: String read fEditorFont write fEditorFont;
 | 
				
			||||||
    property EditorFontSize: Integer read fEditorFontSize write fEditorFontSize;
 | 
					    property EditorFontSize: Integer read fEditorFontSize write fEditorFontSize;
 | 
				
			||||||
@ -2156,6 +2208,144 @@ begin
 | 
				
			|||||||
  Result := FList.Count;
 | 
					  Result := FList.Count;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{ TEditorSynGutterOptions }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					constructor TEditorSynGutterOptions.DoCreate(AIdx: Integer;
 | 
				
			||||||
 | 
					  AGClass: TSynGutterPartBaseClass);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  inherited Create;
 | 
				
			||||||
 | 
					  FGClass := AGClass;
 | 
				
			||||||
 | 
					  FIndex   := AIdx;
 | 
				
			||||||
 | 
					  FVisible := True;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  if FGClass = TSynGutterMarks then begin
 | 
				
			||||||
 | 
					    FWidth := 2;
 | 
				
			||||||
 | 
					  end
 | 
				
			||||||
 | 
					  else
 | 
				
			||||||
 | 
					  if FGClass = TSynGutterLineNumber then begin
 | 
				
			||||||
 | 
					    FWidth := 2;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					constructor TEditorSynGutterOptions.Create(AIdx: Integer;
 | 
				
			||||||
 | 
					  AGClass: TSynGutterPartBaseClass);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  DoCreate(AIdx, AGClass);
 | 
				
			||||||
 | 
					  FDefaults := TEditorSynGutterOptions.DoCreate(AIdx, AGClass);
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					destructor TEditorSynGutterOptions.Destroy;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  FreeAndNil(FDefaults);
 | 
				
			||||||
 | 
					  inherited Destroy;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorSynGutterOptions.Assign(Source: TPersistent);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if Source is TEditorSynGutterOptions then begin
 | 
				
			||||||
 | 
					    FGClass      := TEditorSynGutterOptions(Source).FGClass;
 | 
				
			||||||
 | 
					    FIndex       := TEditorSynGutterOptions(Source).FIndex;
 | 
				
			||||||
 | 
					    FOffsetLeft  := TEditorSynGutterOptions(Source).FOffsetLeft;
 | 
				
			||||||
 | 
					    FOffsetRight := TEditorSynGutterOptions(Source).FOffsetRight;
 | 
				
			||||||
 | 
					    FVisible     := TEditorSynGutterOptions(Source).FVisible;
 | 
				
			||||||
 | 
					    FWidth       := TEditorSynGutterOptions(Source).FWidth;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorSynGutterOptions.ApplyTo(AGutterPart: TSynGutterPartBase);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if AGutterPart = nil then exit;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  if FGClass = TSynGutterMarks then begin
 | 
				
			||||||
 | 
					    TSynGutterMarks(AGutterPart).SetWidthForColumns(FWidth);
 | 
				
			||||||
 | 
					  end
 | 
				
			||||||
 | 
					  else
 | 
				
			||||||
 | 
					  if FGClass = TSynGutterLineNumber then begin
 | 
				
			||||||
 | 
					    AGutterPart.AutoSize := True;
 | 
				
			||||||
 | 
					    TSynGutterLineNumber(AGutterPart).DigitCount := FWidth;
 | 
				
			||||||
 | 
					  end
 | 
				
			||||||
 | 
					  else
 | 
				
			||||||
 | 
					  if FGClass = TSynGutterSeparator then begin
 | 
				
			||||||
 | 
					    AGutterPart.AutoSize := FWidth = 0;
 | 
				
			||||||
 | 
					    if FWidth = 0 then begin
 | 
				
			||||||
 | 
					      TSynGutterSeparator(AGutterPart).Width := 2;
 | 
				
			||||||
 | 
					      TSynGutterSeparator(AGutterPart).LineWidth := 1;
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    else begin
 | 
				
			||||||
 | 
					      TSynGutterSeparator(AGutterPart).Width := FWidth;
 | 
				
			||||||
 | 
					      TSynGutterSeparator(AGutterPart).LineWidth := FWidth;
 | 
				
			||||||
 | 
					    end;
 | 
				
			||||||
 | 
					  end
 | 
				
			||||||
 | 
					  else
 | 
				
			||||||
 | 
					  begin
 | 
				
			||||||
 | 
					    AGutterPart.AutoSize := FWidth = 0;
 | 
				
			||||||
 | 
					    AGutterPart.Width := FWidth;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					  AGutterPart.Visible := FVisible;
 | 
				
			||||||
 | 
					  AGutterPart.LeftOffset := FOffsetLeft;
 | 
				
			||||||
 | 
					  AGutterPart.RightOffset := FOffsetRight;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorSynGutterOptions.ApplyIndexTo(AGutterPart: TSynGutterPartBase);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if AGutterPart <> nil then
 | 
				
			||||||
 | 
					    AGutterPart.Index := Index;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{ TEditorSynGutterOptionsList }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function SynGutterOptListSortCompare(const Item1, Item2: TEditorSynGutterOptions): Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  Result := Item1.Index - Item2.Index;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function TEditorSynGutterOptionsList.GetByClass(AIndex: TSynGutterPartBaseClass
 | 
				
			||||||
 | 
					  ): TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  i: Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  for i := 0 to Count - 1 do
 | 
				
			||||||
 | 
					    if Items[i].GClass = AIndex then
 | 
				
			||||||
 | 
					      exit(Items[i]);
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorSynGutterOptionsList.Assign(Source: TEditorSynGutterOptionsList);
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  i: Integer;
 | 
				
			||||||
 | 
					  n: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  Clear;
 | 
				
			||||||
 | 
					  for i := 0 to Source.Count - 1 do begin
 | 
				
			||||||
 | 
					    n := TEditorSynGutterOptions.Create(Source[i].Index, Source[i].GClass);
 | 
				
			||||||
 | 
					    n.Assign(Source[i]);
 | 
				
			||||||
 | 
					    Add(n);
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorSynGutterOptionsList.AssignItems(Source: TEditorSynGutterOptionsList);
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  i: Integer;
 | 
				
			||||||
 | 
					  itm, dest: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  for i := 0 to Source.Count - 1 do begin
 | 
				
			||||||
 | 
					    itm := Source.Items[i];
 | 
				
			||||||
 | 
					    dest := ByClass[itm.GClass];
 | 
				
			||||||
 | 
					    if dest <> nil then
 | 
				
			||||||
 | 
					      dest.Assign(itm);
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					  Sort;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorSynGutterOptionsList.Sort;
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  i: Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  inherited Sort(@SynGutterOptListSortCompare);
 | 
				
			||||||
 | 
					  // fix gaps
 | 
				
			||||||
 | 
					  for i := 0 to Count - 1 do
 | 
				
			||||||
 | 
					    Items[i].Index := i;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
{ TEditorUserDefinedWords }
 | 
					{ TEditorUserDefinedWords }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
procedure TEditorUserDefinedWords.SetName(AValue: String);
 | 
					procedure TEditorUserDefinedWords.SetName(AValue: String);
 | 
				
			||||||
@ -5127,10 +5317,29 @@ begin
 | 
				
			|||||||
  inherited Create;
 | 
					  inherited Create;
 | 
				
			||||||
  FScrollOnEditLeftOptions := TSynScrollOnEditLeftOptions.Create;
 | 
					  FScrollOnEditLeftOptions := TSynScrollOnEditLeftOptions.Create;
 | 
				
			||||||
  FScrollOnEditRightOptions := TSynScrollOnEditRightOptions.Create;
 | 
					  FScrollOnEditRightOptions := TSynScrollOnEditRightOptions.Create;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  FGutterPartMarks := TEditorSynGutterOptions.Create(0, TSynGutterMarks);
 | 
				
			||||||
 | 
					  FGutterPartLine  := TEditorSynGutterOptions.Create(1, TSynGutterLineNumber);
 | 
				
			||||||
 | 
					  FGutterPartChange:= TEditorSynGutterOptions.Create(2, TSynGutterChanges);
 | 
				
			||||||
 | 
					  FGutterPartSep   := TEditorSynGutterOptions.Create(3, TSynGutterSeparator);
 | 
				
			||||||
 | 
					  FGutterPartFold  := TEditorSynGutterOptions.Create(4, TSynGutterCodeFolding);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  FGutterPartOver  := TEditorSynGutterOptions.Create(0, TSynGutterLineOverview);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  FGutterPartList := TEditorSynGutterOptionsList.Create(True);
 | 
				
			||||||
 | 
					  FGutterRightPartList := TEditorSynGutterOptionsList.Create(True);
 | 
				
			||||||
 | 
					  FGutterPartList.Add(FGutterPartMarks);
 | 
				
			||||||
 | 
					  FGutterPartList.Add(FGutterPartLine);
 | 
				
			||||||
 | 
					  FGutterPartList.Add(FGutterPartChange);
 | 
				
			||||||
 | 
					  FGutterPartList.Add(FGutterPartSep);
 | 
				
			||||||
 | 
					  FGutterPartList.Add(FGutterPartFold);
 | 
				
			||||||
 | 
					  FGutterRightPartList.Add(FGutterPartOver);
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
destructor TEditorOptionsBase.Destroy;
 | 
					destructor TEditorOptionsBase.Destroy;
 | 
				
			||||||
begin
 | 
					begin
 | 
				
			||||||
 | 
					  FreeAndNil(FGutterPartList);
 | 
				
			||||||
 | 
					  FreeAndNil(FGutterRightPartList);
 | 
				
			||||||
  FreeAndNil(FScrollOnEditLeftOptions);
 | 
					  FreeAndNil(FScrollOnEditLeftOptions);
 | 
				
			||||||
  FreeAndNil(FScrollOnEditRightOptions);
 | 
					  FreeAndNil(FScrollOnEditRightOptions);
 | 
				
			||||||
  inherited Destroy;
 | 
					  inherited Destroy;
 | 
				
			||||||
@ -5147,7 +5356,6 @@ begin
 | 
				
			|||||||
  fMultiCaretDeleteSkipLineBreak := False;
 | 
					  fMultiCaretDeleteSkipLineBreak := False;
 | 
				
			||||||
  fExportHtmlWithBackground := False;
 | 
					  fExportHtmlWithBackground := False;
 | 
				
			||||||
  // Display options
 | 
					  // Display options
 | 
				
			||||||
  fShowOverviewGutter := True;
 | 
					 | 
				
			||||||
  fTopInfoView := True;
 | 
					  fTopInfoView := True;
 | 
				
			||||||
  // hints
 | 
					  // hints
 | 
				
			||||||
  fDbgHintAutoTypeCastClass := True;
 | 
					  fDbgHintAutoTypeCastClass := True;
 | 
				
			||||||
@ -5307,7 +5515,6 @@ begin
 | 
				
			|||||||
  fElasticTabsMinWidth := 1;
 | 
					  fElasticTabsMinWidth := 1;
 | 
				
			||||||
  fBracketHighlightStyle := sbhsBoth;
 | 
					  fBracketHighlightStyle := sbhsBoth;
 | 
				
			||||||
  // Display options
 | 
					  // Display options
 | 
				
			||||||
  fGutterSeparatorIndex := 3;
 | 
					 | 
				
			||||||
  fEditorFont := SynDefaultFontName;
 | 
					  fEditorFont := SynDefaultFontName;
 | 
				
			||||||
  fEditorFontSize := SynDefaultFontSize;
 | 
					  fEditorFontSize := SynDefaultFontSize;
 | 
				
			||||||
  fDisableAntialiasing := DefaultEditorDisableAntiAliasing;
 | 
					  fDisableAntialiasing := DefaultEditorDisableAntiAliasing;
 | 
				
			||||||
@ -5353,6 +5560,8 @@ var
 | 
				
			|||||||
  SynEditOpt2: TSynEditorOption2;
 | 
					  SynEditOpt2: TSynEditorOption2;
 | 
				
			||||||
  FileVersion: LongInt;
 | 
					  FileVersion: LongInt;
 | 
				
			||||||
  DefOpts: TSynEditorOptions;
 | 
					  DefOpts: TSynEditorOptions;
 | 
				
			||||||
 | 
					  OldGutterSeparatorIndex: Int64;
 | 
				
			||||||
 | 
					  OldShowLineNumbers: Boolean;
 | 
				
			||||||
begin
 | 
					begin
 | 
				
			||||||
  try
 | 
					  try
 | 
				
			||||||
    FileVersion:=XMLConfig.GetValue('EditorOptions/Version', EditorOptsFormatVersion);
 | 
					    FileVersion:=XMLConfig.GetValue('EditorOptions/Version', EditorOptsFormatVersion);
 | 
				
			||||||
@ -5438,25 +5647,53 @@ begin
 | 
				
			|||||||
      TSynEditBracketHighlightStyle(XMLConfig.GetValue('EditorOptions/General/Editor/BracketHighlightStyle', 2));
 | 
					      TSynEditBracketHighlightStyle(XMLConfig.GetValue('EditorOptions/General/Editor/BracketHighlightStyle', 2));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // Display options
 | 
					    // Display options
 | 
				
			||||||
 | 
					    XMLConfig.ReadObject('EditorOptions/GutterParts/Marks/',  FGutterPartMarks,  FGutterPartMarks.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.ReadObject('EditorOptions/GutterParts/Line/',   FGutterPartLine,   FGutterPartLine.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.ReadObject('EditorOptions/GutterParts/Change/', FGutterPartChange, FGutterPartChange.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.ReadObject('EditorOptions/GutterParts/Sep/',    FGutterPartSep,    FGutterPartSep.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.ReadObject('EditorOptions/GutterParts/Fold/',   FGutterPartFold,   FGutterPartFold.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.ReadObject('EditorOptions/GutterParts/Over/',   FGutterPartOver,   FGutterPartOver.Defaults);
 | 
				
			||||||
 | 
					    FGutterPartList.Sort;
 | 
				
			||||||
 | 
					    FGutterRightPartList.Sort;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    fVisibleRightMargin :=
 | 
					    fVisibleRightMargin :=
 | 
				
			||||||
      XMLConfig.GetValue('EditorOptions/Display/VisibleRightMargin', True);
 | 
					      XMLConfig.GetValue('EditorOptions/Display/VisibleRightMargin', True);
 | 
				
			||||||
    fVisibleGutter :=
 | 
					    fVisibleGutter :=
 | 
				
			||||||
      XMLConfig.GetValue('EditorOptions/Display/VisibleGutter', True);
 | 
					      XMLConfig.GetValue('EditorOptions/Display/VisibleGutter', True);
 | 
				
			||||||
    if FileVersion<4 then begin
 | 
					    if FileVersion<4 then begin
 | 
				
			||||||
      fShowLineNumbers :=
 | 
					      OldShowLineNumbers :=
 | 
				
			||||||
        XMLConfig.GetValue('EditorOptions/Display/ShowLineNumbers', False);
 | 
					        XMLConfig.GetValue('EditorOptions/Display/ShowLineNumbers', False);
 | 
				
			||||||
 | 
					      if OldShowLineNumbers then
 | 
				
			||||||
 | 
					        FGutterPartLine.Visible := True;
 | 
				
			||||||
      fShowOnlyLineNumbersMultiplesOf :=
 | 
					      fShowOnlyLineNumbersMultiplesOf :=
 | 
				
			||||||
        XMLConfig.GetValue('EditorOptions/Display/ShowOnlyLineNumbersMultiplesOf', 1);
 | 
					        XMLConfig.GetValue('EditorOptions/Display/ShowOnlyLineNumbersMultiplesOf', 1);
 | 
				
			||||||
    end else begin
 | 
					    end else begin
 | 
				
			||||||
      fShowLineNumbers :=
 | 
					      OldShowLineNumbers :=
 | 
				
			||||||
        XMLConfig.GetValue('EditorOptions/Display/ShowLineNumbers', True);
 | 
					        XMLConfig.GetValue('EditorOptions/Display/ShowLineNumbers', True);
 | 
				
			||||||
 | 
					      if not OldShowLineNumbers then
 | 
				
			||||||
 | 
					        FGutterPartLine.Visible := False;
 | 
				
			||||||
      fShowOnlyLineNumbersMultiplesOf :=
 | 
					      fShowOnlyLineNumbersMultiplesOf :=
 | 
				
			||||||
        XMLConfig.GetValue('EditorOptions/Display/ShowOnlyLineNumbersMultiplesOf', 5);
 | 
					        XMLConfig.GetValue('EditorOptions/Display/ShowOnlyLineNumbersMultiplesOf', 5);
 | 
				
			||||||
    end;
 | 
					    end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    OldGutterSeparatorIndex :=
 | 
				
			||||||
 | 
					      XMLConfig.GetValue('EditorOptions/Display/GutterSeparatorIndex', 3);
 | 
				
			||||||
 | 
					    if OldGutterSeparatorIndex = -1 then
 | 
				
			||||||
 | 
					      FGutterPartSep.Visible := False
 | 
				
			||||||
 | 
					    else
 | 
				
			||||||
 | 
					    if OldGutterSeparatorIndex <> 3 then begin
 | 
				
			||||||
 | 
					      for i := OldGutterSeparatorIndex+1 to FGutterPartList.Count - 1 do
 | 
				
			||||||
 | 
					        FGutterPartList[i].Index := FGutterPartList[i].Index + 1;
 | 
				
			||||||
 | 
					      FGutterPartSep.Index := OldGutterSeparatorIndex;
 | 
				
			||||||
 | 
					      FGutterPartList.Sort;
 | 
				
			||||||
 | 
					    end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if not XMLConfig.GetValue('EditorOptions/Misc/ShowOverviewGutter', True) then
 | 
				
			||||||
 | 
					      FGutterPartOver.Visible := False;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    fGutterWidth :=
 | 
					    fGutterWidth :=
 | 
				
			||||||
      XMLConfig.GetValue('EditorOptions/Display/GutterWidth', 30);
 | 
					      XMLConfig.GetValue('EditorOptions/Display/GutterWidth', 30);
 | 
				
			||||||
    FGutterSeparatorIndex :=
 | 
					 | 
				
			||||||
      XMLConfig.GetValue('EditorOptions/Display/GutterSeparatorIndex', 3);
 | 
					 | 
				
			||||||
    fRightMargin :=
 | 
					    fRightMargin :=
 | 
				
			||||||
      XMLConfig.GetValue('EditorOptions/Display/RightMargin', 80);
 | 
					      XMLConfig.GetValue('EditorOptions/Display/RightMargin', 80);
 | 
				
			||||||
    fEditorFont  :=
 | 
					    fEditorFont  :=
 | 
				
			||||||
@ -5583,6 +5820,13 @@ begin
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    XMLConfig.WriteObject('EditorOptions/Misc/', Self, FDefaultValues);
 | 
					    XMLConfig.WriteObject('EditorOptions/Misc/', Self, FDefaultValues);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    XMLConfig.WriteObject('EditorOptions/GutterParts/Marks/',  FGutterPartMarks,  FGutterPartMarks.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.WriteObject('EditorOptions/GutterParts/Line/',   FGutterPartLine,   FGutterPartLine.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.WriteObject('EditorOptions/GutterParts/Change/', FGutterPartChange, FGutterPartChange.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.WriteObject('EditorOptions/GutterParts/Sep/',    FGutterPartSep,    FGutterPartSep.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.WriteObject('EditorOptions/GutterParts/Fold/',   FGutterPartFold,   FGutterPartFold.Defaults);
 | 
				
			||||||
 | 
					    XMLConfig.WriteObject('EditorOptions/GutterParts/Over/',   FGutterPartOver,   FGutterPartOver.Defaults);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // general options
 | 
					    // general options
 | 
				
			||||||
    for SynEditOpt := Low(TSynEditorOption) to High(TSynEditorOption) do
 | 
					    for SynEditOpt := Low(TSynEditorOption) to High(TSynEditorOption) do
 | 
				
			||||||
    begin
 | 
					    begin
 | 
				
			||||||
@ -5659,14 +5903,13 @@ begin
 | 
				
			|||||||
      , fVisibleRightMargin, True);
 | 
					      , fVisibleRightMargin, True);
 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/VisibleGutter',
 | 
					    XMLConfig.SetDeleteValue('EditorOptions/Display/VisibleGutter',
 | 
				
			||||||
      fVisibleGutter, True);
 | 
					      fVisibleGutter, True);
 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/ShowLineNumbers',
 | 
					    XMLConfig.DeleteValue('EditorOptions/Display/ShowLineNumbers');
 | 
				
			||||||
      fShowLineNumbers, True);
 | 
					 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/ShowOnlyLineNumbersMultiplesOf',
 | 
					    XMLConfig.SetDeleteValue('EditorOptions/Display/ShowOnlyLineNumbersMultiplesOf',
 | 
				
			||||||
      fShowOnlyLineNumbersMultiplesOf, 5);
 | 
					      fShowOnlyLineNumbersMultiplesOf, 5);
 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/GutterWidth',
 | 
					    XMLConfig.SetDeleteValue('EditorOptions/Display/GutterWidth',
 | 
				
			||||||
      fGutterWidth, 30);
 | 
					      fGutterWidth, 30);
 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/GutterSeparatorIndex',
 | 
					    XMLConfig.DeleteValue('EditorOptions/Display/GutterSeparatorIndex');
 | 
				
			||||||
      fGutterSeparatorIndex, 3);
 | 
					    XMLConfig.DeleteValue('EditorOptions/Misc/ShowOverviewGutter');
 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/RightMargin',
 | 
					    XMLConfig.SetDeleteValue('EditorOptions/Display/RightMargin',
 | 
				
			||||||
      fRightMargin, 80);
 | 
					      fRightMargin, 80);
 | 
				
			||||||
    XMLConfig.SetDeleteValue('EditorOptions/Display/EditorFont',
 | 
					    XMLConfig.SetDeleteValue('EditorOptions/Display/EditorFont',
 | 
				
			||||||
@ -6447,10 +6690,8 @@ begin
 | 
				
			|||||||
    // Display options
 | 
					    // Display options
 | 
				
			||||||
    ASynEdit.Gutter.Visible := fVisibleGutter;
 | 
					    ASynEdit.Gutter.Visible := fVisibleGutter;
 | 
				
			||||||
    ASynEdit.Gutter.AutoSize := true;
 | 
					    ASynEdit.Gutter.AutoSize := true;
 | 
				
			||||||
    ASynEdit.Gutter.LineNumberPart.Visible := fShowLineNumbers;
 | 
					 | 
				
			||||||
    ASynEdit.Gutter.LineNumberPart(0).ShowOnlyLineNumbersMultiplesOf :=
 | 
					    ASynEdit.Gutter.LineNumberPart(0).ShowOnlyLineNumbersMultiplesOf :=
 | 
				
			||||||
      fShowOnlyLineNumbersMultiplesOf;
 | 
					      fShowOnlyLineNumbersMultiplesOf;
 | 
				
			||||||
    ASynEdit.RightGutter.Visible := ShowOverviewGutter;
 | 
					 | 
				
			||||||
    if ASynEdit is TIDESynEditor then
 | 
					    if ASynEdit is TIDESynEditor then
 | 
				
			||||||
      TIDESynEditor(ASynEdit).ShowTopInfo := TopInfoView;
 | 
					      TIDESynEditor(ASynEdit).ShowTopInfo := TopInfoView;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -6460,9 +6701,6 @@ begin
 | 
				
			|||||||
    ASynEdit.Gutter.CodeFoldPart.ReversePopMenuOrder := ReverseFoldPopUpOrder;
 | 
					    ASynEdit.Gutter.CodeFoldPart.ReversePopMenuOrder := ReverseFoldPopUpOrder;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    ASynEdit.Gutter.Width := fGutterWidth;
 | 
					    ASynEdit.Gutter.Width := fGutterWidth;
 | 
				
			||||||
    ASynEdit.Gutter.SeparatorPart.Visible := FGutterSeparatorIndex <> -1;
 | 
					 | 
				
			||||||
    if FGutterSeparatorIndex <> -1 then
 | 
					 | 
				
			||||||
    ASynEdit.Gutter.SeparatorPart(0).Index := FGutterSeparatorIndex;
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    ASynEdit.RightEdge := fRightMargin;
 | 
					    ASynEdit.RightEdge := fRightMargin;
 | 
				
			||||||
    if fVisibleRightMargin then
 | 
					    if fVisibleRightMargin then
 | 
				
			||||||
@ -6515,16 +6753,30 @@ begin
 | 
				
			|||||||
    if ASynEdit.Gutter.ChangesPart<> nil then
 | 
					    if ASynEdit.Gutter.ChangesPart<> nil then
 | 
				
			||||||
      ASynEdit.Gutter.ChangesPart.MouseActions.Assign(FUserMouseSettings.GutterActionsChanges);
 | 
					      ASynEdit.Gutter.ChangesPart.MouseActions.Assign(FUserMouseSettings.GutterActionsChanges);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (ASynEdit.Gutter.SeparatorPart <> nil) and (GutterSeparatorIndex = 2) and ShowLineNumbers then
 | 
					    if (ASynEdit.Gutter.SeparatorPart <> nil) and
 | 
				
			||||||
 | 
					       (abs(FGutterPartSep.Index - FGutterPartLine.Index) = 1) and
 | 
				
			||||||
 | 
					       FGutterPartLine.Visible
 | 
				
			||||||
 | 
					    then
 | 
				
			||||||
      ASynEdit.Gutter.SeparatorPart.MouseActions.Assign(FUserMouseSettings.GutterActionsLines)
 | 
					      ASynEdit.Gutter.SeparatorPart.MouseActions.Assign(FUserMouseSettings.GutterActionsLines)
 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
    if (ASynEdit.Gutter.SeparatorPart <> nil) and (GutterSeparatorIndex >= 2) then
 | 
					    if (ASynEdit.Gutter.SeparatorPart <> nil) and (abs(FGutterPartSep.Index - FGutterPartChange.Index) = 1) then
 | 
				
			||||||
      ASynEdit.Gutter.SeparatorPart.MouseActions.Assign(FUserMouseSettings.GutterActionsChanges);
 | 
					      ASynEdit.Gutter.SeparatorPart.MouseActions.Assign(FUserMouseSettings.GutterActionsChanges);
 | 
				
			||||||
    if ASynEdit.RightGutter.LineOverviewPart <> nil then begin
 | 
					    if ASynEdit.RightGutter.LineOverviewPart <> nil then begin
 | 
				
			||||||
      ASynEdit.RightGutter.LineOverviewPart.MouseActions.Assign(FUserMouseSettings.GutterActionsOverView);
 | 
					      ASynEdit.RightGutter.LineOverviewPart.MouseActions.Assign(FUserMouseSettings.GutterActionsOverView);
 | 
				
			||||||
      ASynEdit.RightGutter.LineOverviewPart.MouseActionsForMarks.Assign(FUserMouseSettings.GutterActionsOverViewMarks);
 | 
					      ASynEdit.RightGutter.LineOverviewPart.MouseActionsForMarks.Assign(FUserMouseSettings.GutterActionsOverViewMarks);
 | 
				
			||||||
    end;
 | 
					    end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    GutterPartList.Sort;
 | 
				
			||||||
 | 
					    for i := 0 to GutterPartList.Count - 1 do begin
 | 
				
			||||||
 | 
					      GutterPartList[i].ApplyTo(ASynEdit.Gutter.Parts.ByClass[GutterPartList[i].GClass, 0]);
 | 
				
			||||||
 | 
					      GutterPartList[i].ApplyIndexTo(ASynEdit.Gutter.Parts.ByClass[GutterPartList[i].GClass, 0]);
 | 
				
			||||||
 | 
					    end;
 | 
				
			||||||
 | 
					    GutterRightPartList.Sort;
 | 
				
			||||||
 | 
					    for i := 0 to GutterRightPartList.Count - 1 do begin
 | 
				
			||||||
 | 
					      GutterRightPartList[i].ApplyTo(ASynEdit.RightGutter.Parts.ByClass[GutterRightPartList[i].GClass, 0]);
 | 
				
			||||||
 | 
					      GutterRightPartList[i].ApplyIndexTo(ASynEdit.RightGutter.Parts.ByClass[GutterRightPartList[i].GClass, 0]);
 | 
				
			||||||
 | 
					    end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    ASynEdit.ScrollOnEditLeftOptions.Assign(ScrollOnEditLeftOptions);
 | 
					    ASynEdit.ScrollOnEditLeftOptions.Assign(ScrollOnEditLeftOptions);
 | 
				
			||||||
    ASynEdit.ScrollOnEditRightOptions.Assign(ScrollOnEditRightOptions);
 | 
					    ASynEdit.ScrollOnEditRightOptions.Assign(ScrollOnEditRightOptions);
 | 
				
			||||||
  finally
 | 
					  finally
 | 
				
			||||||
 | 
				
			|||||||
@ -7,18 +7,18 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
  ClientWidth = 588
 | 
					  ClientWidth = 588
 | 
				
			||||||
  TabOrder = 0
 | 
					  TabOrder = 0
 | 
				
			||||||
  Visible = False
 | 
					  Visible = False
 | 
				
			||||||
  DesignLeft = 176
 | 
					  DesignLeft = 424
 | 
				
			||||||
  DesignTop = 232
 | 
					  DesignTop = 163
 | 
				
			||||||
  object MarginAndGutterGroupBox: TGroupBox
 | 
					  object MarginAndGutterGroupBox: TGroupBox
 | 
				
			||||||
    AnchorSideRight.Side = asrBottom
 | 
					    AnchorSideRight.Side = asrBottom
 | 
				
			||||||
    Left = 0
 | 
					    Left = 0
 | 
				
			||||||
    Height = 151
 | 
					    Height = 249
 | 
				
			||||||
    Top = 0
 | 
					    Top = 0
 | 
				
			||||||
    Width = 588
 | 
					    Width = 588
 | 
				
			||||||
    Align = alTop
 | 
					    Align = alTop
 | 
				
			||||||
    AutoSize = True
 | 
					    AutoSize = True
 | 
				
			||||||
    Caption = 'MarginAndGutterGroupBox'
 | 
					    Caption = 'MarginAndGutterGroupBox'
 | 
				
			||||||
    ClientHeight = 131
 | 
					    ClientHeight = 229
 | 
				
			||||||
    ClientWidth = 584
 | 
					    ClientWidth = 584
 | 
				
			||||||
    TabOrder = 0
 | 
					    TabOrder = 0
 | 
				
			||||||
    object RightMarginLabel: TLabel
 | 
					    object RightMarginLabel: TLabel
 | 
				
			||||||
@ -26,7 +26,7 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      AnchorSideLeft.Side = asrBottom
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
      AnchorSideTop.Control = RightMarginComboBox
 | 
					      AnchorSideTop.Control = RightMarginComboBox
 | 
				
			||||||
      AnchorSideTop.Side = asrCenter
 | 
					      AnchorSideTop.Side = asrCenter
 | 
				
			||||||
      Left = 311
 | 
					      Left = 341
 | 
				
			||||||
      Height = 15
 | 
					      Height = 15
 | 
				
			||||||
      Top = 10
 | 
					      Top = 10
 | 
				
			||||||
      Width = 94
 | 
					      Width = 94
 | 
				
			||||||
@ -38,33 +38,21 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      AnchorSideLeft.Side = asrBottom
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
      AnchorSideTop.Control = ShowOnlyLineNumbersMultiplesOfSpinEdit
 | 
					      AnchorSideTop.Control = ShowOnlyLineNumbersMultiplesOfSpinEdit
 | 
				
			||||||
      AnchorSideTop.Side = asrCenter
 | 
					      AnchorSideTop.Side = asrCenter
 | 
				
			||||||
      Left = 295
 | 
					      Left = 325
 | 
				
			||||||
      Height = 15
 | 
					      Height = 15
 | 
				
			||||||
      Top = 68
 | 
					      Top = 182
 | 
				
			||||||
      Width = 121
 | 
					      Width = 121
 | 
				
			||||||
      BorderSpacing.Left = 6
 | 
					      BorderSpacing.Left = 6
 | 
				
			||||||
      BorderSpacing.Top = 6
 | 
					      BorderSpacing.Top = 6
 | 
				
			||||||
      Caption = 'Every n-th line number'
 | 
					      Caption = 'Every n-th line number'
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object GutterSeparatorIndexLabel: TLabel
 | 
					 | 
				
			||||||
      AnchorSideLeft.Control = GutterSeparatorIndexSpinBox
 | 
					 | 
				
			||||||
      AnchorSideLeft.Side = asrBottom
 | 
					 | 
				
			||||||
      AnchorSideTop.Control = GutterSeparatorIndexSpinBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Side = asrCenter
 | 
					 | 
				
			||||||
      Left = 297
 | 
					 | 
				
			||||||
      Height = 15
 | 
					 | 
				
			||||||
      Top = 39
 | 
					 | 
				
			||||||
      Width = 140
 | 
					 | 
				
			||||||
      BorderSpacing.Left = 6
 | 
					 | 
				
			||||||
      Caption = 'GutterSeparatorIndexLabel'
 | 
					 | 
				
			||||||
    end
 | 
					 | 
				
			||||||
    object RightMarginColorLink: TLabel
 | 
					    object RightMarginColorLink: TLabel
 | 
				
			||||||
      AnchorSideLeft.Control = RightMarginLabel
 | 
					      AnchorSideLeft.Control = RightMarginLabel
 | 
				
			||||||
      AnchorSideLeft.Side = asrBottom
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
      AnchorSideTop.Control = RightMarginLabel
 | 
					      AnchorSideTop.Control = RightMarginLabel
 | 
				
			||||||
      AnchorSideTop.Side = asrCenter
 | 
					      AnchorSideTop.Side = asrCenter
 | 
				
			||||||
      Cursor = crHandPoint
 | 
					      Cursor = crHandPoint
 | 
				
			||||||
      Left = 411
 | 
					      Left = 441
 | 
				
			||||||
      Height = 15
 | 
					      Height = 15
 | 
				
			||||||
      Top = 10
 | 
					      Top = 10
 | 
				
			||||||
      Width = 117
 | 
					      Width = 117
 | 
				
			||||||
@ -82,48 +70,34 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      Left = 6
 | 
					      Left = 6
 | 
				
			||||||
      Height = 19
 | 
					      Height = 19
 | 
				
			||||||
      Top = 6
 | 
					      Top = 6
 | 
				
			||||||
      Width = 173
 | 
					      Width = 171
 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
      Caption = 'VisibleRightMarginCheckBox'
 | 
					      Caption = 'VisibleRightMarginCheckBox'
 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					 | 
				
			||||||
      TabOrder = 0
 | 
					      TabOrder = 0
 | 
				
			||||||
 | 
					      OnChange = GeneralCheckBoxOnChange
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object VisibleGutterCheckBox: TCheckBox
 | 
					    object VisibleGutterCheckBox: TCheckBox
 | 
				
			||||||
      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
					      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
				
			||||||
      AnchorSideTop.Control = VisibleRightMarginCheckBox
 | 
					      AnchorSideTop.Control = chkTopInfoView
 | 
				
			||||||
      AnchorSideTop.Side = asrBottom
 | 
					 | 
				
			||||||
      Left = 6
 | 
					      Left = 6
 | 
				
			||||||
      Height = 19
 | 
					      Height = 19
 | 
				
			||||||
      Top = 31
 | 
					      Top = 31
 | 
				
			||||||
      Width = 140
 | 
					      Width = 138
 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					      BorderSpacing.Left = 6
 | 
				
			||||||
 | 
					      BorderSpacing.Right = 6
 | 
				
			||||||
      Caption = 'VisibleGutterCheckBox'
 | 
					      Caption = 'VisibleGutterCheckBox'
 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					 | 
				
			||||||
      TabOrder = 1
 | 
					      TabOrder = 1
 | 
				
			||||||
    end
 | 
					 | 
				
			||||||
    object ShowLineNumbersCheckBox: TCheckBox
 | 
					 | 
				
			||||||
      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Control = VisibleGutterCheckBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Side = asrBottom
 | 
					 | 
				
			||||||
      Left = 6
 | 
					 | 
				
			||||||
      Height = 19
 | 
					 | 
				
			||||||
      Top = 56
 | 
					 | 
				
			||||||
      Width = 173
 | 
					 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					 | 
				
			||||||
      Caption = 'ShowLineNumbersCheckBox'
 | 
					 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					      OnChange = GeneralCheckBoxOnChange
 | 
				
			||||||
      OnClick = ShowLineNumbersCheckBoxClick
 | 
					 | 
				
			||||||
      TabOrder = 2
 | 
					 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object RightMarginComboBox: TComboBox
 | 
					    object RightMarginComboBox: TComboBox
 | 
				
			||||||
      AnchorSideLeft.Control = VisibleRightMarginCheckBox
 | 
					      AnchorSideLeft.Control = btnGutterUp
 | 
				
			||||||
      AnchorSideLeft.Side = asrBottom
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
      AnchorSideTop.Control = MarginAndGutterGroupBox
 | 
					      AnchorSideTop.Control = MarginAndGutterGroupBox
 | 
				
			||||||
      Left = 235
 | 
					      Left = 265
 | 
				
			||||||
      Height = 23
 | 
					      Height = 23
 | 
				
			||||||
      Top = 6
 | 
					      Top = 6
 | 
				
			||||||
      Width = 70
 | 
					      Width = 70
 | 
				
			||||||
      BorderSpacing.Left = 50
 | 
					      BorderSpacing.Left = 30
 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
      ItemHeight = 15
 | 
					      ItemHeight = 15
 | 
				
			||||||
      Items.Strings = (
 | 
					      Items.Strings = (
 | 
				
			||||||
@ -131,70 +105,184 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
        '78'
 | 
					        '78'
 | 
				
			||||||
        '76'
 | 
					        '76'
 | 
				
			||||||
      )
 | 
					      )
 | 
				
			||||||
 | 
					      TabOrder = 2
 | 
				
			||||||
      OnChange = ComboboxOnChange
 | 
					      OnChange = ComboboxOnChange
 | 
				
			||||||
      OnExit = ComboboxOnExit
 | 
					      OnExit = ComboboxOnExit
 | 
				
			||||||
      OnKeyDown = ComboBoxOnKeyDown
 | 
					      OnKeyDown = ComboBoxOnKeyDown
 | 
				
			||||||
      TabOrder = 3
 | 
					 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object ShowOnlyLineNumbersMultiplesOfSpinEdit: TSpinEdit
 | 
					    object ShowOnlyLineNumbersMultiplesOfSpinEdit: TSpinEdit
 | 
				
			||||||
      AnchorSideLeft.Control = GutterSeparatorIndexSpinBox
 | 
					      AnchorSideLeft.Control = RightMarginComboBox
 | 
				
			||||||
      AnchorSideTop.Control = GutterSeparatorIndexSpinBox
 | 
					      AnchorSideTop.Control = spinGutterPartLeftOffs
 | 
				
			||||||
      AnchorSideTop.Side = asrBottom
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
      Left = 235
 | 
					      Left = 265
 | 
				
			||||||
      Height = 23
 | 
					      Height = 23
 | 
				
			||||||
      Top = 64
 | 
					      Top = 178
 | 
				
			||||||
      Width = 54
 | 
					      Width = 54
 | 
				
			||||||
      BorderSpacing.Top = 6
 | 
					      BorderSpacing.Top = 6
 | 
				
			||||||
      MaxValue = 65536
 | 
					      MaxValue = 65536
 | 
				
			||||||
      MinValue = 1
 | 
					      MinValue = 1
 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					      TabOrder = 3
 | 
				
			||||||
      TabOrder = 4
 | 
					 | 
				
			||||||
      Value = 1
 | 
					      Value = 1
 | 
				
			||||||
    end
 | 
					 | 
				
			||||||
    object GutterSeparatorIndexSpinBox: TSpinEdit
 | 
					 | 
				
			||||||
      AnchorSideLeft.Control = RightMarginComboBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Control = RightMarginComboBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Side = asrBottom
 | 
					 | 
				
			||||||
      Left = 235
 | 
					 | 
				
			||||||
      Height = 23
 | 
					 | 
				
			||||||
      Top = 35
 | 
					 | 
				
			||||||
      Width = 56
 | 
					 | 
				
			||||||
      MaxValue = 4
 | 
					 | 
				
			||||||
      MinValue = -1
 | 
					 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					      OnChange = GeneralCheckBoxOnChange
 | 
				
			||||||
      TabOrder = 5
 | 
					 | 
				
			||||||
    end
 | 
					 | 
				
			||||||
    object chkShowOverview: TCheckBox
 | 
					 | 
				
			||||||
      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Control = ShowLineNumbersCheckBox
 | 
					 | 
				
			||||||
      AnchorSideTop.Side = asrBottom
 | 
					 | 
				
			||||||
      Left = 6
 | 
					 | 
				
			||||||
      Height = 19
 | 
					 | 
				
			||||||
      Top = 81
 | 
					 | 
				
			||||||
      Width = 117
 | 
					 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					 | 
				
			||||||
      Caption = 'chkShowOverview'
 | 
					 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					 | 
				
			||||||
      TabOrder = 6
 | 
					 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object chkTopInfoView: TCheckBox
 | 
					    object chkTopInfoView: TCheckBox
 | 
				
			||||||
      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
					      AnchorSideLeft.Control = RightMarginComboBox
 | 
				
			||||||
      AnchorSideTop.Control = chkShowOverview
 | 
					      AnchorSideTop.Control = VisibleRightMarginCheckBox
 | 
				
			||||||
      AnchorSideTop.Side = asrBottom
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
      Left = 6
 | 
					      Left = 271
 | 
				
			||||||
      Height = 19
 | 
					      Height = 19
 | 
				
			||||||
      Top = 106
 | 
					      Top = 31
 | 
				
			||||||
      Width = 105
 | 
					      Width = 103
 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
      Caption = 'chkTopInfoView'
 | 
					      Caption = 'chkTopInfoView'
 | 
				
			||||||
 | 
					      TabOrder = 4
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object lbGutterParts: TListBox
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = rgGutterSite
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
 | 
					      Left = 6
 | 
				
			||||||
 | 
					      Height = 128
 | 
				
			||||||
 | 
					      Top = 95
 | 
				
			||||||
 | 
					      Width = 194
 | 
				
			||||||
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
 | 
					      ItemHeight = 0
 | 
				
			||||||
 | 
					      TabOrder = 5
 | 
				
			||||||
 | 
					      OnClick = lbGutterPartsClick
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object btnGutterUp: TSpeedButton
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = lbGutterParts
 | 
				
			||||||
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = lbGutterParts
 | 
				
			||||||
 | 
					      Left = 206
 | 
				
			||||||
 | 
					      Height = 22
 | 
				
			||||||
 | 
					      Top = 101
 | 
				
			||||||
 | 
					      Width = 23
 | 
				
			||||||
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
 | 
					      OnClick = btnGutterUpClick
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object btnGutterDown: TSpeedButton
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = lbGutterParts
 | 
				
			||||||
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = btnGutterUp
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
 | 
					      Left = 206
 | 
				
			||||||
 | 
					      Height = 22
 | 
				
			||||||
 | 
					      Top = 129
 | 
				
			||||||
 | 
					      Width = 23
 | 
				
			||||||
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
 | 
					      OnClick = btnGutterDownClick
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object GutterPartVisible: TCheckBox
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = RightMarginComboBox
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = lbGutterParts
 | 
				
			||||||
 | 
					      Left = 265
 | 
				
			||||||
 | 
					      Height = 19
 | 
				
			||||||
 | 
					      Top = 95
 | 
				
			||||||
 | 
					      Width = 106
 | 
				
			||||||
 | 
					      Caption = 'GutterPartVisible'
 | 
				
			||||||
 | 
					      TabOrder = 6
 | 
				
			||||||
 | 
					      OnChange = spinGutterPartWidthChange
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object lblGutterPartMargin: TLabel
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = GutterPartVisible
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = spinGutterPartLeftOffs
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrCenter
 | 
				
			||||||
 | 
					      Left = 265
 | 
				
			||||||
 | 
					      Height = 15
 | 
				
			||||||
 | 
					      Top = 153
 | 
				
			||||||
 | 
					      Width = 105
 | 
				
			||||||
 | 
					      Caption = 'lblGutterPartMargin'
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object spinGutterPartLeftOffs: TSpinEdit
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = lblGutterPartMargin
 | 
				
			||||||
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = spinGutterPartWidth
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
 | 
					      Left = 376
 | 
				
			||||||
 | 
					      Height = 23
 | 
				
			||||||
 | 
					      Top = 149
 | 
				
			||||||
 | 
					      Width = 50
 | 
				
			||||||
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
 | 
					      MaxValue = 10
 | 
				
			||||||
 | 
					      TabOrder = 8
 | 
				
			||||||
 | 
					      OnChange = spinGutterPartWidthChange
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object spinGutterPartRightOffs: TSpinEdit
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = spinGutterPartLeftOffs
 | 
				
			||||||
 | 
					      AnchorSideLeft.Side = asrBottom
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = spinGutterPartLeftOffs
 | 
				
			||||||
 | 
					      Left = 432
 | 
				
			||||||
 | 
					      Height = 23
 | 
				
			||||||
 | 
					      Top = 149
 | 
				
			||||||
 | 
					      Width = 50
 | 
				
			||||||
 | 
					      BorderSpacing.Left = 6
 | 
				
			||||||
 | 
					      MaxValue = 25
 | 
				
			||||||
 | 
					      TabOrder = 10
 | 
				
			||||||
 | 
					      OnChange = spinGutterPartWidthChange
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object spinGutterPartWidth: TSpinEdit
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = spinGutterPartLeftOffs
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = GutterPartVisible
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
 | 
					      Left = 376
 | 
				
			||||||
 | 
					      Height = 23
 | 
				
			||||||
 | 
					      Top = 120
 | 
				
			||||||
 | 
					      Width = 50
 | 
				
			||||||
 | 
					      BorderSpacing.Top = 6
 | 
				
			||||||
 | 
					      BorderSpacing.Bottom = 6
 | 
				
			||||||
 | 
					      MaxValue = 99
 | 
				
			||||||
      TabOrder = 7
 | 
					      TabOrder = 7
 | 
				
			||||||
 | 
					      OnChange = spinGutterPartWidthChange
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object lblGutterPartWidth: TLabel
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = GutterPartVisible
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = spinGutterPartWidth
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrCenter
 | 
				
			||||||
 | 
					      Left = 265
 | 
				
			||||||
 | 
					      Height = 15
 | 
				
			||||||
 | 
					      Top = 124
 | 
				
			||||||
 | 
					      Width = 99
 | 
				
			||||||
 | 
					      Caption = 'lblGutterPartWidth'
 | 
				
			||||||
 | 
					    end
 | 
				
			||||||
 | 
					    object rgGutterSite: TRadioGroup
 | 
				
			||||||
 | 
					      AnchorSideLeft.Control = MarginAndGutterGroupBox
 | 
				
			||||||
 | 
					      AnchorSideTop.Control = VisibleGutterCheckBox
 | 
				
			||||||
 | 
					      AnchorSideTop.Side = asrBottom
 | 
				
			||||||
 | 
					      AnchorSideRight.Control = MarginAndGutterGroupBox
 | 
				
			||||||
 | 
					      AnchorSideRight.Side = asrBottom
 | 
				
			||||||
 | 
					      Left = 6
 | 
				
			||||||
 | 
					      Height = 39
 | 
				
			||||||
 | 
					      Top = 50
 | 
				
			||||||
 | 
					      Width = 106
 | 
				
			||||||
 | 
					      AutoFill = True
 | 
				
			||||||
 | 
					      AutoSize = True
 | 
				
			||||||
 | 
					      BorderSpacing.Left = 6
 | 
				
			||||||
 | 
					      BorderSpacing.Right = 6
 | 
				
			||||||
 | 
					      ChildSizing.LeftRightSpacing = 6
 | 
				
			||||||
 | 
					      ChildSizing.HorizontalSpacing = 6
 | 
				
			||||||
 | 
					      ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
 | 
				
			||||||
 | 
					      ChildSizing.EnlargeVertical = crsHomogenousChildResize
 | 
				
			||||||
 | 
					      ChildSizing.ShrinkHorizontal = crsScaleChilds
 | 
				
			||||||
 | 
					      ChildSizing.ShrinkVertical = crsScaleChilds
 | 
				
			||||||
 | 
					      ChildSizing.Layout = cclLeftToRightThenTopToBottom
 | 
				
			||||||
 | 
					      ChildSizing.ControlsPerLine = 2
 | 
				
			||||||
 | 
					      ClientHeight = 19
 | 
				
			||||||
 | 
					      ClientWidth = 102
 | 
				
			||||||
 | 
					      Columns = 2
 | 
				
			||||||
 | 
					      Items.Strings = (
 | 
				
			||||||
 | 
					        'Left'
 | 
				
			||||||
 | 
					        'Right'
 | 
				
			||||||
 | 
					      )
 | 
				
			||||||
 | 
					      TabOrder = 9
 | 
				
			||||||
 | 
					      OnClick = rgGutterSiteClick
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
  end
 | 
					  end
 | 
				
			||||||
  object EditorFontGroupBox: TGroupBox
 | 
					  object EditorFontGroupBox: TGroupBox
 | 
				
			||||||
    AnchorSideRight.Side = asrBottom
 | 
					    AnchorSideRight.Side = asrBottom
 | 
				
			||||||
    Left = 0
 | 
					    Left = 0
 | 
				
			||||||
    Height = 113
 | 
					    Height = 113
 | 
				
			||||||
    Top = 157
 | 
					    Top = 255
 | 
				
			||||||
    Width = 588
 | 
					    Width = 588
 | 
				
			||||||
    Align = alTop
 | 
					    Align = alTop
 | 
				
			||||||
    AutoSize = True
 | 
					    AutoSize = True
 | 
				
			||||||
@ -251,9 +339,9 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      BorderSpacing.Left = 6
 | 
					      BorderSpacing.Left = 6
 | 
				
			||||||
      BorderSpacing.Top = 6
 | 
					      BorderSpacing.Top = 6
 | 
				
			||||||
      ItemHeight = 15
 | 
					      ItemHeight = 15
 | 
				
			||||||
      OnEditingDone = EditorFontComboBoxEditingDone
 | 
					 | 
				
			||||||
      TabOrder = 0
 | 
					      TabOrder = 0
 | 
				
			||||||
      Text = 'EditorFontComboBox'
 | 
					      Text = 'EditorFontComboBox'
 | 
				
			||||||
 | 
					      OnEditingDone = EditorFontComboBoxEditingDone
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object EditorFontButton: TButton
 | 
					    object EditorFontButton: TButton
 | 
				
			||||||
      AnchorSideTop.Control = EditorFontComboBox
 | 
					      AnchorSideTop.Control = EditorFontComboBox
 | 
				
			||||||
@ -268,8 +356,8 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      Anchors = [akTop, akRight, akBottom]
 | 
					      Anchors = [akTop, akRight, akBottom]
 | 
				
			||||||
      BorderSpacing.Right = 6
 | 
					      BorderSpacing.Right = 6
 | 
				
			||||||
      Caption = '...'
 | 
					      Caption = '...'
 | 
				
			||||||
      OnClick = EditorFontButtonClick
 | 
					 | 
				
			||||||
      TabOrder = 1
 | 
					      TabOrder = 1
 | 
				
			||||||
 | 
					      OnClick = EditorFontButtonClick
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object EditorFontSizeSpinEdit: TSpinEdit
 | 
					    object EditorFontSizeSpinEdit: TSpinEdit
 | 
				
			||||||
      AnchorSideLeft.Control = EditorFontGroupBox
 | 
					      AnchorSideLeft.Control = EditorFontGroupBox
 | 
				
			||||||
@ -281,8 +369,8 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      Width = 50
 | 
					      Width = 50
 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
      MinValue = -100
 | 
					      MinValue = -100
 | 
				
			||||||
      OnChange = EditorFontSizeSpinEditChange
 | 
					 | 
				
			||||||
      TabOrder = 2
 | 
					      TabOrder = 2
 | 
				
			||||||
 | 
					      OnChange = EditorFontSizeSpinEditChange
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object ExtraLineSpacingComboBox: TComboBox
 | 
					    object ExtraLineSpacingComboBox: TComboBox
 | 
				
			||||||
      AnchorSideLeft.Control = EditorFontSizeLabel
 | 
					      AnchorSideLeft.Control = EditorFontSizeLabel
 | 
				
			||||||
@ -301,10 +389,10 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
        '1'
 | 
					        '1'
 | 
				
			||||||
        '2'
 | 
					        '2'
 | 
				
			||||||
      )
 | 
					      )
 | 
				
			||||||
 | 
					      TabOrder = 4
 | 
				
			||||||
      OnChange = ComboboxOnChange
 | 
					      OnChange = ComboboxOnChange
 | 
				
			||||||
      OnExit = ComboboxOnExit
 | 
					      OnExit = ComboboxOnExit
 | 
				
			||||||
      OnKeyDown = ComboBoxOnKeyDown
 | 
					      OnKeyDown = ComboBoxOnKeyDown
 | 
				
			||||||
      TabOrder = 4
 | 
					 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object ExtraCharSpacingComboBox: TComboBox
 | 
					    object ExtraCharSpacingComboBox: TComboBox
 | 
				
			||||||
      AnchorSideLeft.Control = ExtraLineSpacingComboBox
 | 
					      AnchorSideLeft.Control = ExtraLineSpacingComboBox
 | 
				
			||||||
@ -321,10 +409,10 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
        '1'
 | 
					        '1'
 | 
				
			||||||
        '2'
 | 
					        '2'
 | 
				
			||||||
      )
 | 
					      )
 | 
				
			||||||
 | 
					      TabOrder = 3
 | 
				
			||||||
      OnChange = ComboboxOnChange
 | 
					      OnChange = ComboboxOnChange
 | 
				
			||||||
      OnExit = ComboboxOnExit
 | 
					      OnExit = ComboboxOnExit
 | 
				
			||||||
      OnKeyDown = ComboBoxOnKeyDown
 | 
					      OnKeyDown = ComboBoxOnKeyDown
 | 
				
			||||||
      TabOrder = 3
 | 
					 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
    object DisableAntialiasingCheckBox: TCheckBox
 | 
					    object DisableAntialiasingCheckBox: TCheckBox
 | 
				
			||||||
      AnchorSideLeft.Control = EditorFontGroupBox
 | 
					      AnchorSideLeft.Control = EditorFontGroupBox
 | 
				
			||||||
@ -333,19 +421,19 @@ object EditorDisplayOptionsFrame: TEditorDisplayOptionsFrame
 | 
				
			|||||||
      Left = 6
 | 
					      Left = 6
 | 
				
			||||||
      Height = 19
 | 
					      Height = 19
 | 
				
			||||||
      Top = 64
 | 
					      Top = 64
 | 
				
			||||||
      Width = 173
 | 
					      Width = 171
 | 
				
			||||||
      BorderSpacing.Around = 6
 | 
					      BorderSpacing.Around = 6
 | 
				
			||||||
      Caption = 'DisableAntialiasingCheckBox'
 | 
					      Caption = 'DisableAntialiasingCheckBox'
 | 
				
			||||||
      OnChange = GeneralCheckBoxOnChange
 | 
					 | 
				
			||||||
      TabOrder = 5
 | 
					      TabOrder = 5
 | 
				
			||||||
 | 
					      OnChange = GeneralCheckBoxOnChange
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
  end
 | 
					  end
 | 
				
			||||||
  inline DisplayPreview: TSynEdit
 | 
					  inline DisplayPreview: TSynEdit
 | 
				
			||||||
    AnchorSideRight.Side = asrBottom
 | 
					    AnchorSideRight.Side = asrBottom
 | 
				
			||||||
    AnchorSideBottom.Side = asrBottom
 | 
					    AnchorSideBottom.Side = asrBottom
 | 
				
			||||||
    Left = 0
 | 
					    Left = 0
 | 
				
			||||||
    Height = 179
 | 
					    Height = 81
 | 
				
			||||||
    Top = 276
 | 
					    Top = 374
 | 
				
			||||||
    Width = 588
 | 
					    Width = 588
 | 
				
			||||||
    Align = alClient
 | 
					    Align = alClient
 | 
				
			||||||
    BorderSpacing.Top = 6
 | 
					    BorderSpacing.Top = 6
 | 
				
			||||||
 | 
				
			|||||||
@ -27,11 +27,13 @@ interface
 | 
				
			|||||||
uses
 | 
					uses
 | 
				
			||||||
  Classes, SysUtils,
 | 
					  Classes, SysUtils,
 | 
				
			||||||
  // LCL
 | 
					  // LCL
 | 
				
			||||||
  Graphics, Dialogs, StdCtrls, Spin, LCLType, Controls,
 | 
					  Graphics, Dialogs, StdCtrls, Spin, LCLType, Controls, Buttons, ExtCtrls,
 | 
				
			||||||
  // SynEdit
 | 
					  // SynEdit
 | 
				
			||||||
  SynEdit, SynEditMouseCmds, SynGutterLineNumber, SynGutterLineOverview, SynGutter, SynEditTypes,
 | 
					  SynEdit, SynEditMouseCmds, SynGutterLineNumber, SynGutterLineOverview,
 | 
				
			||||||
 | 
					  SynGutter, SynEditTypes, SynGutterBase, SynGutterMarks, SynGutterChanges,
 | 
				
			||||||
 | 
					  SynGutterCodeFolding,
 | 
				
			||||||
  // IdeIntf
 | 
					  // IdeIntf
 | 
				
			||||||
  IDEOptionsIntf, IDEOptEditorIntf, IDEUtils,
 | 
					  IDEOptionsIntf, IDEOptEditorIntf, IDEUtils, IDEImagesIntf,
 | 
				
			||||||
  // IDE
 | 
					  // IDE
 | 
				
			||||||
  EditorOptions, LazarusIDEStrConsts, editor_general_options, editor_color_options,
 | 
					  EditorOptions, LazarusIDEStrConsts, editor_general_options, editor_color_options,
 | 
				
			||||||
  SourceSynEditor, SourceMarks;
 | 
					  SourceSynEditor, SourceMarks;
 | 
				
			||||||
@ -40,8 +42,8 @@ type
 | 
				
			|||||||
  { TEditorDisplayOptionsFrame }
 | 
					  { TEditorDisplayOptionsFrame }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  TEditorDisplayOptionsFrame = class(TAbstractIDEOptionsEditor)
 | 
					  TEditorDisplayOptionsFrame = class(TAbstractIDEOptionsEditor)
 | 
				
			||||||
 | 
					    GutterPartVisible: TCheckBox;
 | 
				
			||||||
    chkTopInfoView: TCheckBox;
 | 
					    chkTopInfoView: TCheckBox;
 | 
				
			||||||
    chkShowOverview: TCheckBox;
 | 
					 | 
				
			||||||
    DisableAntialiasingCheckBox: TCheckBox;
 | 
					    DisableAntialiasingCheckBox: TCheckBox;
 | 
				
			||||||
    DisplayPreview: TSynEdit;
 | 
					    DisplayPreview: TSynEdit;
 | 
				
			||||||
    EditorFontButton: TButton;
 | 
					    EditorFontButton: TButton;
 | 
				
			||||||
@ -53,17 +55,25 @@ type
 | 
				
			|||||||
    ExtraCharSpacingLabel: TLabel;
 | 
					    ExtraCharSpacingLabel: TLabel;
 | 
				
			||||||
    ExtraLineSpacingComboBox: TComboBox;
 | 
					    ExtraLineSpacingComboBox: TComboBox;
 | 
				
			||||||
    ExtraLineSpacingLabel: TLabel;
 | 
					    ExtraLineSpacingLabel: TLabel;
 | 
				
			||||||
    GutterSeparatorIndexLabel: TLabel;
 | 
					    lblGutterPartWidth: TLabel;
 | 
				
			||||||
 | 
					    lblGutterPartMargin: TLabel;
 | 
				
			||||||
 | 
					    lbGutterParts: TListBox;
 | 
				
			||||||
    MarginAndGutterGroupBox: TGroupBox;
 | 
					    MarginAndGutterGroupBox: TGroupBox;
 | 
				
			||||||
 | 
					    rgGutterSite: TRadioGroup;
 | 
				
			||||||
    RightMarginColorLink: TLabel;
 | 
					    RightMarginColorLink: TLabel;
 | 
				
			||||||
    RightMarginComboBox: TComboBox;
 | 
					    RightMarginComboBox: TComboBox;
 | 
				
			||||||
    RightMarginLabel: TLabel;
 | 
					    RightMarginLabel: TLabel;
 | 
				
			||||||
    ShowLineNumbersCheckBox: TCheckBox;
 | 
					 | 
				
			||||||
    ShowOnlyLineNumbersMultiplesOfLabel: TLabel;
 | 
					    ShowOnlyLineNumbersMultiplesOfLabel: TLabel;
 | 
				
			||||||
    ShowOnlyLineNumbersMultiplesOfSpinEdit: TSpinEdit;
 | 
					    ShowOnlyLineNumbersMultiplesOfSpinEdit: TSpinEdit;
 | 
				
			||||||
    GutterSeparatorIndexSpinBox: TSpinEdit;
 | 
					    btnGutterUp: TSpeedButton;
 | 
				
			||||||
 | 
					    btnGutterDown: TSpeedButton;
 | 
				
			||||||
 | 
					    spinGutterPartWidth: TSpinEdit;
 | 
				
			||||||
 | 
					    spinGutterPartLeftOffs: TSpinEdit;
 | 
				
			||||||
 | 
					    spinGutterPartRightOffs: TSpinEdit;
 | 
				
			||||||
    VisibleGutterCheckBox: TCheckBox;
 | 
					    VisibleGutterCheckBox: TCheckBox;
 | 
				
			||||||
    VisibleRightMarginCheckBox: TCheckBox;
 | 
					    VisibleRightMarginCheckBox: TCheckBox;
 | 
				
			||||||
 | 
					    procedure btnGutterDownClick(Sender: TObject);
 | 
				
			||||||
 | 
					    procedure btnGutterUpClick(Sender: TObject);
 | 
				
			||||||
    procedure EditorFontButtonClick(Sender: TObject);
 | 
					    procedure EditorFontButtonClick(Sender: TObject);
 | 
				
			||||||
    procedure EditorFontComboBoxEditingDone(Sender: TObject);
 | 
					    procedure EditorFontComboBoxEditingDone(Sender: TObject);
 | 
				
			||||||
    procedure EditorFontSizeSpinEditChange(Sender: TObject);
 | 
					    procedure EditorFontSizeSpinEditChange(Sender: TObject);
 | 
				
			||||||
@ -72,13 +82,20 @@ type
 | 
				
			|||||||
      Shift: TShiftState);
 | 
					      Shift: TShiftState);
 | 
				
			||||||
    procedure ComboboxOnChange(Sender: TObject);
 | 
					    procedure ComboboxOnChange(Sender: TObject);
 | 
				
			||||||
    procedure GeneralCheckBoxOnChange(Sender: TObject);
 | 
					    procedure GeneralCheckBoxOnChange(Sender: TObject);
 | 
				
			||||||
 | 
					    procedure lbGutterPartsClick(Sender: TObject);
 | 
				
			||||||
 | 
					    procedure rgGutterSiteClick(Sender: TObject);
 | 
				
			||||||
 | 
					    procedure FillGutterPartList;
 | 
				
			||||||
    procedure RightMarginColorLinkClick(Sender: TObject);
 | 
					    procedure RightMarginColorLinkClick(Sender: TObject);
 | 
				
			||||||
    procedure RightMarginColorLinkMouseEnter(Sender: TObject);
 | 
					    procedure RightMarginColorLinkMouseEnter(Sender: TObject);
 | 
				
			||||||
    procedure RightMarginColorLinkMouseLeave(Sender: TObject);
 | 
					    procedure RightMarginColorLinkMouseLeave(Sender: TObject);
 | 
				
			||||||
    procedure ShowLineNumbersCheckBoxClick(Sender: TObject);
 | 
					    procedure spinGutterPartWidthChange(Sender: TObject);
 | 
				
			||||||
  private
 | 
					  private
 | 
				
			||||||
    FDialog: TAbstractOptionsEditorDialog;
 | 
					    FDialog: TAbstractOptionsEditorDialog;
 | 
				
			||||||
    FUpdatingFontSizeRange: Boolean;
 | 
					    FUpdatingFontSizeRange: Boolean;
 | 
				
			||||||
 | 
					    FCurrentGutterPart: TEditorSynGutterOptions;
 | 
				
			||||||
 | 
					    FCurGutterPartList: TEditorSynGutterOptionsList;
 | 
				
			||||||
 | 
					    FCurGutterRightPartList: TEditorSynGutterOptionsList;
 | 
				
			||||||
 | 
					    FGutterParsUpdating: Boolean;
 | 
				
			||||||
    function FontSizeNegativeToPositive(NegativeSize: Integer): Integer;
 | 
					    function FontSizeNegativeToPositive(NegativeSize: Integer): Integer;
 | 
				
			||||||
    function GeneralPage: TEditorGeneralOptionsFrame; inline;
 | 
					    function GeneralPage: TEditorGeneralOptionsFrame; inline;
 | 
				
			||||||
    procedure SetEditorFontSizeSpinEditValue(FontSize: Integer);
 | 
					    procedure SetEditorFontSizeSpinEditValue(FontSize: Integer);
 | 
				
			||||||
@ -87,11 +104,16 @@ type
 | 
				
			|||||||
    function DoSynEditMouse(var {%H-}AnInfo: TSynEditMouseActionInfo;
 | 
					    function DoSynEditMouse(var {%H-}AnInfo: TSynEditMouseActionInfo;
 | 
				
			||||||
                         {%H-}HandleActionProc: TSynEditMouseActionHandler): Boolean;
 | 
					                         {%H-}HandleActionProc: TSynEditMouseActionHandler): Boolean;
 | 
				
			||||||
  public
 | 
					  public
 | 
				
			||||||
 | 
					    constructor Create(AOwner: TComponent); override;
 | 
				
			||||||
 | 
					    destructor Destroy; override;
 | 
				
			||||||
 | 
					    procedure UpdatePreviews;
 | 
				
			||||||
    function GetTitle: String; override;
 | 
					    function GetTitle: String; override;
 | 
				
			||||||
    procedure Setup(ADialog: TAbstractOptionsEditorDialog); override;
 | 
					    procedure Setup(ADialog: TAbstractOptionsEditorDialog); override;
 | 
				
			||||||
    procedure ReadSettings(AOptions: TAbstractIDEOptions); override;
 | 
					    procedure ReadSettings(AOptions: TAbstractIDEOptions); override;
 | 
				
			||||||
    procedure WriteSettings(AOptions: TAbstractIDEOptions); override;
 | 
					    procedure WriteSettings(AOptions: TAbstractIDEOptions); override;
 | 
				
			||||||
    class function SupportedOptionsClass: TAbstractIDEOptionsClass; override;
 | 
					    class function SupportedOptionsClass: TAbstractIDEOptionsClass; override;
 | 
				
			||||||
 | 
					    property CurGutterPartList: TEditorSynGutterOptionsList read FCurGutterPartList;
 | 
				
			||||||
 | 
					    property CurGutterRightPartList: TEditorSynGutterOptionsList read FCurGutterRightPartList;
 | 
				
			||||||
  end;
 | 
					  end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
implementation
 | 
					implementation
 | 
				
			||||||
@ -131,6 +153,38 @@ begin
 | 
				
			|||||||
  Result := true;
 | 
					  Result := true;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					constructor TEditorDisplayOptionsFrame.Create(AOwner: TComponent);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  inherited Create(AOwner);
 | 
				
			||||||
 | 
					  FCurGutterPartList := TEditorSynGutterOptionsList.Create(True);
 | 
				
			||||||
 | 
					  FCurGutterRightPartList := TEditorSynGutterOptionsList.Create(True);
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					destructor TEditorDisplayOptionsFrame.Destroy;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  inherited Destroy;
 | 
				
			||||||
 | 
					  FCurGutterPartList.Free;
 | 
				
			||||||
 | 
					  FCurGutterRightPartList.Free;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorDisplayOptionsFrame.UpdatePreviews;
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  i, j: Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  with GeneralPage do
 | 
				
			||||||
 | 
					    for i := Low(PreviewEdits) to High(PreviewEdits) do
 | 
				
			||||||
 | 
					      if PreviewEdits[i] <> nil then begin
 | 
				
			||||||
 | 
					        for j := 0 to FCurGutterPartList.Count - 1 do begin
 | 
				
			||||||
 | 
					          FCurGutterPartList[j].ApplyTo(PreviewEdits[i].Gutter.Parts.ByClass[FCurGutterPartList[j].GClass, 0]);
 | 
				
			||||||
 | 
					          FCurGutterPartList[j].ApplyIndexTo(PreviewEdits[i].Gutter.Parts.ByClass[FCurGutterPartList[j].GClass, 0]);
 | 
				
			||||||
 | 
					        end;
 | 
				
			||||||
 | 
					        for j := 0 to FCurGutterRightPartList.Count - 1 do begin
 | 
				
			||||||
 | 
					          FCurGutterRightPartList[j].ApplyTo(PreviewEdits[i].RightGutter.Parts.ByClass[FCurGutterRightPartList[j].GClass, 0]);
 | 
				
			||||||
 | 
					          FCurGutterRightPartList[j].ApplyIndexTo(PreviewEdits[i].RightGutter.Parts.ByClass[FCurGutterRightPartList[j].GClass, 0]);
 | 
				
			||||||
 | 
					        end;
 | 
				
			||||||
 | 
					      end;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
procedure TEditorDisplayOptionsFrame.EditorFontButtonClick(Sender: TObject);
 | 
					procedure TEditorDisplayOptionsFrame.EditorFontButtonClick(Sender: TObject);
 | 
				
			||||||
var
 | 
					var
 | 
				
			||||||
  FontDialog: TFontDialog;
 | 
					  FontDialog: TFontDialog;
 | 
				
			||||||
@ -262,7 +316,6 @@ procedure TEditorDisplayOptionsFrame.GeneralCheckBoxOnChange(Sender: TObject);
 | 
				
			|||||||
var
 | 
					var
 | 
				
			||||||
  a: integer;
 | 
					  a: integer;
 | 
				
			||||||
  AGeneralPage: TEditorGeneralOptionsFrame;
 | 
					  AGeneralPage: TEditorGeneralOptionsFrame;
 | 
				
			||||||
  Separator: TSynGutterSeparator;
 | 
					 | 
				
			||||||
begin
 | 
					begin
 | 
				
			||||||
  AGeneralPage := GeneralPage;
 | 
					  AGeneralPage := GeneralPage;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -274,20 +327,10 @@ begin
 | 
				
			|||||||
      if PreviewEdits[a] <> nil then
 | 
					      if PreviewEdits[a] <> nil then
 | 
				
			||||||
      begin
 | 
					      begin
 | 
				
			||||||
        PreviewEdits[a].Gutter.Visible := VisibleGutterCheckBox.Checked;
 | 
					        PreviewEdits[a].Gutter.Visible := VisibleGutterCheckBox.Checked;
 | 
				
			||||||
        PreviewEdits[a].RightGutter.Visible := chkShowOverview.Checked;
 | 
					 | 
				
			||||||
        PreviewEdits[a].Gutter.LineNumberPart.Visible
 | 
					 | 
				
			||||||
          := ShowLineNumbersCheckBox.Checked;
 | 
					 | 
				
			||||||
        if Assigned(PreviewEdits[a].Gutter.Parts.ByClass[TSynGutterLineNumber, 0]) then
 | 
					        if Assigned(PreviewEdits[a].Gutter.Parts.ByClass[TSynGutterLineNumber, 0]) then
 | 
				
			||||||
          TSynGutterLineNumber(PreviewEdits[a].Gutter.Parts.ByClass[TSynGutterLineNumber, 0])
 | 
					          TSynGutterLineNumber(PreviewEdits[a].Gutter.Parts.ByClass[TSynGutterLineNumber, 0])
 | 
				
			||||||
            .ShowOnlyLineNumbersMultiplesOf := ShowOnlyLineNumbersMultiplesOfSpinEdit.Value;
 | 
					            .ShowOnlyLineNumbersMultiplesOf := ShowOnlyLineNumbersMultiplesOfSpinEdit.Value;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        Separator := TSynGutterSeparator(PreviewEdits[a].Gutter.Parts.ByClass[TSynGutterSeparator, 0]);
 | 
					 | 
				
			||||||
        if Assigned(Separator) then
 | 
					 | 
				
			||||||
        begin
 | 
					 | 
				
			||||||
          Separator.Visible := GutterSeparatorIndexSpinBox.Value <> -1;
 | 
					 | 
				
			||||||
          if Separator.Visible then
 | 
					 | 
				
			||||||
            Separator.Index := GutterSeparatorIndexSpinBox.Value;
 | 
					 | 
				
			||||||
        end;
 | 
					 | 
				
			||||||
        PreviewEdits[a].RightEdge := StrToIntDef(RightMarginComboBox.Text, 80);
 | 
					        PreviewEdits[a].RightEdge := StrToIntDef(RightMarginComboBox.Text, 80);
 | 
				
			||||||
        if VisibleRightMarginCheckBox.Checked then
 | 
					        if VisibleRightMarginCheckBox.Checked then
 | 
				
			||||||
          PreviewEdits[a].Options := PreviewEdits[a].Options - [eoHideRightMargin]
 | 
					          PreviewEdits[a].Options := PreviewEdits[a].Options - [eoHideRightMargin]
 | 
				
			||||||
@ -300,6 +343,107 @@ begin
 | 
				
			|||||||
      end;
 | 
					      end;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorDisplayOptionsFrame.lbGutterPartsClick(Sender: TObject);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  FCurrentGutterPart := nil;
 | 
				
			||||||
 | 
					  if lbGutterParts.ItemIndex >= 0 then
 | 
				
			||||||
 | 
					    FCurrentGutterPart := TEditorSynGutterOptions(lbGutterParts.Items.Objects[lbGutterParts.ItemIndex]);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  FGutterParsUpdating := True;
 | 
				
			||||||
 | 
					  GutterPartVisible.Checked := FCurrentGutterPart.Visible;
 | 
				
			||||||
 | 
					  spinGutterPartWidth.Value := FCurrentGutterPart.Width;
 | 
				
			||||||
 | 
					  spinGutterPartLeftOffs.Value := FCurrentGutterPart.OffsetLeft;
 | 
				
			||||||
 | 
					  spinGutterPartRightOffs.Value := FCurrentGutterPart.OffsetRight;
 | 
				
			||||||
 | 
					  FGutterParsUpdating := False;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  btnGutterUp.Enabled := lbGutterParts.ItemIndex > 0;
 | 
				
			||||||
 | 
					  btnGutterDown.Enabled := lbGutterParts.ItemIndex < lbGutterParts.Count - 1;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  ShowOnlyLineNumbersMultiplesOfSpinEdit.Enabled := (FCurrentGutterPart <> nil) and
 | 
				
			||||||
 | 
					    (FCurrentGutterPart.GClass = TSynGutterLineNumber);
 | 
				
			||||||
 | 
					  ShowOnlyLineNumbersMultiplesOfLabel.Enabled := ShowOnlyLineNumbersMultiplesOfSpinEdit.Enabled;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorDisplayOptionsFrame.btnGutterUpClick(Sender: TObject);
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  l: TEditorSynGutterOptionsList;
 | 
				
			||||||
 | 
					  i, i2: Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if rgGutterSite.Buttons[0].Checked
 | 
				
			||||||
 | 
					  then l := FCurGutterPartList
 | 
				
			||||||
 | 
					  else l := FCurGutterRightPartList;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  i := lbGutterParts.ItemIndex;
 | 
				
			||||||
 | 
					  if (i < 1) or (i >= l.Count) then
 | 
				
			||||||
 | 
					    exit;
 | 
				
			||||||
 | 
					  i2 := l[i-1].Index;
 | 
				
			||||||
 | 
					  l[i-1].Index := l[i].Index;
 | 
				
			||||||
 | 
					  l[i].Index := i2;
 | 
				
			||||||
 | 
					  l.Sort;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  FillGutterPartList;
 | 
				
			||||||
 | 
					  lbGutterParts.ItemIndex := i - 1;
 | 
				
			||||||
 | 
					  lbGutterPartsClick(nil);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  UpdatePreviews;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorDisplayOptionsFrame.btnGutterDownClick(Sender: TObject);
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  l: TEditorSynGutterOptionsList;
 | 
				
			||||||
 | 
					  i, i2: Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if rgGutterSite.Buttons[0].Checked
 | 
				
			||||||
 | 
					  then l := FCurGutterPartList
 | 
				
			||||||
 | 
					  else l := FCurGutterRightPartList;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  i := lbGutterParts.ItemIndex;
 | 
				
			||||||
 | 
					  if (i < 0) or (i >= l.Count-1) then
 | 
				
			||||||
 | 
					    exit;
 | 
				
			||||||
 | 
					  i2 := l[i+1].Index;
 | 
				
			||||||
 | 
					  l[i+1].Index := l[i].Index;
 | 
				
			||||||
 | 
					  l[i].Index := i2;
 | 
				
			||||||
 | 
					  l.Sort;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  FillGutterPartList;
 | 
				
			||||||
 | 
					  lbGutterParts.ItemIndex := i + 1;
 | 
				
			||||||
 | 
					  lbGutterPartsClick(nil);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  UpdatePreviews;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorDisplayOptionsFrame.rgGutterSiteClick(Sender: TObject);
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  FillGutterPartList;
 | 
				
			||||||
 | 
					  lbGutterParts.ItemIndex := 0;
 | 
				
			||||||
 | 
					  lbGutterPartsClick(nil);
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					procedure TEditorDisplayOptionsFrame.FillGutterPartList;
 | 
				
			||||||
 | 
					  function GPartName(aGClass: TSynGutterPartBaseClass): string;
 | 
				
			||||||
 | 
					  begin
 | 
				
			||||||
 | 
					    Result := '?';
 | 
				
			||||||
 | 
					    if aGClass = TSynGutterMarks        then Result := optDispGutterMarks;
 | 
				
			||||||
 | 
					    if aGClass = TSynGutterLineNumber   then Result := dlgAddHiAttrLineNumber;
 | 
				
			||||||
 | 
					    if aGClass = TSynGutterChanges      then Result := optDispGutterChanges;
 | 
				
			||||||
 | 
					    if aGClass = TSynGutterSeparator    then Result := optDispGutterSeparator;
 | 
				
			||||||
 | 
					    if aGClass = TSynGutterCodeFolding  then Result := optDispGutterFolding;
 | 
				
			||||||
 | 
					    if aGClass = TSynGutterLineOverview then Result := dlgMouseOptNodeGutterLineOverview;
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					var
 | 
				
			||||||
 | 
					  l: TEditorSynGutterOptionsList;
 | 
				
			||||||
 | 
					  i: Integer;
 | 
				
			||||||
 | 
					begin
 | 
				
			||||||
 | 
					  if rgGutterSite.Buttons[0].Checked
 | 
				
			||||||
 | 
					  then l := FCurGutterPartList
 | 
				
			||||||
 | 
					  else l := FCurGutterRightPartList;
 | 
				
			||||||
 | 
					  lbGutterParts.Clear;
 | 
				
			||||||
 | 
					  for i := 0 to l.Count - 1 do begin
 | 
				
			||||||
 | 
					    lbGutterParts.AddItem(GPartName(l[i].GClass), l[i]);
 | 
				
			||||||
 | 
					  end;
 | 
				
			||||||
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
procedure TEditorDisplayOptionsFrame.RightMarginColorLinkClick(Sender: TObject);
 | 
					procedure TEditorDisplayOptionsFrame.RightMarginColorLinkClick(Sender: TObject);
 | 
				
			||||||
var
 | 
					var
 | 
				
			||||||
  col: TEditorColorOptionsFrame;
 | 
					  col: TEditorColorOptionsFrame;
 | 
				
			||||||
@ -322,10 +466,16 @@ begin
 | 
				
			|||||||
  (Sender as TLabel).Font.Color := clBlue;
 | 
					  (Sender as TLabel).Font.Color := clBlue;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
procedure TEditorDisplayOptionsFrame.ShowLineNumbersCheckBoxClick(Sender: TObject);
 | 
					procedure TEditorDisplayOptionsFrame.spinGutterPartWidthChange(Sender: TObject);
 | 
				
			||||||
begin
 | 
					begin
 | 
				
			||||||
  ShowOnlyLineNumbersMultiplesOfSpinEdit.Enabled := ShowLineNumbersCheckBox.Checked;
 | 
					  if FGutterParsUpdating then
 | 
				
			||||||
  ShowOnlyLineNumbersMultiplesOfLabel.Enabled := ShowLineNumbersCheckBox.Checked;
 | 
					    exit;
 | 
				
			||||||
 | 
					  FCurrentGutterPart.Visible := GutterPartVisible.Checked;
 | 
				
			||||||
 | 
					  FCurrentGutterPart.Width := spinGutterPartWidth.Value;
 | 
				
			||||||
 | 
					  FCurrentGutterPart.OffsetLeft := spinGutterPartLeftOffs.Value;
 | 
				
			||||||
 | 
					  FCurrentGutterPart.OffsetRight := spinGutterPartRightOffs.Value;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  UpdatePreviews;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function TEditorDisplayOptionsFrame.GeneralPage: TEditorGeneralOptionsFrame; inline;
 | 
					function TEditorDisplayOptionsFrame.GeneralPage: TEditorGeneralOptionsFrame; inline;
 | 
				
			||||||
@ -363,9 +513,7 @@ begin
 | 
				
			|||||||
  MarginAndGutterGroupBox.Caption := dlgMarginGutter;
 | 
					  MarginAndGutterGroupBox.Caption := dlgMarginGutter;
 | 
				
			||||||
  VisibleRightMarginCheckBox.Caption := dlgVisibleRightMargin;
 | 
					  VisibleRightMarginCheckBox.Caption := dlgVisibleRightMargin;
 | 
				
			||||||
  VisibleGutterCheckBox.Caption := dlgVisibleGutter;
 | 
					  VisibleGutterCheckBox.Caption := dlgVisibleGutter;
 | 
				
			||||||
  ShowLineNumbersCheckBox.Caption := dlgShowLineNumbers;
 | 
					 | 
				
			||||||
  ShowOnlyLineNumbersMultiplesOfLabel.Caption := lisEveryNThLineNumber;
 | 
					  ShowOnlyLineNumbersMultiplesOfLabel.Caption := lisEveryNThLineNumber;
 | 
				
			||||||
  GutterSeparatorIndexLabel.Caption := dlgGutterSeparatorIndex;
 | 
					 | 
				
			||||||
  RightMarginLabel.Caption := dlgRightMargin;
 | 
					  RightMarginLabel.Caption := dlgRightMargin;
 | 
				
			||||||
  EditorFontGroupBox.Caption := dlgDefaultEditorFont;
 | 
					  EditorFontGroupBox.Caption := dlgDefaultEditorFont;
 | 
				
			||||||
  EditorFontSizeLabel.Caption := dlgEditorFontSize;
 | 
					  EditorFontSizeLabel.Caption := dlgEditorFontSize;
 | 
				
			||||||
@ -373,9 +521,19 @@ begin
 | 
				
			|||||||
  ExtraLineSpacingLabel.Caption := dlgExtraLineSpacing;
 | 
					  ExtraLineSpacingLabel.Caption := dlgExtraLineSpacing;
 | 
				
			||||||
  DisableAntialiasingCheckBox.Caption := dlgDisableAntialiasing;
 | 
					  DisableAntialiasingCheckBox.Caption := dlgDisableAntialiasing;
 | 
				
			||||||
  RightMarginColorLink.Caption := dlgColorLink;
 | 
					  RightMarginColorLink.Caption := dlgColorLink;
 | 
				
			||||||
  chkShowOverview.Caption := lisShowOverviewGutter;
 | 
					 | 
				
			||||||
  chkTopInfoView.Caption := lisTopInfoView;
 | 
					  chkTopInfoView.Caption := lisTopInfoView;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  btnGutterUp.Images := IDEImages.Images_16;
 | 
				
			||||||
 | 
					  btnGutterDown.Images := IDEImages.Images_16;
 | 
				
			||||||
 | 
					  btnGutterUp.ImageIndex := IDEImages.LoadImage('arrow_up', 16);
 | 
				
			||||||
 | 
					  btnGutterDown.ImageIndex := IDEImages.LoadImage('arrow_down', 16);
 | 
				
			||||||
 | 
					  rgGutterSite.Items[0] := lisLeftGutter;
 | 
				
			||||||
 | 
					  rgGutterSite.Items[1] := lisRightGutter;
 | 
				
			||||||
 | 
					  GutterPartVisible.Caption := lisGutterPartVisible;
 | 
				
			||||||
 | 
					  lblGutterPartWidth.Caption := lisGutterPartWidth;
 | 
				
			||||||
 | 
					  lblGutterPartMargin.Caption := lisGutterPartMargin;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  with GeneralPage do
 | 
					  with GeneralPage do
 | 
				
			||||||
    AddPreviewEdit(DisplayPreview);
 | 
					    AddPreviewEdit(DisplayPreview);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -408,10 +566,8 @@ begin
 | 
				
			|||||||
    // init the spin-edit first, since it does not trigger on change,
 | 
					    // init the spin-edit first, since it does not trigger on change,
 | 
				
			||||||
    // but is copied when checkboxes are initialized
 | 
					    // but is copied when checkboxes are initialized
 | 
				
			||||||
    ShowOnlyLineNumbersMultiplesOfSpinEdit.Value := ShowOnlyLineNumbersMultiplesOf;
 | 
					    ShowOnlyLineNumbersMultiplesOfSpinEdit.Value := ShowOnlyLineNumbersMultiplesOf;
 | 
				
			||||||
    GutterSeparatorIndexSpinBox.Value := GutterSeparatorIndex;
 | 
					 | 
				
			||||||
    VisibleRightMarginCheckBox.Checked := VisibleRightMargin;
 | 
					    VisibleRightMarginCheckBox.Checked := VisibleRightMargin;
 | 
				
			||||||
    VisibleGutterCheckBox.Checked := VisibleGutter;
 | 
					    VisibleGutterCheckBox.Checked := VisibleGutter;
 | 
				
			||||||
    ShowLineNumbersCheckBox.Checked := ShowLineNumbers;
 | 
					 | 
				
			||||||
    VisibleRightMarginCheckBox.Checked := VisibleRightMargin;
 | 
					    VisibleRightMarginCheckBox.Checked := VisibleRightMargin;
 | 
				
			||||||
    SetComboBoxText(RightMarginComboBox, IntToStr(RightMargin),cstCaseInsensitive);
 | 
					    SetComboBoxText(RightMarginComboBox, IntToStr(RightMargin),cstCaseInsensitive);
 | 
				
			||||||
    SetComboBoxText(EditorFontComboBox, EditorFont,cstCaseInsensitive);
 | 
					    SetComboBoxText(EditorFontComboBox, EditorFont,cstCaseInsensitive);
 | 
				
			||||||
@ -419,12 +575,17 @@ begin
 | 
				
			|||||||
    SetComboBoxText(ExtraCharSpacingComboBox, IntToStr(ExtraCharSpacing),cstCaseInsensitive);
 | 
					    SetComboBoxText(ExtraCharSpacingComboBox, IntToStr(ExtraCharSpacing),cstCaseInsensitive);
 | 
				
			||||||
    SetComboBoxText(ExtraLineSpacingComboBox, IntToStr(ExtraLineSpacing),cstCaseInsensitive);
 | 
					    SetComboBoxText(ExtraLineSpacingComboBox, IntToStr(ExtraLineSpacing),cstCaseInsensitive);
 | 
				
			||||||
    DisableAntialiasingCheckBox.Checked := DisableAntialiasing;
 | 
					    DisableAntialiasingCheckBox.Checked := DisableAntialiasing;
 | 
				
			||||||
    chkShowOverview.Checked := ShowOverviewGutter;
 | 
					 | 
				
			||||||
    chkTopInfoView.Checked := TopInfoView;
 | 
					    chkTopInfoView.Checked := TopInfoView;
 | 
				
			||||||
 | 
					    FCurGutterPartList.Assign(GutterPartList);
 | 
				
			||||||
 | 
					    FCurGutterRightPartList.Assign(GutterRightPartList);
 | 
				
			||||||
 | 
					    FCurGutterPartList.Sort;
 | 
				
			||||||
 | 
					    GutterRightPartList.Sort;
 | 
				
			||||||
  end;
 | 
					  end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  ShowOnlyLineNumbersMultiplesOfLabel.Enabled := ShowLineNumbersCheckBox.Checked;
 | 
					  rgGutterSite.Buttons[0].Checked := True;
 | 
				
			||||||
  ShowOnlyLineNumbersMultiplesOfSpinEdit.Enabled := ShowLineNumbersCheckBox.Checked;
 | 
					  FillGutterPartList;
 | 
				
			||||||
 | 
					  lbGutterParts.ItemIndex := 0;
 | 
				
			||||||
 | 
					  lbGutterPartsClick(nil);
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
procedure TEditorDisplayOptionsFrame.WriteSettings(AOptions: TAbstractIDEOptions);
 | 
					procedure TEditorDisplayOptionsFrame.WriteSettings(AOptions: TAbstractIDEOptions);
 | 
				
			||||||
@ -433,9 +594,7 @@ begin
 | 
				
			|||||||
  begin
 | 
					  begin
 | 
				
			||||||
    VisibleRightMargin := VisibleRightMarginCheckBox.Checked;
 | 
					    VisibleRightMargin := VisibleRightMarginCheckBox.Checked;
 | 
				
			||||||
    VisibleGutter := VisibleGutterCheckBox.Checked;
 | 
					    VisibleGutter := VisibleGutterCheckBox.Checked;
 | 
				
			||||||
    ShowLineNumbers := ShowLineNumbersCheckBox.Checked;
 | 
					 | 
				
			||||||
    ShowOnlyLineNumbersMultiplesOf := ShowOnlyLineNumbersMultiplesOfSpinEdit.Value;
 | 
					    ShowOnlyLineNumbersMultiplesOf := ShowOnlyLineNumbersMultiplesOfSpinEdit.Value;
 | 
				
			||||||
    GutterSeparatorIndex := GutterSeparatorIndexSpinBox.Value;
 | 
					 | 
				
			||||||
    VisibleRightMargin := VisibleRightMarginCheckBox.Checked;
 | 
					    VisibleRightMargin := VisibleRightMarginCheckBox.Checked;
 | 
				
			||||||
    RightMargin := StrToIntDef(RightMarginComboBox.Text, 80);
 | 
					    RightMargin := StrToIntDef(RightMarginComboBox.Text, 80);
 | 
				
			||||||
    EditorFont := EditorFontComboBox.Text;
 | 
					    EditorFont := EditorFontComboBox.Text;
 | 
				
			||||||
@ -443,8 +602,9 @@ begin
 | 
				
			|||||||
    ExtraCharSpacing := StrToIntDef(ExtraCharSpacingComboBox.Text, ExtraCharSpacing);
 | 
					    ExtraCharSpacing := StrToIntDef(ExtraCharSpacingComboBox.Text, ExtraCharSpacing);
 | 
				
			||||||
    ExtraLineSpacing := StrToIntDef(ExtraLineSpacingComboBox.Text, ExtraLineSpacing);
 | 
					    ExtraLineSpacing := StrToIntDef(ExtraLineSpacingComboBox.Text, ExtraLineSpacing);
 | 
				
			||||||
    DisableAntialiasing := DisableAntialiasingCheckBox.Checked;
 | 
					    DisableAntialiasing := DisableAntialiasingCheckBox.Checked;
 | 
				
			||||||
    ShowOverviewGutter := chkShowOverview.Checked;
 | 
					 | 
				
			||||||
    TopInfoView := chkTopInfoView.Checked;
 | 
					    TopInfoView := chkTopInfoView.Checked;
 | 
				
			||||||
 | 
					    GutterPartList.AssignItems(FCurGutterPartList);
 | 
				
			||||||
 | 
					    GutterRightPartList.AssignItems(FCurGutterRightPartList);
 | 
				
			||||||
  end;
 | 
					  end;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -5468,9 +5468,14 @@ resourcestring
 | 
				
			|||||||
    +'not be deleted because it is not owned by %s.';
 | 
					    +'not be deleted because it is not owned by %s.';
 | 
				
			||||||
  lisFilter3 = 'Filter: %s';
 | 
					  lisFilter3 = 'Filter: %s';
 | 
				
			||||||
  lisFileExtensionOfPrograms = 'File extension of programs';
 | 
					  lisFileExtensionOfPrograms = 'File extension of programs';
 | 
				
			||||||
  lisEveryNThLineNumber = 'Every n-th line number';
 | 
					  lisEveryNThLineNumber = 'Show every n-th line number';
 | 
				
			||||||
  lisShowOverviewGutter = 'Show overview gutter';
 | 
					  lisShowOverviewGutter = 'Show overview gutter';
 | 
				
			||||||
  lisTopInfoView = 'Show Class/Procedure hint';
 | 
					  lisTopInfoView = 'Show Class/Procedure hint';
 | 
				
			||||||
 | 
					  lisLeftGutter = 'Left Gutter';
 | 
				
			||||||
 | 
					  lisRightGutter = 'Right Gutter';
 | 
				
			||||||
 | 
					  lisGutterPartVisible = 'Visible';
 | 
				
			||||||
 | 
					  lisGutterPartWidth = 'Width';
 | 
				
			||||||
 | 
					  lisGutterPartMargin = 'Margin';
 | 
				
			||||||
  lisLink = 'Link:';
 | 
					  lisLink = 'Link:';
 | 
				
			||||||
  lisShort = 'Short:';
 | 
					  lisShort = 'Short:';
 | 
				
			||||||
  lisInsertUrlTag = 'Insert url tag';
 | 
					  lisInsertUrlTag = 'Insert url tag';
 | 
				
			||||||
@ -6441,6 +6446,10 @@ resourcestring
 | 
				
			|||||||
    +'You may want to rebuild the IDE with the packages installed. After the '
 | 
					    +'You may want to rebuild the IDE with the packages installed. After the '
 | 
				
			||||||
    +'rebuild, the debugger backend can be changed in the menu: Tools -> '
 | 
					    +'rebuild, the debugger backend can be changed in the menu: Tools -> '
 | 
				
			||||||
    +'Options.';
 | 
					    +'Options.';
 | 
				
			||||||
 | 
					  optDispGutterMarks = 'Marks';
 | 
				
			||||||
 | 
					  optDispGutterChanges = 'Changes';
 | 
				
			||||||
 | 
					  optDispGutterSeparator = 'Separator';
 | 
				
			||||||
 | 
					  optDispGutterFolding = 'Folding';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
implementation
 | 
					implementation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -11983,12 +11983,12 @@ begin
 | 
				
			|||||||
  ActEdit:=ActiveEditor;
 | 
					  ActEdit:=ActiveEditor;
 | 
				
			||||||
  if ActEdit = nil then exit;
 | 
					  if ActEdit = nil then exit;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  MenuItem.Checked := not EditorOpts.ShowLineNumbers;
 | 
					  MenuItem.Checked := not EditorOpts.GutterPartLine.Visible;
 | 
				
			||||||
  ShowLineNumbers:=MenuItem.Checked;
 | 
					  ShowLineNumbers:=MenuItem.Checked;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  for i:=0 to SourceEditorCount-1 do
 | 
					  for i:=0 to SourceEditorCount-1 do
 | 
				
			||||||
    SourceEditors[i].EditorComponent.Gutter.LineNumberPart.Visible := ShowLineNumbers;
 | 
					    SourceEditors[i].EditorComponent.Gutter.LineNumberPart.Visible := ShowLineNumbers;
 | 
				
			||||||
  EditorOpts.ShowLineNumbers := ShowLineNumbers;
 | 
					  EditorOpts.GutterPartLine.Visible := ShowLineNumbers;
 | 
				
			||||||
  EditorOpts.Save;
 | 
					  EditorOpts.Save;
 | 
				
			||||||
end;
 | 
					end;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user