Georg Baum wrote:
Abdelrazak Younes wrote:
Am I right that all of the filetools.h API should be converted to
docstring?
If filenames with non-ASCII characters should be supported, then yes.
I think we should support that indeed.
I have started the conversion already so please tell me quick if that's
not the case.
You will probably need to add some low level system dependant support stuff,
because there is AFAIK no standard how filenames are encoded in different
platforms.
I plan to first encapsulate the conversion to/from ascii inside each of
the filetools functions. Then I will look at how boost::filesystem can
handle unicode, if at all possible...
I am tempted to convert everything even when a std::string would
suffice. For example getFormatFromContents(), should that be:
lyx::docstring const getFormatFromContents(lyx::docstring const & name);
or
std::string const getFormatFromContents(lyx::docstring const & name);
I guess the format name could stay with std::string but this would not
bring a big performance advantage. The first solution (docstring has the
advantage that it looks nicer and we won't need to convert that to
docstring if we need to display that format name somewhere.
What do you think?
Abdel.