Re: [Lazarus] Define Symbols in SynEdit

2009-02-11 Thread Martin Friebe
saeka wrote:
> Hello, developers.
>
> SynEdit.pp source code has a lot of 'SYN_MBCSSUPPORT','SYN_LAZARUS'.
>
> It seems to be SynEdit was compiled by defines SYN_MBCSSUPPORT originaly
> but now, that is undefined by SYN_LAZARUS. (in SynEdit.inc)
>
> SYN_MBCSSUPPORT is defined by supporting MultiByteCharacterSystem on
> FarEastAsian Windows, but MBCS is not equal to UNICODE.
>
> Now, SynEdit in Lazarus is working at UNICODE, ( Its very nice for us.)
> and SynEdit in Lazarus is highly customized for Lazarus and FreePascal.
>
> I have created patch on released version 0.9.16-0.9.24 to Japanese Community
> in which enabling SYN_MBCSSUPPORT.
> (http://sourceforge.jp/projects/freepascaljp/releases/?package_id=5278)
> Now, that is not smart way after 0.9.26, I think. 
> In Unicode, no additional defines needed in handling character.
>
> How about delete symbols, and delete IFDEF codings , if it will not be
> used in the future ?
> (SYN_MBCSSUPPORT, SYN_LAZARUS, and defines about delphi version)
>   
That has to be decided on a case by case base. (per symbol).

A start has been made, and some of the {$IFDEF SYNLAZARUS} have been
removed. More to follow. It is done while work is in progress. Removing
all at once has a higher risk of accidental removing the wrong block
(especially with "ifNdef"), and sometime those still compile, and bugs
would be introduced.

For other ifdef it has to be seen, how badly broken the alternative code
is, and if it is easy to support it or better to trash it. There seems
no need to rush. Only issue is that if you search for reference to some
method, it returns matches in the dead code too.

For making modifications or providing patches, you only need to look at
supporting the SYNLAZARUS version. You can completely ignore the none
SYNLAZARUS code. As far as I am aware much of it does not compile anyway.
You should keep IFDEFs that relate to the compiler used, such as
"{$IFDEF f...@{$endif}methodname". Also keep IFDEFs for compiler
versions. Some of those may have lack of testing, but their presence
will make fixing easier, if bugs a reported by people using older/other
versions of fpc/delphi.


As for 0.9.26 and Japanese (or any other Language). The primary support
is and will be on UTF8.
- UTF8 support for wide char display has just been fixed, and as of now
can be build from SVN. As of tomorrow 12th Feb it will be in the daily
snapshot too.
- Support for MBCS is currently not maintained. If you wish to keep it,
patches will be welcome.


Best Regards
Martin


___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Define Symbols in SynEdit

2009-02-11 Thread Mattias Gärtner
Zitat von saeka :

> Hello, developers.
>
> SynEdit.pp source code has a lot of 'SYN_MBCSSUPPORT','SYN_LAZARUS'.
>
> It seems to be SynEdit was compiled by defines SYN_MBCSSUPPORT originaly
> but now, that is undefined by SYN_LAZARUS.$B!!(B(in SynEdit.inc)
>
> SYN_MBCSSUPPORT is defined by supporting MultiByteCharacterSystem on
> FarEastAsian Windows, but MBCS is not equal to UNICODE.
>
> Now, SynEdit in Lazarus is working at UNICODE, ( Its very nice for us.)
> and SynEdit in Lazarus is highly customized for Lazarus and FreePascal.
>
> I have created patch on released version 0.9.16-0.9.24 to Japanese Community
> in which enabling SYN_MBCSSUPPORT.
> (http://sourceforge.jp/projects/freepascaljp/releases/?package_id=5278)
> Now, that is not smart way after 0.9.26, I think. 
> In Unicode, no additional defines needed in handling character.
>
> How about delete symbols, and delete IFDEF codings , if it will not be
> used in the future ?
> (SYN_MBCSSUPPORT, SYN_LAZARUS, and defines about delphi version)

They were kept to eventually merge the changes to synedit.
But the differences became too big, so it makes no sense anymore to use
syn_lazarus.
They can be removed. Martin already started to clean up the code.


Mattias

___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Define Symbols in SynEdit

2009-02-11 Thread saeka
Hello, developers.

SynEdit.pp source code has a lot of 'SYN_MBCSSUPPORT','SYN_LAZARUS'.

It seems to be SynEdit was compiled by defines SYN_MBCSSUPPORT originaly
but now, that is undefined by SYN_LAZARUS. (in SynEdit.inc)

SYN_MBCSSUPPORT is defined by supporting MultiByteCharacterSystem on
FarEastAsian Windows, but MBCS is not equal to UNICODE.

Now, SynEdit in Lazarus is working at UNICODE, ( Its very nice for us.)
and SynEdit in Lazarus is highly customized for Lazarus and FreePascal.

I have created patch on released version 0.9.16-0.9.24 to Japanese Community
in which enabling SYN_MBCSSUPPORT.
(http://sourceforge.jp/projects/freepascaljp/releases/?package_id=5278)
Now, that is not smart way after 0.9.26, I think. 
In Unicode, no additional defines needed in handling character.

How about delete symbols, and delete IFDEF codings , if it will not be
used in the future ?
(SYN_MBCSSUPPORT, SYN_LAZARUS, and defines about delphi version)

Thanks,
Saeka
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus