Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FXTextCodec.h
1 /********************************************************************************
2 * *
3 * U n i c o d e T e x t C o d e c *
4 * *
5 *********************************************************************************
6 * Copyright (C) 2002,2017 by L.Johnson & J.van der Zijp. All Rights Reserved. *
7 *********************************************************************************
8 * This library is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU Lesser General Public License as published by *
10 * the Free Software Foundation; either version 3 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This library is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU Lesser General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU Lesser General Public License *
19 * along with this program. If not, see <http://www.gnu.org/licenses/> *
20 ********************************************************************************/
21 #ifndef FXTEXTCODEC_H
22 #define FXTEXTCODEC_H
23 
24 #ifndef FXOBJECT_H
25 #include "FXObject.h"
26 #endif
27 
28 namespace FX {
29 
30 
34 class FXAPI FXTextCodec : public FXObject {
35  FXDECLARE_ABSTRACT(FXTextCodec)
36 public:
37 
40 
42  virtual FXint mb2utflen(const FXchar* src,FXint nsrc) const;
43 
45  FXint mb2utflen(const FXString& src) const;
46 
48  virtual FXint mb2utf(FXchar* dst,FXint ndst,const FXchar* src,FXint nsrc) const;
49 
51  FXint mb2utf(FXchar* dst,FXint ndst,const FXchar* src) const;
52 
54  FXint mb2utf(FXchar* dst,FXint ndst,const FXString& src) const;
55 
57  FXString mb2utf(const FXchar* src,FXint nsrc) const;
58 
60  FXString mb2utf(const FXchar* src) const;
61 
63  FXString mb2utf(const FXString& src) const;
64 
66  virtual FXint mb2wc(FXwchar& wc,const FXchar* src,FXint nsrc) const;
67 
68 
69 
71  virtual FXint utf2mblen(const FXchar* src,FXint nsrc) const;
72 
74  virtual FXint utf2mblen(const FXString& src) const;
75 
77  virtual FXint utf2mb(FXchar* dst,FXint ndst,const FXchar* src,FXint nsrc) const;
78 
80  FXint utf2mb(FXchar* dst,FXint ndst,const FXchar* src) const;
81 
83  FXint utf2mb(FXchar* dst,FXint ndst,const FXString& src) const;
84 
86  FXString utf2mb(const FXchar* src,FXint nsrc) const;
87 
89  FXString utf2mb(const FXchar* src) const;
90 
92  FXString utf2mb(const FXString& src) const;
93 
95  virtual FXint wc2mb(FXchar* dst,FXint ndst,FXwchar wc) const;
96 
97 
101  virtual FXint mibEnum() const = 0;
102 
106  virtual const FXchar* name() const = 0;
107 
112  virtual const FXchar* mimeName() const = 0;
113 
117  virtual const FXchar* const* aliases() const = 0;
118 
120  virtual ~FXTextCodec(){}
121  };
122 
123 }
124 
125 #endif

Copyright © 1997-2016 Jeroen van der Zijp