summaryrefslogtreecommitdiffstats
path: root/lib/kotext/kohyphen/kohyphen.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/kotext/kohyphen/kohyphen.cpp')
-rw-r--r--lib/kotext/kohyphen/kohyphen.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/kotext/kohyphen/kohyphen.cpp b/lib/kotext/kohyphen/kohyphen.cpp
index 29d13c37b..d8a0374e8 100644
--- a/lib/kotext/kohyphen/kohyphen.cpp
+++ b/lib/kotext/kohyphen/kohyphen.cpp
@@ -71,7 +71,7 @@ KoHyphenator::KoHyphenator()
for (uint i = 0; i < records.count(); i++)
{
TQDomNamedNodeMap attr = records.item(i).attributes();
- if (attr.tqcontains("lang") && attr.tqcontains("encoding")) {
+ if (attr.contains("lang") && attr.contains("encoding")) {
TQString lang = attr.namedItem("lang").nodeValue();
TQString encoding = attr.namedItem("encoding").nodeValue();
#ifdef DEBUG_HYPHENATOR
@@ -171,18 +171,18 @@ HyphenDict *KoHyphenator::dict(const TQString &_lang) const
{
TQString lang( _lang );
//only load dictionary when encoding info is present
- if (encodings.tqfind(lang) == encodings.end())
+ if (encodings.find(lang) == encodings.end())
{
- int underscore = lang.tqfind('_');
+ int underscore = lang.find('_');
if ( underscore > -1 ) {
lang.truncate( underscore );
- if (encodings.tqfind(lang) == encodings.end())
+ if (encodings.find(lang) == encodings.end())
throw KoHyphenatorException( TQString("No dictionary for %1").tqarg(lang) );
}
else
throw KoHyphenatorException( TQString("No dictionary for %1").tqarg(lang) );
}
- if (dicts.tqfind(lang) == dicts.end())
+ if (dicts.find(lang) == dicts.end())
{
#ifdef DEBUG_HYPHENATOR
kdDebug() << "Searching dictionary for '" << lang << "' language..." << endl;
@@ -194,7 +194,7 @@ HyphenDict *KoHyphenator::dict(const TQString &_lang) const
kdDebug() << "Loading dictionary for '" << lang << "' language: path = " << path << endl;
#endif
const_cast<KoHyphenator*>(this)->dicts.insert( lang, hnj_hyphen_load(TQFile::encodeName(path)) );
- if (dicts.tqfind(lang) == dicts.end())
+ if (dicts.find(lang) == dicts.end())
{
#ifdef DEBUG_HYPHENATOR
kdDebug() << "No dictionary loaded" << endl;
@@ -210,14 +210,14 @@ HyphenDict *KoHyphenator::dict(const TQString &_lang) const
TQTextCodec* KoHyphenator::codecForLang(const TQString& lang) const
{
- EncodingMap::Iterator it = encodings.tqfind(lang);
+ EncodingMap::Iterator it = encodings.find(lang);
if (it == encodings.end())
{
- int underscore = lang.tqfind('_');
+ int underscore = lang.find('_');
if ( underscore > -1 ) {
TQString _lang( lang );
_lang.truncate( underscore );
- it = encodings.tqfind(_lang);
+ it = encodings.find(_lang);
}
}
if (it != encodings.end())