[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    koffice/lib/kotext
From:       David Faure <faure () kde ! org>
Date:       2006-02-01 11:16:50
Message-ID: 1138792610.891872.4056.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 504496 by dfaure:

Fix strange red and blue lines appearing for people who use --enable-debug:
KoComplexText.cpp:#define BIDI_DEBUG 0 // 2
KoComplexText.cpp:#if (BIDI_DEBUG >= 1)
KoTextParag.cpp:#ifdef BIDI_DEBUG
Funny heh?


 M  +7 -7      KoComplexText.cpp  


--- trunk/koffice/lib/kotext/KoComplexText.cpp #504495:504496
@@ -855,8 +855,8 @@
 }
 #endif
 
-#define BIDI_DEBUG 0 // 2
-#if (BIDI_DEBUG >= 1)
+//#define BIDI_DEBUG
+#ifdef BIDI_DEBUG
 #include <iostream>
 #endif
 
@@ -933,7 +933,7 @@
 	    dirCurrent = text.at(current).direction();
 
 
-#if (BIDI_DEBUG >= 2)
+#ifdef BIDI_DEBUG
 	cout << "directions: dir=" << dir << " current=" << dirCurrent << " last=" << \
status.last << " eor=" << status.eor << " lastStrong=" << status.lastStrong << " \
embedding=" << context->dir << " level =" << (int)context->level << endl;  #endif
 
@@ -1311,7 +1311,7 @@
 	++current;
     }
 
-#if (BIDI_DEBUG >= 1)
+#ifdef BIDI_DEBUG
     cout << "reached end of line current=" << current << ", eor=" << eor << endl;
 #endif
     eor = current - 1; // remove dummy char
@@ -1341,7 +1341,7 @@
     // reversing is only done up to the lowest odd level
     if(!(levelLow%2)) levelLow++;
 
-#if (BIDI_DEBUG >= 1)
+#ifdef BIDI_DEBUG
     cout << "reorderLine: lineLow = " << (uint)levelLow << ", lineHigh = " << \
(uint)levelHigh << endl;  cout << "logical order is:" << endl;
     QPtrListIterator<KoTextRun> it2(*runs);
@@ -1379,7 +1379,7 @@
 	levelHigh--;
     }
 
-#if (BIDI_DEBUG >= 1)
+#ifdef BIDI_DEBUG
     cout << "visual order is:" << endl;
     QPtrListIterator<KoTextRun> it3(*runs);
     KoTextRun *r3;
@@ -1468,7 +1468,7 @@
 	else if( dir == QChar::DirAN )
 	    level += 2;
     }
-#if (BIDI_DEBUG >= 1)
+#ifdef BIDI_DEBUG
     printf("new run: dir=%d from %d, to %d level = %d\n", dir, _start, _stop, \
level);  #endif
 }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic