2 synedit sites

2 synedit sites
https://github.com/TurboPack/SynEdit >> compile in Berlin from getit
https://github.com/SynEdit/SynEdit >> dose not compile
2'nd seem to be the latest
in procedure TSynJavaSyn.Next;
first has
'A'..'Z', 'a'..'z', '_', '$', 'À'..'Ö', 'Ø'..'ö', 'ø'..'ÿ': IdentProc; >> OK
second has which is updated 4 month ago
'A'..'Z', 'a'..'z', '_', '$', WideChar(#$C0)..WideChar(#$D6), WideChar(#$D8)..WideChar(#$F6), WideChar(#$F8)..WideChar(#$FF):

IdentProc;
but the error is
[dcc32 Error] SynHighlighterJava.pas(877): E2011 Low bound exceeds high bound

Which is the formal site? it seem to be the second one.

https://github.com/TurboPack/SynEdit

Comments

  1. That won't work for all locales; I just posted my remark there:

    The problem in `function IsWordBreakChar(C: WideChar): Boolean;` is that the "high char" characters above 127 (#$80 and up) will be translated to unicode by the compiler. This translation depends on the locale, no matter if `HIGHCHARUNICODE` is turned on or off.

    The best solution for high-char constants is to use use *four* hexadecimal digits for these character constants to fix the Unicode code point as per suggestion by Allen Bauer in wiert.me - Delphi – HIGHCHARUNICODE directive (Delphi) – RAD Studio

    However, I do not think that listing a set of characters that can function as word-break is a good solution for `IsWordBreakChar` as with the growing number of Unicode codepoints, this list is never going to be complete.

    The opposite (testing which characters are part of a word) have a much higher chance of being stable. Such a solution could be based on the list at the .NET [Char.IsLetter Method (Char)](https://msdn.microsoft.com/en-us/library/system.char.isletter.aspx) and [Char.IsDigit Method (Char)](https://msdn.microsoft.com/en-us/library/system.char.isdigit.aspx).

    ReplyDelete
  2. Jeroen Wiert Pluimers to be specific what do you suggest
    to change the line 'A'..'Z', 'a'..'z', '_', '$', WideChar(#$C0)..WideChar(#$D6), WideChar(#$D8)..WideChar(#$F6), WideChar(#$F8)..WideChar(#$FF):
    to what or leave it as it was ?
    'A'..'Z', 'a'..'z', '_', '$', 'À'..'Ö', 'Ø'..'ö', 'ø'..'ÿ' ?
    WideChar(#$C0) wiil be WideChar(#$00C0) ?

    ReplyDelete
  3. shlomo abuisak that depends on which non-Unicode character set is used and which order the non-Unicode and Unicode codepoints have.

    ReplyDelete

Post a Comment