On 04/06/2010 15:59, ik wrote:
<http://ik.homelinux.org/>

        The implementation of TSynEdit is to run across all of the
        ASCII table (0..255) and act only by this. And that's a
        logical bug imho.


    You speak of the SynHighlighter, or the actual SynEdit?


Yes I am.
This was an either or question :)  But I take it "the highlighter"


    Most of the highlighters are old, and haven't had much
    maintenance, so they do what was right 10 years ago....


It seems that the only maintained version of syntax highlight is the Pascal version.
Out of the languages yes => because it is used by the IDE

The LFM highlighter should be ok too.
Diff highlighter is new, but again, the relevant tokens are inside the ascii range.. (and it only supports a subset of diff styles anyway)

I have no idea how xml or html react to the full utf8 range => I haven't looked at them, except for adding a rough folding support.

The overall thing is, that 99% of the work on SynEdit applied to the usage inside the IDE. SynEdit as a component for user-app (and that does include all the highlighters) has not yet been much looked after.



    Pascal-Highlighter, can resolve to the trick of treading text of
    ascii. All pascal relevant keywords are limited to latin chars =>
    and they are the same in Ascii/Ansi or utf8.


On Delphi.NET they also allow multibyte names such as:

procedure פרוצדורה(const מחרוזת : String); ...

Ok, but Lazarus deals with FPC => and FPC doesn't do that yet.
And even then => only thing it needs to do, is to make sure it treads them as a single word.

    If you source contains other chars (multy-byte utf8) in places
    where this is allowed, the pascal highlighting will continue to work.


There is a need to also add Bi-Directional support for multi-byte support. I want to add it when I'll have some time for it.
multi-byte as in what?

I know there is multy-byte ascii => but synedit uses utf8.
Well in principal it would be nice to support different encodings. But that would require LCL support, because as long as all Keypresses come in utf8.....

bidi:
Nice => but make sure you keep it modular.

I am in the process (long time prospect) to rip that whole one big single class into pieces. => So try not to put new stuff into the main class.

Martin
--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to