Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members
|
00001 /******************************************************************************** 00002 * * 00003 * U T F - 3 2 T e x t C o d e c * 00004 * * 00005 ********************************************************************************* 00006 * Copyright (C) 2002,2006 by L.Johnson & J.van der Zijp. All Rights Reserved. * 00007 ********************************************************************************* 00008 * This library is free software; you can redistribute it and/or * 00009 * modify it under the terms of the GNU Lesser General Public * 00010 * License as published by the Free Software Foundation; either * 00011 * version 2.1 of the License, or (at your option) any later version. * 00012 * * 00013 * This library is distributed in the hope that it will be useful, * 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00016 * Lesser General Public License for more details. * 00017 * * 00018 * You should have received a copy of the GNU Lesser General Public * 00019 * License along with this library; if not, write to the Free Software * 00020 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * 00021 ********************************************************************************* 00022 * $Id: FXUTF32Codec.h,v 1.10 2006/01/22 17:58:12 fox Exp $ * 00023 ********************************************************************************/ 00024 #ifndef FXUTF32CODEC_H 00025 #define FXUTF32CODEC_H 00026 00027 #ifndef FXTEXTCODEC_H 00028 #include "FXTextCodec.h" 00029 #endif 00030 00031 00032 namespace FX { 00033 00034 00035 /// Codec for UTF-32BE 00036 class FXAPI FXUTF32BECodec : public FXTextCodec { 00037 FXDECLARE(FXUTF32BECodec) 00038 public: 00039 FXUTF32BECodec(){} 00040 virtual FXint mb2wc(FXwchar& wc,const FXchar* src,FXint nsrc) const; 00041 virtual FXint wc2mb(FXchar* dst,FXint ndst,FXwchar wc) const; 00042 virtual const FXchar* name() const; 00043 virtual const FXchar* mimeName() const; 00044 virtual FXint mibEnum() const; 00045 virtual const FXchar* const* aliases() const; 00046 virtual ~FXUTF32BECodec(){} 00047 }; 00048 00049 00050 /// Codec for UTF-32LE 00051 class FXAPI FXUTF32LECodec : public FXTextCodec { 00052 FXDECLARE(FXUTF32LECodec) 00053 public: 00054 FXUTF32LECodec(){} 00055 virtual FXint mb2wc(FXwchar& wc,const FXchar* src,FXint nsrc) const; 00056 virtual FXint wc2mb(FXchar* dst,FXint ndst,FXwchar wc) const; 00057 virtual const FXchar* name() const; 00058 virtual const FXchar* mimeName() const; 00059 virtual FXint mibEnum() const; 00060 virtual const FXchar* const* aliases() const; 00061 virtual ~FXUTF32LECodec(){} 00062 }; 00063 00064 00065 /// Codec for UTF-32 00066 class FXAPI FXUTF32Codec : public FXTextCodec { 00067 FXDECLARE(FXUTF32Codec) 00068 public: 00069 FXUTF32Codec(){} 00070 virtual FXint mb2wc(FXwchar& wc,const FXchar* src,FXint nsrc) const; 00071 virtual FXint mb2utflen(const FXchar* src,FXint nsrc) const; 00072 virtual FXint mb2utf(FXchar* dst,FXint ndst,const FXchar* src,FXint nsrc) const; 00073 virtual FXint wc2mb(FXchar* dst,FXint ndst,FXwchar wc) const; 00074 virtual FXint utf2mblen(const FXchar* src,FXint nsrc) const; 00075 virtual FXint utf2mb(FXchar* dst,FXint ndst,const FXchar* src,FXint nsrc) const; 00076 virtual const FXchar* name() const; 00077 virtual const FXchar* mimeName() const; 00078 virtual FXint mibEnum() const; 00079 virtual const FXchar* const* aliases() const; 00080 virtual ~FXUTF32Codec(){} 00081 }; 00082 00083 00084 } 00085 00086 #endif 00087
Copyright © 1997-2005 Jeroen van der Zijp |