TurboPack / SynEdit

SynEdit is a syntax highlighting edit control, not based on the Windows common controls.
216 stars 72 forks source link

value of the SYNS_FriendlyAttrKey constant #240

Closed Lajos-Juhasz closed 1 year ago

Lajos-Juhasz commented 1 year ago

I'm using the FriendlyName of the attribute of highlighters to create an options dialog. As far as I can see everywhere SynEditStrConst.SYNS_FriendlyAttrKey is used for Keyword, but the value of the constant is Key this is not descriptive enough. Could the value be changed to be Keyword?

pyscripter commented 1 year ago

For keywords SYNS_FriendlyAttrReservedWord is used. 'Key' (SYNS_FriendlyAttrKey) is used for key-value pairs as for example in INI files.

Lajos-Juhasz commented 1 year ago

Ok, I made an investigation the original code (years ago) was:

fKeyAttri := TSynHighlighterAttributes.Create(SYNS_AttrReservedWord, SYNS_FriendlyAttrReservedWord);

That is changed wrongly to:

fKeyAttri := TSynHighlighterAttributes.Create(SYNS_AttrKey, SYNS_FriendlyAttrKey);

Lajos-Juhasz commented 1 year ago

The problematic change is: https://github.com/SynEdit/SynEdit/issues/112

pyscripter commented 1 year ago

Fixed in https://github.com/pyscripter/SynEdit