Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-23 Thread Michael Van Canneyt
On Tue, 23 Mar 2010, Graeme Geldenhuys wrote: Marco van de Voort het geskryf: For the same reason why the Unix rtl is not a Windows emulation. We are writing a multiplatform compiler and rtl, not an emulation. If only that was true... I can highlight a few places where Windows emulation is

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-23 Thread Graeme Geldenhuys
Marco van de Voort het geskryf: > > For the same reason why the Unix rtl is not a Windows emulation. We are > writing a multiplatform compiler and rtl, not an emulation. If only that was true... I can highlight a few places where Windows emulation is used rather that pure multi-platform implement

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-21 Thread dmitry boyarintsev
On Sun, Mar 21, 2010 at 7:53 PM, Jonas Maebe wrote: > On Mac it's utf-8, not utf-16. At least, not as "sequence of bytes", see test1.pas of the ufiles package. thanks, dmitry ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepa

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-21 Thread Jonas Maebe
On 21 Mar 2010, at 17:29, Martin Schreiber wrote: > On Windows and Mac utf-16 is then native filename encoding On Mac it's utf-8, not utf-16. Jonas ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-21 Thread Marco van de Voort
In our previous episode, Martin Schreiber said: > > Yes, it does so and i see no problems here. The package also converts > > UTF-16 to ansi encoding for Win9x. > > Converting string from UTF16 to UTF8 (or any other encoding) is not > > much time penalty comparing to the time of the file operation

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-21 Thread Martin Schreiber
On Sunday 21 March 2010 16:17:49 dmitry boyarintsev wrote: > On Tue, Mar 21, 2010 at 2:01 PM, Marco van de Voort > > wrote: > > I'll reiterate my opinion that first a decision about what the working > > stringtype of the RTL will be. IMHO there is no d

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-21 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > On Tue, Mar 21, 2010 at 2:01 PM, Marco van de Voort > wrote: > > I'll reiterate my opinion that first a decision about what the working > > stringtype of the RTL will be. > > IMHO there is no decent

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-21 Thread dmitry boyarintsev
On Tue, Mar 21, 2010 at 2:01 PM, Marco van de Voort wrote: > I'll reiterate my opinion that first a decision about what the working > stringtype of the RTL will be. > IMHO there is no decent solution till there is a real utf-8 type (read > cpnewstr)

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-16 Thread dmitry boyarintsev
Any hints about the package? http://bugs.freepascal.org/view.php?id=15795 thanks, dmitry ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-09 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > > The patch has been updated: http://bugs.freepascal.org/view.php?id=15795 > (is it possible to allow the reporter to delete its files in FPC bug tracker?) > > The library is now RTL "encoding" independent. Actually it's > configurable, so, if R

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-09 Thread dmitry boyarintsev
On Tue, Mar 9, 2010 at 1:49 PM, Marco van de Voort wrote: >> The library is now RTL "encoding" independent. Actually it's >> configurable, so, if RTL string encoding changes, only a 2-3 lines in >> the library should be changed. > > I don't know, but I can delete anything but the most recent if yo

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-03-09 Thread dmitry boyarintsev
Hello, The patch has been updated: http://bugs.freepascal.org/view.php?id=15795 (is it possible to allow the reporter to delete its files in FPC bug tracker?) The library is now RTL "encoding" independent. Actually it's configurable, so, if RTL string encoding changes, only a 2-3 lines in the lib

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-18 Thread Florian Klaempfl
Felipe Monteiro de Carvalho schrieb: > 2010/2/17 Flávio Etrusco : >> I've read somewhere that Windows ANSI functions support utf-8? >> (despite the name) > > lol!!! > > You read from someone deeply missinformed =D Switch the console to a font supporting unicode, execute chcp 65001 and you can ou

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-18 Thread Michael Schnell
On 02/17/2010 06:52 PM, Martin Schreiber wrote: > Aren't filenames on Linux an array of bytes without any encoding by > definition? > Right. But how to visualize them ? -Michael ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.f

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Felipe Monteiro de Carvalho
2010/2/17 Flávio Etrusco : > I've read somewhere that Windows ANSI functions support utf-8? > (despite the name) lol!!! You read from someone deeply missinformed =D -- Felipe Monteiro de Carvalho ___ fpc-devel maillist - fpc-devel@lists.freepascal.o

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Flávio Etrusco
On Wed, Feb 17, 2010 at 4:10 AM, dmitry boyarintsev wrote: > Reported: http://bugs.freepascal.org/view.php?id=15795 > > It's up to FPC team to accept or reject the package. > > thanks, > dmitry I've read somewhere that Windows ANSI functions support utf-8? (despite the name) -Flávio

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Marco van de Voort
In our previous episode, Martin Schreiber said: > On Wednesday 17 February 2010 09:15:53 Marco van de Voort wrote: > > > > Reject as far as I'm concerned. I'd like to see the RTL being in the system > > encoding. (IOW UTF-8 on at least FreeBSD/Linux) using an abstracted > > RTLString. > > > Aren't

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Martin Schreiber
On Wednesday 17 February 2010 09:15:53 Marco van de Voort wrote: > > Reject as far as I'm concerned. I'd like to see the RTL being in the system > encoding. (IOW UTF-8 on at least FreeBSD/Linux) using an abstracted > RTLString. > Aren't filenames on Linux an array of bytes without any encoding by

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > > RTLString. > > > > This sets a precedent. > > Could you please resolve the issue with "won't be accepted" (or no > changes required)? It's not my decision alone. The whole problem with this unicode string is that there is no definitive roadmap

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Marco van de Voort
In our previous episode, Mattias Gaertner said: > > > > Could you please resolve the issue with "won't be accepted" (or no > > changes required)? > > > > The implementation is not only about RTL encoding, but system > > environment as well, since it depends upon Windows *W function to be > > avai

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread dmitry boyarintsev
Thanks Mattias, i'll do proper changes to file name comparison functions. thanks, dmitry ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Mattias Gaertner
On Wed, 17 Feb 2010 12:34:35 +0300 dmitry boyarintsev wrote: > On Wed, Feb 17, 2010 at 11:15 AM, Marco van de Voort wrote: > > Reject as far as I'm concerned. I'd like to see the RTL being in the system > > encoding. (IOW UTF-8 on at least FreeBSD/Linux) using an abstracted > > RTLString. > > >

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread dmitry boyarintsev
On Wed, Feb 17, 2010 at 11:15 AM, Marco van de Voort wrote: > Reject as far as I'm concerned. I'd like to see the RTL being in the system > encoding. (IOW UTF-8 on at least FreeBSD/Linux) using an abstracted > RTLString. > > This sets a precedent. Could you please resolve the issue with "won't be

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Vincent Snijders
dmitry boyarintsev schreef: On Wed, Feb 17, 2010 at 11:15 AM, Marco van de Voort wrote: Reject as far as I'm concerned. I'd like to see the RTL being in the system encoding. (IOW UTF-8 on at least FreeBSD/Linux) using an abstracted RTLString. Vincent, is there a place in CCR for the run-time

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Michael Schnell
No comment on the idea of converting dynamically typed string constants at the first touch in realtime ? -Michael ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread dmitry boyarintsev
On Wed, Feb 17, 2010 at 11:15 AM, Marco van de Voort wrote: > Reject as far as I'm concerned. I'd like to see the RTL being in the system > encoding. (IOW UTF-8 on at least FreeBSD/Linux) using an abstracted > RTLString. Vincent, is there a place in CCR for the run-time package? thanks, dmitry _

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-17 Thread Marco van de Voort
In our previous episode, Vincent Snijders said: > dmitry boyarintsev schreef: > > Reported: http://bugs.freepascal.org/view.php?id=15795 > > > > It's up to FPC team to accept or reject the package. > > Thanks, I will monitor the issue to see the outcome. Reject as far as I'm concerned. I'd like

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-16 Thread Vincent Snijders
dmitry boyarintsev schreef: Reported: http://bugs.freepascal.org/view.php?id=15795 It's up to FPC team to accept or reject the package. Thanks, I will monitor the issue to see the outcome. Vincent ___ fpc-devel maillist - fpc-devel@lists.freepasca

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-16 Thread dmitry boyarintsev
Reported: http://bugs.freepascal.org/view.php?id=15795 It's up to FPC team to accept or reject the package. thanks, dmitry ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Vincent Snijders
Marco van de Voort schreef: That is not my call, but I won't commit it. Because all this stuff must be maintained when real solutions come later. if Lazarus needs a quick fix, they should keep it in own SVN. Or use the units from msegui or use the units from tiopf or use the units from (any

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > On Mon, Feb 1, 2010 at 3:20 PM, Marco van de Voort wrote: > > More importantly, the stuff in the FCL depends on the RTL, so stuffing in > > the FCL is useless since it would need primitives in the RTL to operate on. > > Does it mean, if i provid

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread dmitry boyarintsev
On Mon, Feb 1, 2010 at 3:20 PM, Marco van de Voort wrote: > More importantly, the stuff in the FCL depends on the RTL, so stuffing in > the FCL is useless since it would need primitives in the RTL to operate on. Does it mean, if i provide a FCL package with: unit UnicodeFileUtils; function Fi

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > > in fpGUI project (fpg_utils.pas unit), having functions like > > fpgFileExists(), fpgFindFirst(), fpgFindNext() etc. Use them instead of the > > standard RTL functions, and they will try and handle Unicode file system > > access correctly on eac

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread dmitry boyarintsev
On Mon, Feb 1, 2010 at 11:09 AM, Graeme Geldenhuys wrote: > Alternatively you can introduce helper RTL functions. We have done similar > in fpGUI project (fpg_utils.pas unit), having functions like > fpgFileExists(), fpgFindFirst(), fpgFindNext() etc. Use them instead of the > standard RTL functio

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Michael Schnell
On 02/01/2010 12:26 PM, Marco van de Voort wrote: > Daniel touches the main problem. The string type is compiletime, while the > standard encoding is runtime. > I do see this (that is why I said "If possible", even if I have no idea about what impact this has. Maybe it could be possible to fin

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, Michael Schnell said: > > I feel that the runtime performance overhead necessary for doing the RTL > with dynamically encoded strings is not too big, provided the RTL itself > does not force automatic conversions (e.g. by inappropriately encoded > string constants) . Dani

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Michael Schnell
On 02/01/2010 10:53 AM, Marco van de Voort wrote: > It makes sense to take the > encoding closest to the system, to at least allow minimal conversion > scenarios. > Of course ! If the RTL is done with dynamically encoded strings you would need to take care that anything string value that neith

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Daniël Mantione
Op Mon, 1 Feb 2010, schreef Marco van de Voort: In our previous episode, Dani?l Mantione said: Some commercial unices are also using utf-16 afaik, since they haven't switched their TTY to UTF-8 yet. To be investigated. I lean towards RTLString=utf8string; and RTLString=unicodestring on the r

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, Michael Schnell said: > Right, But exactly this seems to ask for dynamically encoded strings > allowing to do the user code as agnostic of the system encoding as > possible while automatic conversions are made whenever necessary, but > avoided whenever possible. Both strin

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Michael Schnell
On 02/01/2010 10:27 AM, Marco van de Voort wrote: > We are not Codegear, for which everything but Windows is an afterthought. > Right, But exactly this seems to ask for dynamically encoded strings allowing to do the user code as agnostic of the system encoding as possible while automatic conver

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, Dani?l Mantione said: > > Some commercial unices are also using utf-16 afaik, since they haven't > > switched their TTY to UTF-8 yet. To be investigated. > > > > I lean towards RTLString=utf8string; and RTLString=unicodestring on the > > respective platforms, and then expre

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Daniël Mantione
Op Mon, 1 Feb 2010, schreef Marco van de Voort: In our previous episode, Michael Schnell said: D2009/d2010 are still windows only. Do you think there is any general problem in using D2009 strings with dynamic encoding with Unix ? On the first view I don't see one. In general I prefer to u

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, Michael Schnell said: > > D2009/d2010 are still windows only. > > > Do you think there is any general problem in using D2009 strings with > dynamic encoding with Unix ? On the first view I don't see one. In general I prefer to use each platform using its native encoding

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Michael Schnell
On 02/01/2010 09:46 AM, Marco van de Voort wrote: > D2009/d2010 are still windows only. > Do you think there is any general problem in using D2009 strings with dynamic encoding with Unix ? On the first view I don't see one. -Michael ___ fpc-devel mail

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > Now, i see, the technical solution is not easy. > > > The point is more or less to come up with some logical system, not just > > random additions when something is missing. > > FPC will be forced to catch-up with D2009, anyway. Yes, but D2009/

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread dmitry boyarintsev
On Mon, Feb 1, 2010 at 11:31 AM, Marco van de Voort wrote: > Which requires libc, and *nix supports UTF-8 directly. Now, i see, the technical solution is not easy. > The point is more or less to come up with some logical system, not just > random additions when something is missing. FPC will be

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > > What would you do on Unix? Any solution must be platform-wide. > > I'm not talking about removing Ansi functions. I'm talking about the > possibility of adding Unicode function equivalents. > For Unix unicode functions would simply call Ansi f

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread dmitry boyarintsev
On Mon, Feb 1, 2010 at 11:01 AM, Marco van de Voort wrote: > What would you do on Unix? Any solution must be platform-wide. I'm not talking about removing Ansi functions. I'm talking about the possibility of adding Unicode function equivalents. For Unix unicode functions would simply call Ansi fu

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Graeme Geldenhuys
dmitry boyarintsev wrote: > > Would it be possible to fix the problem in RTL? by adding > UnicodeString (WideString) version of file operation functions? Until the cpstrnew branch in FPC is complete, I guess the answer is No. Alternatively you can introduce helper RTL functions. We have done si

Re: [fpc-devel] RTL and Unicode filenames operations.

2010-02-01 Thread Marco van de Voort
In our previous episode, dmitry boyarintsev said: > Any hints on these bugs? > http://bugs.freepascal.org/view.php?id=12923 > http://bugs.freepascal.org/view.php?id=15642 // patch proposed to > workaround RTL limitation in LCL > > This is mostly concern of Windows OS. Moders Unix doesn't have the

[fpc-devel] RTL and Unicode filenames operations.

2010-01-31 Thread dmitry boyarintsev
Hello, FPC developers Any hints on these bugs? http://bugs.freepascal.org/view.php?id=12923 http://bugs.freepascal.org/view.php?id=15642 // patch proposed to workaround RTL limitation in LCL This is mostly concern of Windows OS. Moders Unix doesn't have the problem, usually having UTF8 as their's