[fpc-devel] Very simple questions about Widestring on Linux
Léo Willian Kölln
leokolln at gmail.com
Tue Mar 17 22:51:57 CET 2009
I´m Working on a project of a program that will run on Windows and
Linux. The binary to the windows will be compiled using Delphi, and
for Linux using FPC. (This is not the question)
All the strings on the code are Widestrings (yes!).
On Windows i have specific functions to call using Widestrings
(functions with the postfix W).
No problems so far, but when i want to implement my functions using
the RTL, i just see arguments, parameters and returns of String.
As far i´ve read, they are aways Ansistrings, i´m right? Or i need
inform the compiler of this? (Q1)
To convert to Widestrings, i need include the unit "cwstring".
Where? Only at the main unit, or on every unit where an RTL function
is called? (Q2)
The conversion is transparent, in both ways? (Q3)
And for a stupid question:
If my host (linux) machine is using, for example, an ISO8859-1 coding
(file names, etc...) or even a more exotic one.
The conversion will be transparent, in both ways? (Q4)
The answers will help a lot, maybe a very objective Wiki entry about
this will help a lot of people, because i read many threads on the
list, a lot of text on the Wiki but all i find is discussion about the
types of string, what will be better if default, etc (all discussions
are valids, but is not what i was looking for).
Thanks in advance and sorry the bad English!
Léo
More information about the fpc-devel
mailing list