FX::FXUnicodify< fastlen > Class Template Reference

#include <FXGenericTools.h>

List of all members.


Detailed Description

template<size_t fastlen = 2048>
class FX::FXUnicodify< fastlen >

Converts a UTF-8 format FX::FXString into a unicode string suitable for the host operating system.

Parameters:
fastlen How much stack space to use before resorting to the allocator
On POSIX, it is assumed that the host OS also uses UTF-8 and thus returns the FXString as-is. On Windows, if UNICODE is defined, then it converts to UTF-16 otherwise it returns the FXString as-is. In all cases the terminating null of the source FXString is preserved.

If you are converting a path which can utilise the \\?\ escape sequence to enable 32,768 character long paths, pass true for the isPath parameter to the constructor.

Example:

CreateFile(FXUnicodify<>(path, true).buffer(), ...

Public Member Functions

 FXUnicodify (bool isPath=false)
 FXUnicodify (const FXString &str, bool isPath=false)
const FXchar * buffer () const throw ()
const FXchar * buffer (const FXString &str) const throw ()
FXint length () const throw ()
FXint length (const FXString &str) const throw ()

The documentation for this class was generated from the following file:

(C) 2002-2008 Niall Douglas. Some parts (C) to assorted authors.
Generated on Fri Jun 13 21:59:41 2008 for TnFOX by doxygen v1.5.6