summaryrefslogtreecommitdiffstats
path: root/kdoctools/kio_help.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kdoctools/kio_help.cpp')
-rw-r--r--kdoctools/kio_help.cpp36
1 files changed, 18 insertions, 18 deletions
diff --git a/kdoctools/kio_help.cpp b/kdoctools/kio_help.cpp
index 7af5919ff..292c4de13 100644
--- a/kdoctools/kio_help.cpp
+++ b/kdoctools/kio_help.cpp
@@ -75,7 +75,7 @@ TQString HelpProtocol::langLookup(const TQString& fname)
if ( ( *it ).right( 5 ) == ".html" )
{
- TQString file = (*it).left((*it).tqfindRev('/')) + "/index.docbook";
+ TQString file = (*it).left((*it).findRev('/')) + "/index.docbook";
kdDebug( 7119 ) << "Looking for help in: " << file << endl;
info.setFile(file);
if (info.exists() && info.isFile() && info.isReadable())
@@ -112,7 +112,7 @@ TQString HelpProtocol::lookupFile(const TQString &fname,
}
else
{
- tqunicodeError( i18n("There is no documentation available for %1." ).arg(path) );
+ unicodeError( i18n("There is no documentation available for %1." ).arg(path) );
finished();
return TQString::null;
}
@@ -123,7 +123,7 @@ TQString HelpProtocol::lookupFile(const TQString &fname,
}
-void HelpProtocol::tqunicodeError( const TQString &t )
+void HelpProtocol::unicodeError( const TQString &t )
{
data(fromUnicode( TQString(
"<html><head><meta http-equiv=\"Content-Type\" content=\"text/html; charset=%1\"></head>\n"
@@ -189,7 +189,7 @@ void HelpProtocol::get( const KURL& url )
return;
}
} else {
- TQString docbook_file = file.left(file.tqfindRev('/')) + "/index.docbook";
+ TQString docbook_file = file.left(file.findRev('/')) + "/index.docbook";
if (!KStandardDirs::exists(file)) {
file = docbook_file;
} else {
@@ -215,13 +215,13 @@ void HelpProtocol::get( const KURL& url )
kdDebug( 7119 ) << "parsed " << mParsed.length() << endl;
if (mParsed.isEmpty()) {
- tqunicodeError( i18n( "The requested help file could not be parsed:<br>%1" ).arg( file ) );
+ unicodeError( i18n( "The requested help file could not be parsed:<br>%1" ).arg( file ) );
} else {
- int pos1 = mParsed.tqfind( "charset=" );
+ int pos1 = mParsed.find( "charset=" );
if ( pos1 > 0 ) {
- int pos2 = mParsed.tqfind( '"', pos1 );
+ int pos2 = mParsed.find( '"', pos1 );
if ( pos2 > 0 ) {
- mParsed.tqreplace( pos1, pos2 - pos1, "charset=UTF-8" );
+ mParsed.replace( pos1, pos2 - pos1, "charset=UTF-8" );
}
}
data( mParsed.utf8() );
@@ -248,11 +248,11 @@ void HelpProtocol::get( const KURL& url )
kdDebug( 7119 ) << "parsed " << mParsed.length() << endl;
if (mParsed.isEmpty()) {
- tqunicodeError( i18n( "The requested help file could not be parsed:<br>%1" ).arg( file ) );
+ unicodeError( i18n( "The requested help file could not be parsed:<br>%1" ).arg( file ) );
} else {
TQString query = url.query(), anchor;
- // if we have a query, look if it tqcontains an anchor
+ // if we have a query, look if it contains an anchor
if (!query.isEmpty())
if (query.left(8) == "?anchor=") {
anchor = query.mid(8).lower();
@@ -274,7 +274,7 @@ void HelpProtocol::get( const KURL& url )
{
int index = 0;
while ( true ) {
- index = mParsed.tqfind( TQRegExp( "<a name=" ), index);
+ index = mParsed.find( TQRegExp( "<a name=" ), index);
if ( index == -1 ) {
kdDebug( 7119 ) << "no anchor\n";
break; // use whatever is the target, most likely index.html
@@ -283,12 +283,12 @@ void HelpProtocol::get( const KURL& url )
if ( mParsed.mid( index, 11 + anchor.length() ).lower() ==
TQString( "<a name=\"%1\">" ).arg( anchor ) )
{
- index = mParsed.tqfindRev( "<FILENAME filename=", index ) +
+ index = mParsed.findRev( "<FILENAME filename=", index ) +
strlen( "<FILENAME filename=\"" );
TQString filename=mParsed.mid( index, 2000 );
- filename = filename.left( filename.tqfind( '\"' ) );
+ filename = filename.left( filename.find( '\"' ) );
TQString path = target.path();
- path = path.left( path.tqfindRev( '/' ) + 1) + filename;
+ path = path.left( path.findRev( '/' ) + 1) + filename;
kdDebug( 7119 ) << "anchor found in " << path <<endl;
target.setPath( path );
break;
@@ -307,21 +307,21 @@ void HelpProtocol::emitFile( const KURL& url )
{
infoMessage(i18n("Looking up section"));
- TQString filename = url.path().mid(url.path().tqfindRev('/') + 1);
+ TQString filename = url.path().mid(url.path().findRev('/') + 1);
- int index = mParsed.tqfind(TQString("<FILENAME filename=\"%1\"").arg(filename));
+ int index = mParsed.find(TQString("<FILENAME filename=\"%1\"").arg(filename));
if (index == -1) {
if ( filename == "index.html" ) {
data( fromUnicode( mParsed ) );
return;
}
- tqunicodeError( i18n("Could not tqfind filename %1 in %2.").arg(filename).arg( url.url() ) );
+ unicodeError( i18n("Could not find filename %1 in %2.").arg(filename).arg( url.url() ) );
return;
}
TQString filedata = splitOut(mParsed, index);
- tqreplaceCharsetHeader( filedata );
+ replaceCharsetHeader( filedata );
data( fromUnicode( filedata ) );
data( TQByteArray() );