diff options
Diffstat (limited to 'src/codecs/tqtextcodec.cpp')
| -rw-r--r-- | src/codecs/tqtextcodec.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/codecs/tqtextcodec.cpp b/src/codecs/tqtextcodec.cpp index 7082c43b0..01aa6e31c 100644 --- a/src/codecs/tqtextcodec.cpp +++ b/src/codecs/tqtextcodec.cpp @@ -1154,8 +1154,8 @@ unsigned short TQTextCodec::characterFromUnicode(const TQString &str, int pos) c } /*! - Returns TRUE if the Unicode character \a ch can be fully encoded - with this codec; otherwise returns FALSE. The default + Returns true if the Unicode character \a ch can be fully encoded + with this codec; otherwise returns false. The default implementation tests if the result of toUnicode(fromUnicode(ch)) is the original \a ch. Subclasses may be able to improve the efficiency. @@ -1173,7 +1173,7 @@ bool TQTextCodec::canEncode( TQChar ch ) const bool TQTextCodec::canEncode( const TQString& s ) const { if ( s.isEmpty() ) - return TRUE; + return true; return toUnicode(fromUnicode(s)) == s; } @@ -1315,7 +1315,7 @@ public: char line[maxlen]; char esc='\\'; char comm='%'; - bool incmap = FALSE; + bool incmap = false; while (iod->readLine(line,maxlen) > 0) { if (0==tqstrnicmp(line,"<code_set_name>",15)) n = line+15; @@ -1334,7 +1334,7 @@ public: if (!to_unicode) { to_unicode = new ushort[256]; } - incmap = TRUE; + incmap = true; } else if (0==tqstrnicmp(line,"END CHARMAP",11)) break; else if (incmap) { @@ -2380,7 +2380,7 @@ bool TQSimpleTextCodec::canEncode( TQChar ch ) const unsigned short u = ch.unicode(); unsigned char* rmp = reverseMap->data(); int rmsize = (int) reverseMap->size(); - return u < 128 ? TRUE : (( u < rmsize ) ? (*(rmp+u) != 0) : FALSE ); + return u < 128 ? true : (( u < rmsize ) ? (*(rmp+u) != 0) : false ); } const char* TQSimpleTextCodec::name() const @@ -2615,7 +2615,7 @@ TQString TQLatin15Codec::toUnicode(const char* chars, int len) const } static inline unsigned char -latin15CharFromUnicode( unsigned short uc, bool replacement = TRUE ) +latin15CharFromUnicode( unsigned short uc, bool replacement = true ) { uchar c; if ( uc < 0x0100 ) { @@ -2678,7 +2678,7 @@ latin15CharFromUnicode( unsigned short uc, bool replacement = TRUE ) void TQLatin15Codec::fromUnicode( const TQChar *in, unsigned short *out, int length ) const { while ( length-- ) { - *out = latin15CharFromUnicode( in->unicode(), FALSE ); + *out = latin15CharFromUnicode( in->unicode(), false ); ++in; ++out; } @@ -2704,7 +2704,7 @@ TQCString TQLatin15Codec::fromUnicode(const TQString& uc, int& len ) const unsigned short TQLatin15Codec::characterFromUnicode(const TQString &str, int pos) const { - return latin15CharFromUnicode( str.unicode()[pos].unicode(), FALSE ); + return latin15CharFromUnicode( str.unicode()[pos].unicode(), false ); } |
