summaryrefslogtreecommitdiffstats
path: root/pylupdate3/proparser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'pylupdate3/proparser.cpp')
-rw-r--r--pylupdate3/proparser.cpp44
1 files changed, 22 insertions, 22 deletions
diff --git a/pylupdate3/proparser.cpp b/pylupdate3/proparser.cpp
index f018b4c..edb86c1 100644
--- a/pylupdate3/proparser.cpp
+++ b/pylupdate3/proparser.cpp
@@ -3,7 +3,7 @@
**
** proparser.cpp
**
-** This file is part of Qt Linguist.
+** This file is part of TQt Linguist.
**
** See the file LICENSE included in the distribution for the usage
** and distribution terms.
@@ -19,53 +19,53 @@
#include "proparser.h"
-QMap<QString, QString> proFileTagMap( const QString& text )
+TQMap<TQString, TQString> proFileTagMap( const TQString& text )
{
- QString t = text;
+ TQString t = text;
/*
Strip comments, merge lines ending with backslash, add
spaces around '=' and '+=', replace '\n' with ';', and
simplify white spaces.
*/
- t.replace( QRegExp(QString("#[^\n]$")), QString(" ") );
- t.replace( QRegExp(QString("\\\\\\s*\n")), QString(" ") );
- t.replace( QRegExp(QString("=")), QString(" = ") );
- t.replace( QRegExp(QString("\\+ =")), QString(" += ") );
- t.replace( QRegExp(QString("\n")), QString(";") );
+ t.replace( TQRegExp(TQString("#[^\n]$")), TQString(" ") );
+ t.replace( TQRegExp(TQString("\\\\\\s*\n")), TQString(" ") );
+ t.replace( TQRegExp(TQString("=")), TQString(" = ") );
+ t.replace( TQRegExp(TQString("\\+ =")), TQString(" += ") );
+ t.replace( TQRegExp(TQString("\n")), TQString(";") );
t = t.simplifyWhiteSpace();
- QMap<QString, QString> tagMap;
+ TQMap<TQString, TQString> tagMap;
- QStringList lines = QStringList::split( QChar(';'), t );
- QStringList::Iterator line;
+ TQStringList lines = TQStringList::split( TQChar(';'), t );
+ TQStringList::Iterator line;
for ( line = lines.begin(); line != lines.end(); ++line ) {
- QStringList toks = QStringList::split( QChar(' '), *line );
+ TQStringList toks = TQStringList::split( TQChar(' '), *line );
if ( toks.count() >= 3 &&
- (toks[1] == QString("=") || toks[1] == QString("+=")) ) {
- QString tag = toks.first();
- int k = tag.findRev( QChar(':') ); // as in 'unix:'
+ (toks[1] == TQString("=") || toks[1] == TQString("+=")) ) {
+ TQString tag = toks.first();
+ int k = tag.findRev( TQChar(':') ); // as in 'unix:'
if ( k != -1 )
tag = tag.mid( k + 1 );
toks.remove( toks.begin() );
- QString action = toks.first();
+ TQString action = toks.first();
toks.remove( toks.begin() );
if ( tagMap.contains(tag) ) {
- if ( action == QString("=") )
- tagMap.replace( tag, toks.join(QChar(' ')) );
+ if ( action == TQString("=") )
+ tagMap.replace( tag, toks.join(TQChar(' ')) );
else
- tagMap[tag] += QChar( ' ' ) + toks.join( QChar(' ') );
+ tagMap[tag] += TQChar( ' ' ) + toks.join( TQChar(' ') );
} else {
- tagMap[tag] = toks.join( QChar(' ') );
+ tagMap[tag] = toks.join( TQChar(' ') );
}
}
}
- QRegExp var( "\\$\\$[a-zA-Z0-9_]+" );
- QMap<QString, QString>::Iterator it;
+ TQRegExp var( "\\$\\$[a-zA-Z0-9_]+" );
+ TQMap<TQString, TQString>::Iterator it;
for ( it = tagMap.begin(); it != tagMap.end(); ++it ) {
int i = 0;