diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
commit | d6f8bbb45b267065a6907e71ff9c98bb6d161241 (patch) | |
tree | d109539636691d7b03036ca1c0ed29dbae6577cf /lib/util/kdeveditorutil.cpp | |
parent | 3331a47a9cad24795c7440ee8107143ce444ef34 (diff) | |
download | tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.tar.gz tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1157658 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'lib/util/kdeveditorutil.cpp')
-rw-r--r-- | lib/util/kdeveditorutil.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/util/kdeveditorutil.cpp b/lib/util/kdeveditorutil.cpp index fdf044d5..ca946ce6 100644 --- a/lib/util/kdeveditorutil.cpp +++ b/lib/util/kdeveditorutil.cpp @@ -33,15 +33,15 @@ bool KDevEditorUtil::currentPositionReal( unsigned int * line, unsigned int * co return true; } -QString KDevEditorUtil::currentLine( KTextEditor::Document * doc, KTextEditor::View * view ) +TQString KDevEditorUtil::currentLine( KTextEditor::Document * doc, KTextEditor::View * view ) { KTextEditor::EditInterface * editIface = dynamic_cast<KTextEditor::EditInterface*>( doc ); - if ( !editIface ) return QString(); + if ( !editIface ) return TQString(); view = view ? view : dynamic_cast<KTextEditor::View*>( doc->widget() ); KTextEditor::ViewCursorInterface * cursorIface = dynamic_cast<KTextEditor::ViewCursorInterface*>( view ); - if ( !cursorIface ) return QString(); + if ( !cursorIface ) return TQString(); uint line = 0; uint col = 0; @@ -50,21 +50,21 @@ QString KDevEditorUtil::currentLine( KTextEditor::Document * doc, KTextEditor::V return editIface->textLine(line); } -QString KDevEditorUtil::currentWord( KTextEditor::Document * doc, KTextEditor::View * view ) +TQString KDevEditorUtil::currentWord( KTextEditor::Document * doc, KTextEditor::View * view ) { KTextEditor::EditInterface * editIface = dynamic_cast<KTextEditor::EditInterface*>( doc ); - if ( !editIface ) return QString(); + if ( !editIface ) return TQString(); view = view ? view : dynamic_cast<KTextEditor::View*>( doc->widget() ); KTextEditor::ViewCursorInterface * cursorIface = dynamic_cast<KTextEditor::ViewCursorInterface*>( view ); - if ( !cursorIface ) return QString(); + if ( !cursorIface ) return TQString(); uint line = 0; uint col = 0; cursorIface->cursorPositionReal(&line, &col); - QString linestr = editIface->textLine(line); + TQString linestr = editIface->textLine(line); int startPos = QMAX( QMIN( (int)col, (int)linestr.length()-1 ), 0 ); int endPos = startPos; @@ -74,14 +74,14 @@ QString KDevEditorUtil::currentWord( KTextEditor::Document * doc, KTextEditor::V while (endPos < (int)linestr.length() && ( linestr[endPos].isLetterOrNumber() || linestr[endPos] == '_' ) ) endPos++; - return ( ( startPos == endPos ) ? QString::null : linestr.mid( startPos+1, endPos-startPos-1 ) ); + return ( ( startPos == endPos ) ? TQString::null : linestr.mid( startPos+1, endPos-startPos-1 ) ); } -QString KDevEditorUtil::currentSelection( KTextEditor::Document * doc ) +TQString KDevEditorUtil::currentSelection( KTextEditor::Document * doc ) { KTextEditor::SelectionInterface * selectIface = dynamic_cast<KTextEditor::SelectionInterface*>( doc ); - return selectIface ? selectIface->selection() : QString(); + return selectIface ? selectIface->selection() : TQString(); } |