From 10308be19ef7fa44699562cc75946e7ea1fdf6b9 Mon Sep 17 00:00:00 2001 From: tpearson Date: Fri, 7 Jan 2011 03:45:53 +0000 Subject: Revert automated changes Sorry guys, they are just not ready for prime time Work will continue as always git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1212479 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kate/part/katetextline.cpp | 54 +++++++++++++++++++++++----------------------- 1 file changed, 27 insertions(+), 27 deletions(-) (limited to 'kate/part/katetextline.cpp') diff --git a/kate/part/katetextline.cpp b/kate/part/katetextline.cpp index 6280c7300..e64b928c7 100644 --- a/kate/part/katetextline.cpp +++ b/kate/part/katetextline.cpp @@ -110,11 +110,11 @@ void KateTextLine::truncate(uint newLen) int KateTextLine::nextNonSpaceChar(uint pos) const { const uint len = m_text.length(); - const TQChar *tqunicode = m_text.tqunicode(); + const TQChar *unicode = m_text.unicode(); for(uint i = pos; i < len; i++) { - if(!tqunicode[i].isSpace()) + if(!unicode[i].isSpace()) return i; } @@ -128,11 +128,11 @@ int KateTextLine::previousNonSpaceChar(uint pos) const if (pos >= (uint)len) pos = len - 1; - const TQChar *tqunicode = m_text.tqunicode(); + const TQChar *unicode = m_text.unicode(); for(int i = pos; i >= 0; i--) { - if(!tqunicode[i].isSpace()) + if(!unicode[i].isSpace()) return i; } @@ -152,20 +152,20 @@ int KateTextLine::lastChar() const const TQChar *KateTextLine::firstNonSpace() const { int first = firstChar(); - return (first > -1) ? ((TQChar*)m_text.tqunicode())+first : m_text.tqunicode(); + return (first > -1) ? ((TQChar*)m_text.unicode())+first : m_text.unicode(); } uint KateTextLine::indentDepth (uint tabwidth) const { uint d = 0; const uint len = m_text.length(); - const TQChar *tqunicode = m_text.tqunicode(); + const TQChar *unicode = m_text.unicode(); for(uint i = 0; i < len; i++) { - if(tqunicode[i].isSpace()) + if(unicode[i].isSpace()) { - if (tqunicode[i] == TQChar('\t')) + if (unicode[i] == TQChar('\t')) d += tabwidth - (d % tabwidth); else d++; @@ -189,11 +189,11 @@ bool KateTextLine::stringAtPos(uint pos, const TQString& match) const // overflow again which (pos+matchlen > len) does not catch; see bugs #129263 and #129580 Q_ASSERT(pos < len); - const TQChar *tqunicode = m_text.tqunicode(); - const TQChar *matchUnicode = match.tqunicode(); + const TQChar *unicode = m_text.unicode(); + const TQChar *matchUnicode = match.unicode(); for (uint i=0; i < matchlen; i++) - if (tqunicode[i+pos] != matchUnicode[i]) + if (unicode[i+pos] != matchUnicode[i]) return false; return true; @@ -206,11 +206,11 @@ bool KateTextLine::startingWith(const TQString& match) const if (matchlen > m_text.length()) return false; - const TQChar *tqunicode = m_text.tqunicode(); - const TQChar *matchUnicode = match.tqunicode(); + const TQChar *unicode = m_text.unicode(); + const TQChar *matchUnicode = match.unicode(); for (uint i=0; i < matchlen; i++) - if (tqunicode[i] != matchUnicode[i]) + if (unicode[i] != matchUnicode[i]) return false; return true; @@ -223,12 +223,12 @@ bool KateTextLine::endingWith(const TQString& match) const if (matchlen > m_text.length()) return false; - const TQChar *tqunicode = m_text.tqunicode(); - const TQChar *matchUnicode = match.tqunicode(); + const TQChar *unicode = m_text.unicode(); + const TQChar *matchUnicode = match.unicode(); uint start = m_text.length() - matchlen; for (uint i=0; i < matchlen; i++) - if (tqunicode[start+i] != matchUnicode[i]) + if (unicode[start+i] != matchUnicode[i]) return false; return true; @@ -239,11 +239,11 @@ int KateTextLine::cursorX(uint pos, uint tabChars) const uint x = 0; const uint n = kMin (pos, m_text.length()); - const TQChar *tqunicode = m_text.tqunicode(); + const TQChar *unicode = m_text.unicode(); for ( uint z = 0; z < n; z++) { - if (tqunicode[z] == TQChar('\t')) + if (unicode[z] == TQChar('\t')) x += tabChars - (x % tabChars); else x++; @@ -257,11 +257,11 @@ uint KateTextLine::lengthWithTabs (uint tabChars) const { uint x = 0; const uint len = m_text.length(); - const TQChar *tqunicode = m_text.tqunicode(); + const TQChar *unicode = m_text.unicode(); for ( uint z = 0; z < len; z++) { - if (tqunicode[z] == TQChar('\t')) + if (unicode[z] == TQChar('\t')) x += tabChars - (x % tabChars); else x++; @@ -278,16 +278,16 @@ bool KateTextLine::searchText (uint startCol, const TQString &text, uint *foundA { int col = startCol; uint l = text.length(); - // allow tqfinding the string ending at eol + // allow finding the string ending at eol if ( col == (int) m_text.length() ) ++startCol; do { - index = m_text.tqfindRev( text, col, casesensitive ); + index = m_text.findRev( text, col, casesensitive ); col--; } while ( col >= 0 && l + index >= startCol ); } else - index = m_text.tqfind (text, startCol, casesensitive); + index = m_text.find (text, startCol, casesensitive); if (index > -1) { @@ -309,7 +309,7 @@ bool KateTextLine::searchText (uint startCol, const TQRegExp ®exp, uint *foun { int col = startCol; - // allow tqfinding the string ending at eol + // allow finding the string ending at eol if ( col == (int) m_text.length() ) ++startCol; do { index = regexp.searchRev (m_text, col); @@ -346,7 +346,7 @@ char *KateTextLine::dump (char *buf, bool withHighlighting) const memcpy(buf, &l, sizeof(uint)); buf += sizeof(uint); - memcpy(buf, (char *) m_text.tqunicode(), sizeof(TQChar)*l); + memcpy(buf, (char *) m_text.unicode(), sizeof(TQChar)*l); buf += sizeof(TQChar) * l; if (!withHighlighting) @@ -440,4 +440,4 @@ char *KateTextLine::restore (char *buf) return buf; } -// kate: space-indent on; indent-width 2; tqreplace-tabs on; +// kate: space-indent on; indent-width 2; replace-tabs on; -- cgit v1.2.1