2007-10-31 22:40:34 +00:00
|
|
|
|
// -*- C++ -*-
|
2007-11-08 06:05:19 +00:00
|
|
|
|
/**
|
|
|
|
|
* \file strfwd.h
|
|
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
|
*
|
|
|
|
|
* \author Andr<EFBFBD> P<EFBFBD>nitz
|
|
|
|
|
* \author Enrico Forestieri
|
|
|
|
|
*
|
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
|
*/
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
|
|
|
|
#ifndef STRFWD_H
|
|
|
|
|
#define STRFWD_H
|
|
|
|
|
|
|
|
|
|
#ifdef USE_WCHAR_T
|
|
|
|
|
|
|
|
|
|
// Prefer this if possible because GNU libstdc++ has usable
|
|
|
|
|
// std::ctype<wchar_t> locale facets but not
|
|
|
|
|
// std::ctype<boost::uint32_t>. gcc older than 3.4 is also missing
|
|
|
|
|
// usable std::char_traits<boost::uint32_t>.
|
|
|
|
|
namespace lyx { typedef wchar_t char_type; }
|
|
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
|
|
#include <boost/cstdint.hpp>
|
2007-10-31 23:41:22 +00:00
|
|
|
|
namespace lyx { typedef boost::uint32_t char_type; }
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
2007-11-08 06:05:19 +00:00
|
|
|
|
#include<iosfwd>
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
|
namespace lyx {
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
2007-11-08 06:05:19 +00:00
|
|
|
|
/// String type for storing the main text in UCS4 encoding
|
|
|
|
|
typedef std::basic_string<char_type> docstring;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
|
/// Base class for UCS4 input streams
|
2007-11-08 06:05:19 +00:00
|
|
|
|
typedef std::basic_istream<char_type> idocstream;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
|
/// Base class for UCS4 output streams
|
2007-11-08 06:05:19 +00:00
|
|
|
|
typedef std::basic_ostream<char_type> odocstream;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
2007-11-08 06:05:19 +00:00
|
|
|
|
#if ! defined(USE_WCHAR_T)
|
|
|
|
|
extern odocstream & operator<<(odocstream &, char);
|
|
|
|
|
#endif
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
|
|
|
|
} // namespace lyx
|
|
|
|
|
|
|
|
|
|
#endif
|