diff options
Diffstat (limited to 'lib/kotext/KoAutoFormat.cpp')
-rw-r--r-- | lib/kotext/KoAutoFormat.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/kotext/KoAutoFormat.cpp b/lib/kotext/KoAutoFormat.cpp index c859d26c..7ca6f1a7 100644 --- a/lib/kotext/KoAutoFormat.cpp +++ b/lib/kotext/KoAutoFormat.cpp @@ -932,7 +932,7 @@ bool KoAutoFormat::doCompletion( KoTextCursor* textEditCursor, KoTextParag *para uint maxlength = 0; for ( TQStringList::ConstIterator it = wordlist.begin(); it != wordlist.end(); ++it ) // several completion words were found { - if ( (*it).tqstartsWith( lastWord, false ) && new_wordlist.find(*it) == new_wordlist.end() ) //the completion words that begin with lastWord + if ( (*it).startsWith( lastWord, false ) && new_wordlist.find(*it) == new_wordlist.end() ) //the completion words that begin with lastWord { if ( (*it).length() > maxlength ) maxlength = (*it).length(); @@ -952,7 +952,7 @@ bool KoAutoFormat::doCompletion( KoTextCursor* textEditCursor, KoTextParag *para TQChar ch = new_wordlist.first().at(i); for (TQStringList::ConstIterator it = new_wordlist.begin(); it != new_wordlist.end(); ++it ) { - if ( (*it).tqat(i).lower() != ch.lower() ) + if ( (*it).at(i).lower() != ch.lower() ) { word = (*it).left(i); //the completion word is truncated here //kdDebug() << "set the word completion to:" << word << endl; @@ -1063,7 +1063,7 @@ void KoAutoFormat::showToolTipBox(KoTextParag *parag, int index, TQWidget *widg m_completionBox->setText(word); m_completionBox->setLastWord(lastWord); m_completionBox->adjustSize(); - int const height = m_completionBox->tqsizeHint().height(); + int const height = m_completionBox->sizeHint().height(); m_completionBox->move( show_pos.x(), show_pos.y() - height ); if (!m_completionBox->isShown() ) @@ -1778,7 +1778,7 @@ void KoAutoFormat::doAutoDetectUrl( KoTextCursor *textEditCursor, KoTextParag *p txtObj->insert( textEditCursor, lastFormat, KoTextObject::customItemChar(), i18n("Insert Variable"), KoTextDocument::HighlightSelection, KoTextObject::DefaultInsertFlags, customItemsMap ); var->recalc(); - parag->tqinvalidate(0); + parag->invalidate(0); parag->setChanged( true ); // adjust index @@ -1819,7 +1819,7 @@ void KoAutoFormat::doAutoIncludeUpperUpper(KoTextCursor* /*textEditCursor*/, KoT break; word.append( ch ); } - if( word.length() > 2 && word.left(2)==word.left(2).upper() && word.tqat(3)!=word.tqat(3).upper() ) + if( word.length() > 2 && word.left(2)==word.left(2).upper() && word.at(3)!=word.at(3).upper() ) { if ( m_twoUpperLetterException.findIndex(word )==-1) m_twoUpperLetterException.append( word); @@ -1856,7 +1856,7 @@ void KoAutoFormat::doAutoIncludeAbbreviation(KoTextCursor* /*textEditCursor*/, K break; wordAfter.append( ch ); } - if( word.length()>1 && !wordAfter.isEmpty() && wordAfter.tqat(0)==wordAfter.tqat(0).lower()) + if( word.length()>1 && !wordAfter.isEmpty() && wordAfter.at(0)==wordAfter.at(0).lower()) { if ( m_upperCaseExceptions.findIndex(word )==-1) m_upperCaseExceptions.append( word ); @@ -2158,14 +2158,14 @@ KCommand *KoAutoFormat::doCapitalizeNameOfDays( KoTextCursor* textEditCursor, Ko TQString replaceStr= m_cacheNameOfDays[pos]; int start = index - replaceStr.length(); int length = replaceStr.length(); - if( word.tqat(0).isLetter() && word.tqat(0)==word.tqat(0).lower() ) + if( word.at(0).isLetter() && word.at(0)==word.at(0).lower() ) { KoTextCursor cursor( parag->document() ); cursor.setParag( parag ); cursor.setIndex( start ); textdoc->setSelectionStart( KoTextDocument::HighlightSelection, &cursor ); cursor.setIndex( start + length ); - TQString replacement = replaceStr.tqat(0).upper() + replaceStr.right( length-1 ); + TQString replacement = replaceStr.at(0).upper() + replaceStr.right( length-1 ); textdoc->setSelectionEnd( KoTextDocument::HighlightSelection, &cursor ); TQString cmdName=i18n("Capitalize Name of Days"); KCommand *cmd =txtObj->replaceSelectionCommand( textEditCursor, replacement, |