blob: 9161760d85ad408e8a1da6337e8d04fde7223617 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
//========================================================================
//
// UGooString.h
//
// Unicode string
//
// Copyright 2005 Albert Astals Cid <aacid@kde.org>
//
//========================================================================
#ifndef UGooString_H
#define UGooString_H
#include "CharTypes.h"
class GooString;
class UGooString
{
public:
// Create an unicode string
UGooString(Unicode *u, int l);
// Create a unicode string from <str>.
UGooString(GooString &str);
// Copy the unicode string
UGooString(const UGooString &str);
// Create a unicode string from <str>.
UGooString(const char *str);
// Destructor.
~UGooString();
// Get length.
int getLength() const { return length; }
// Compare two strings: -1:< 0:= +1:>
int cmp(UGooString *str) const;
// get the unicode
Unicode *unicode() const { return s; }
// get the const char*
char *getCString() const;
private:
void initChar(GooString &str);
int length;
Unicode *s;
};
#endif
|