summaryrefslogtreecommitdiffstats
path: root/kbabel/filters/gettext/gettextimport.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kbabel/filters/gettext/gettextimport.cpp')
-rw-r--r--kbabel/filters/gettext/gettextimport.cpp50
1 files changed, 25 insertions, 25 deletions
diff --git a/kbabel/filters/gettext/gettextimport.cpp b/kbabel/filters/gettext/gettextimport.cpp
index ce1680d4..f66516cc 100644
--- a/kbabel/filters/gettext/gettextimport.cpp
+++ b/kbabel/filters/gettext/gettextimport.cpp
@@ -1,4 +1,4 @@
-// kate: space-indent on; indent-width 3; tqreplace-tabs on;
+// kate: space-indent on; indent-width 3; replace-tabs on;
/* ****************************************************************************
This file is part of KBabel
@@ -163,7 +163,7 @@ ConversiontqStatus GettextImportPlugin::load(const TQString& filename, const TQS
}
// check if header seems to indicate docbook content generated by xml2pot
- const bool docbookContent = (tempHeader.msgstr().tqfind("application/x-xml2pot") != tempHeader.msgstr().end());
+ const bool docbookContent = (tempHeader.msgstr().find("application/x-xml2pot") != tempHeader.msgstr().end());
// now parse the rest of the file
uint counter=0;
@@ -200,7 +200,7 @@ ConversiontqStatus GettextImportPlugin::load(const TQString& filename, const TQS
appendCatalogItem(tempCatItem);
// check if first comment seems to indicate a docbook source file
if(counter==0)
- docbookFile = ( tempCatItem.comment().tqfind(".docbook") != -1 );
+ docbookFile = ( tempCatItem.comment().find(".docbook") != -1 );
}
}
else if(success==RECOVERED_PARSE_ERROR)
@@ -439,7 +439,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
part=Comment;
_comment=line;
}
- else if(line.tqfind(TQRegExp("^msgctxt\\s*\".*\"$")) != -1)
+ else if(line.find(TQRegExp("^msgctxt\\s*\".*\"$")) != -1)
{
part=Msgctxt;
@@ -449,7 +449,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
_msgctxt=line;
seenMsgctxt=true;
}
- else if(line.tqfind(TQRegExp("^msgid\\s*\".*\"$")) != -1)
+ else if(line.find(TQRegExp("^msgid\\s*\".*\"$")) != -1)
{
part=Msgid;
@@ -460,7 +460,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
(*(_msgid).begin())=line;
}
// one of the quotation marks is missing
- else if(line.tqfind(TQRegExp("^msgid\\s*\"?.*\"?$")) != -1)
+ else if(line.find(TQRegExp("^msgid\\s*\"?.*\"?$")) != -1)
{
part=Msgid;
@@ -494,7 +494,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
{
_comment+=("\n"+line);
}
- else if(line.tqfind(TQRegExp("^msgctxt\\s*\".*\"$")) != -1)
+ else if(line.find(TQRegExp("^msgctxt\\s*\".*\"$")) != -1)
{
part=Msgctxt;
@@ -504,7 +504,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
_msgctxt=line;
seenMsgctxt=true;
}
- else if(line.tqfind(TQRegExp("^msgid\\s*\".*\"$")) != -1)
+ else if(line.find(TQRegExp("^msgid\\s*\".*\"$")) != -1)
{
part=Msgid;
@@ -515,7 +515,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
(*(_msgid).begin())=line;
}
// one of the quotation marks is missing
- else if(line.tqfind(TQRegExp("^msgid\\s*\"?.*\"?$")) != -1)
+ else if(line.find(TQRegExp("^msgid\\s*\"?.*\"?$")) != -1)
{
part=Msgid;
@@ -539,7 +539,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
{
if(line.isEmpty())
continue;
- else if(line.tqfind(TQRegExp("^\".*\\n?\"$")) != -1)
+ else if(line.find(TQRegExp("^\".*\\n?\"$")) != -1)
{
// remove quotes at beginning and the end of the lines
line.remove(TQRegExp("^\""));
@@ -551,7 +551,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
else
_msgctxt+=("\n"+line);
}
- else if(line.tqfind(TQRegExp("^msgid\\s*\".*\"$")) != -1)
+ else if(line.find(TQRegExp("^msgid\\s*\".*\"$")) != -1)
{
part=Msgid;
@@ -562,7 +562,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
(*(_msgid).begin())=line;
}
// one of the quotation marks is missing
- else if(line.tqfind(TQRegExp("^msgid\\s*\"?.*\"?$")) != -1)
+ else if(line.find(TQRegExp("^msgid\\s*\"?.*\"?$")) != -1)
{
part=Msgid;
@@ -586,7 +586,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
{
if(line.isEmpty())
continue;
- else if(line.tqfind(TQRegExp("^\".*\\n?\"$")) != -1)
+ else if(line.find(TQRegExp("^\".*\\n?\"$")) != -1)
{
// remove quotes at beginning and the end of the lines
line.remove(TQRegExp("^\""));
@@ -604,7 +604,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
else
(*it)+=("\n"+line);
}
- else if(line.tqfind(TQRegExp("^msgid_plural\\s*\".*\"$")) != -1)
+ else if(line.find(TQRegExp("^msgid_plural\\s*\".*\"$")) != -1)
{
part=Msgid;
_gettextPluralForm = true;
@@ -616,7 +616,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
_msgid.append(line);
}
// one of the quotation marks is missing
- else if(line.tqfind(TQRegExp("^msgid_plural\\s*\"?.*\"?$")) != -1)
+ else if(line.find(TQRegExp("^msgid_plural\\s*\"?.*\"?$")) != -1)
{
part=Msgid;
_gettextPluralForm = true;
@@ -631,7 +631,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
recoverableError=true;
}
else if(!_gettextPluralForm
- && (line.tqfind(TQRegExp("^msgstr\\s*\".*\\n?\"$")) != -1))
+ && (line.find(TQRegExp("^msgstr\\s*\".*\\n?\"$")) != -1))
{
part=Msgstr;
@@ -642,7 +642,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
(*msgstrIt)=line;
}
else if(!_gettextPluralForm
- && line.tqfind(TQRegExp("^msgstr\\s*\"?.*\\n?\"?$")) != -1)
+ && line.find(TQRegExp("^msgstr\\s*\"?.*\\n?\"?$")) != -1)
{
part=Msgstr;
@@ -656,7 +656,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
recoverableError=true;
}
else if( _gettextPluralForm
- && (line.tqfind(TQRegExp("^msgstr\\[0\\]\\s*\".*\\n?\"$")) != -1))
+ && (line.find(TQRegExp("^msgstr\\[0\\]\\s*\".*\\n?\"$")) != -1))
{
part=Msgstr;
@@ -667,7 +667,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
(*msgstrIt)=line;
}
else if( _gettextPluralForm
- && (line.tqfind(TQRegExp("^msgstr\\[0\\]\\s*\"?.*\\n?\"?$")) != -1))
+ && (line.find(TQRegExp("^msgstr\\[0\\]\\s*\"?.*\\n?\"?$")) != -1))
{
part=Msgstr;
@@ -694,7 +694,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
break;
}
// a line of the msgid with a missing quotation mark
- else if(line.tqfind(TQRegExp("^\"?.+\\n?\"?$")) != -1)
+ else if(line.find(TQRegExp("^\"?.+\\n?\"?$")) != -1)
{
recoverableError=true;
@@ -726,7 +726,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
if(line.isEmpty())
continue;
// another line of the msgstr
- else if(line.tqfind(TQRegExp("^\".*\\n?\"$")) != -1)
+ else if(line.find(TQRegExp("^\".*\\n?\"$")) != -1)
{
// remove quotes at beginning and the end of the lines
line.remove(TQRegExp("^\""));
@@ -738,7 +738,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
(*msgstrIt)+=("\n"+line);
}
else if( _gettextPluralForm
- && (line.tqfind(TQRegExp("^msgstr\\[[0-9]+\\]\\s*\".*\\n?\"$")) != -1))
+ && (line.find(TQRegExp("^msgstr\\[[0-9]+\\]\\s*\".*\\n?\"$")) != -1))
{
// remove quotes at beginning and the end of the lines
line.remove(TQRegExp("^msgstr\\[[0-9]+\\]\\s*\"?"));
@@ -747,7 +747,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
msgstrIt=_msgstr.append(line);
}
else if( _gettextPluralForm
- && (line.tqfind(TQRegExp("^msgstr\\[[0-9]\\]\\s*\"?.*\\n?\"?$")) != -1))
+ && (line.find(TQRegExp("^msgstr\\[[0-9]\\]\\s*\"?.*\\n?\"?$")) != -1))
{
// remove quotes at beginning and the end of the lines
line.remove(TQRegExp("^msgstr\\[[0-9]\\]\\s*\"?"));
@@ -758,7 +758,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
if(!line.isEmpty())
recoverableError=true;
}
- else if((line.tqfind(TQRegExp("^\\s*msgid")) != -1) || (line.tqfind(TQRegExp("^\\s*#")) != -1))
+ else if((line.find(TQRegExp("^\\s*msgid")) != -1) || (line.find(TQRegExp("^\\s*#")) != -1))
{
// We have read successfully one entry, so end loop.
stream.tqdevice()->at(pos);// reset position in stream to beginning of this line
@@ -771,7 +771,7 @@ ConversiontqStatus GettextImportPlugin::readEntry(TQTextStream& stream)
break;
}
// another line of the msgstr with a missing quotation mark
- else if(line.tqfind(TQRegExp("^\"?.+\\n?\"?$")) != -1)
+ else if(line.find(TQRegExp("^\"?.+\\n?\"?$")) != -1)
{
recoverableError=true;