Recent

Author Topic: Other SynEdit issues  (Read 338 times)

aducom

  • Full Member
  • ***
  • Posts: 122
    • http://www.aducom.com
Other SynEdit issues
« on: May 26, 2019, 01:13:26 pm »
I expect that version 2.0 has some changes regarding synedit as I suddenly realized that I was missing line numbers, the change mark. I also noticed that there is a gutter parts property now (perhaps it was always there but never need to use it) which had an instance of zero causing the issue I reported before. Now adding a gutter part will add a 'SynGutterLineNumber' which can be modified to appear as usual. But I miss the options to add other types of gutter parts like the coloring of changes, the bullet, and bookmarks. I might be overlooking things. Are there any docs I can find regarding this?

Apparently converting/migrating my application towards 2.0.2 and changing to the 64 bit version might have caused issues. In the code of syngutter I can find the missing gutter parts:
    Function LineNumberPart(Index: Integer = 0): TSynGutterLineNumber;
    Function CodeFoldPart(Index: Integer = 0): TSynGutterCodeFolding;
    Function ChangesPart(Index: Integer = 0): TSynGutterChanges;
    Function MarksPart(Index: Integer = 0): TSynGutterMarks;
    Function SeparatorPart(Index: Integer = 0): TSynGutterSeparator;
    Function LineOverviewPart(Index: Integer = 0): TSynGutterLineOverview;   

There is even some 'default'. But for some reason, there is no default gutter and I'm not able to assign other types.

Ok, I created a new application and adding a synedit does add the parts automatically. So something went wrong porting to the new version. I can try to fix by patching the form, however, I still wonder how to add a part other then linenumber.
« Last Edit: May 26, 2019, 01:32:11 pm by aducom »

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 5706
    • wiki
Re: Other SynEdit issues
« Reply #1 on: May 29, 2019, 12:23:07 am »
Gutter.Parts existed since Lazarus version 1.0 (or maybe before, the oldest I have is 1.0 fixes branch.

From what version of Lazarus did you upgrade?

If loading of gutter parts failed, then maybe the error is somewhere else, and it would be good to find out what it is. (Do you still have the old lfm file (and pas unit), that do not load, and can you share it?)

It the gutter part editor, below the "add" button, is a dropdown. You can select what parts to add.