summaryrefslogtreecommitdiffstats
path: root/tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp')
-rw-r--r--tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp58
1 files changed, 29 insertions, 29 deletions
diff --git a/tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp b/tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp
index b608d51..8c2e0df 100644
--- a/tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp
+++ b/tqtinterface/qt4/tools/assistant/helpdialogimpl.cpp
@@ -71,7 +71,7 @@
static TQString stripAmpersand( const TQString &str )
{
TQString s( str );
- s = s.tqreplace( '&', "" );
+ s = s.replace( '&', "" );
return s;
}
@@ -138,7 +138,7 @@ HelpNavigationListItem::HelpNavigationListItem( TQListBox *ls, const TQString &t
void HelpNavigationListItem::addLink( const TQString &link )
{
- int hash = link.tqfind( '#' );
+ int hash = link.find( '#' );
if ( hash == -1 ) {
linkList << link;
return;
@@ -364,10 +364,10 @@ void HelpDialog::loadIndexFile()
lastKeyword = (*it).keyword;
TQString lnk = (*it).link;
- int i = lnk.tqfindRev('#');
+ int i = lnk.findRev('#');
if ( i > -1 )
lnk = lnk.left( i );
- if (!keywordDocuments.tqcontains(lnk))
+ if (!keywordDocuments.contains(lnk))
keywordDocuments.append(lnk);
}
framePrepare->hide();
@@ -569,13 +569,13 @@ void HelpDialog::buildContentDict()
void HelpDialog::currentTabChanged( const TQString &s )
{
- if ( stripAmpersand( s ).tqcontains( tr( "Index" ) ) )
+ if ( stripAmpersand( s ).contains( tr( "Index" ) ) )
TQTimer::singleShot( 0, this, TQT_SLOT( loadIndexFile() ) );
- else if ( stripAmpersand( s ).tqcontains( tr( "Bookmarks" ) ) )
+ else if ( stripAmpersand( s ).contains( tr( "Bookmarks" ) ) )
insertBookmarks();
- else if ( stripAmpersand( s ).tqcontains( tr( "Contents" ) ) )
+ else if ( stripAmpersand( s ).contains( tr( "Contents" ) ) )
TQTimer::singleShot( 0, this, TQT_SLOT( insertContents() ) );
- else if ( stripAmpersand( s ).tqcontains( tr( "Search" ) ) )
+ else if ( stripAmpersand( s ).contains( tr( "Search" ) ) )
TQTimer::singleShot( 0, this, TQT_SLOT( setupFullTextIndex() ) );
}
@@ -614,11 +614,11 @@ void HelpDialog::showTopic( TQListViewItem *item )
void HelpDialog::showTopic()
{
- if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).tqcontains( tr( "Index" ) ) )
+ if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).contains( tr( "Index" ) ) )
showIndexTopic();
- else if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).tqcontains( tr( "Bookmarks" ) ) )
+ else if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).contains( tr( "Bookmarks" ) ) )
showBookmarkTopic();
- else if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).tqcontains( tr( "Contents" ) ) )
+ else if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).contains( tr( "Contents" ) ) )
showContentsTopic();
}
@@ -671,7 +671,7 @@ void HelpDialog::searchInIndex( const TQString &s )
TQString HelpDialog::titleOfLink( const TQString &link )
{
TQString s( link );
- s.remove( s.tqfind( '#' ), s.length() );
+ s.remove( s.find( '#' ), s.length() );
s = titleMap[ s ];
if ( s.isEmpty() )
return link;
@@ -944,16 +944,16 @@ void HelpDialog::setupFullTextIndex()
TQString documentName;
for ( ; it != titleMap.end(); ++it ) {
documentName = it.key();
- int i = documentName.tqfindRev('#');
+ int i = documentName.findRev('#');
if ( i > -1 )
documentName = documentName.left( i );
- if (!documentList.tqcontains(documentName))
+ if (!documentList.contains(documentName))
documentList << documentName;
}
loadIndexFile();
for (TQStringList::Iterator it2 = keywordDocuments.begin(); it2 != keywordDocuments.end(); ++it2) {
- if (!documentList.tqcontains(*it2))
+ if (!documentList.contains(*it2))
documentList << *it2;
}
fullTextIndex->setDocList( documentList );
@@ -996,11 +996,11 @@ void HelpDialog::setIndexingProgress( int prog )
void HelpDialog::startSearch()
{
TQString str = termsEdit->text();
- str = str.tqreplace( "\'", "\"" );
- str = str.tqreplace( "`", "\"" );
+ str = str.replace( "\'", "\"" );
+ str = str.replace( "`", "\"" );
TQString buf = str;
- str = str.tqreplace( "-", " " );
- str = str.tqreplace( TQRegExp( "\\s[\\S]?\\s" ), " " );
+ str = str.replace( "-", " " );
+ str = str.replace( TQRegExp( "\\s[\\S]?\\s" ), " " );
terms = TQStringList::split( " ", str );
TQStringList termSeq;
TQStringList seqWords;
@@ -1008,28 +1008,28 @@ void HelpDialog::startSearch()
for ( ; it != terms.end(); ++it ) {
(*it) = (*it).simplifyWhiteSpace();
(*it) = (*it).lower();
- (*it) = (*it).tqreplace( "\"", "" );
+ (*it) = (*it).replace( "\"", "" );
}
- if ( str.tqcontains( '\"' ) ) {
- if ( (str.tqcontains( '\"' ))%2 == 0 ) {
+ if ( str.contains( '\"' ) ) {
+ if ( (str.contains( '\"' ))%2 == 0 ) {
int beg = 0;
int end = 0;
TQString s;
- beg = str.tqfind( '\"', beg );
+ beg = str.find( '\"', beg );
while ( beg != -1 ) {
beg++;
- end = str.tqfind( '\"', beg );
+ end = str.find( '\"', beg );
s = str.mid( beg, end - beg );
s = s.lower();
s = s.simplifyWhiteSpace();
- if ( s.tqcontains( '*' ) ) {
+ if ( s.contains( '*' ) ) {
TQMessageBox::warning( this, tr( "Full Text Search" ),
tr( "Using a wildcard within phrases is not allowed." ) );
return;
}
seqWords += TQStringList::split( ' ', s );
termSeq << s;
- beg = str.tqfind( '\"', end + 1);
+ beg = str.find( '\"', end + 1);
}
} else {
TQMessageBox::warning( this, tr( "Full Text Search" ),
@@ -1095,14 +1095,14 @@ void HelpDialog::showItemMenu( TQListBoxItem *item, const TQPoint &pos )
return;
int id = itemPopup->exec( pos );
if ( id == 0 ) {
- if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).tqcontains( tr( "Index" ) ) )
+ if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).contains( tr( "Index" ) ) )
showTopic();
else {
showResultPage( item );
}
} else if ( id > 0 ) {
HelpWindow *hw = help->browsers()->currentBrowser();
- if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).tqcontains( tr( "Index" ) ) ) {
+ if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).contains( tr( "Index" ) ) ) {
editIndex->blockSignals( TRUE );
editIndex->setText( item->text() );
editIndex->blockSignals( FALSE );
@@ -1147,7 +1147,7 @@ void HelpDialog::showItemMenu( TQListViewItem *item, const TQPoint &pos )
return;
int id = itemPopup->exec( pos );
if ( id == 0 ) {
- if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).tqcontains( tr( "Contents" ) ) )
+ if ( stripAmpersand( tabWidget->tabLabel( tabWidget->currentPage() ) ).contains( tr( "Contents" ) ) )
showContentsTopic();
else
showBookmarkTopic();