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

List:       kwrite-devel
Subject:    [Bug 81005] [PATCH] Corresponding parenthesis does not get
From:       Jesse Yurkovich <yurkjes () iit ! edu>
Date:       2004-05-09 1:24:26
Message-ID: 20040509012426.29142.qmail () ktown ! kde ! org
[Download RAW message or body]

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
      
http://bugs.kde.org/show_bug.cgi?id=81005      
yurkjes iit edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Corresponding parenthesis   |[PATCH] Corresponding
                   |does not get colorized      |parenthesis does not get
                   |                            |colorized



------- Additional Comments From yurkjes iit edu  2004-05-09 03:24 -------
Yupe :)  The patch gives prio to the right opening bracket instead of the left \
closing one. Now on to 75535 ...

RCS file: /home/kde/kdelibs/kate/part/katedocument.cpp,v
retrieving revision 1.711
diff -u -p -r1.711 katedocument.cpp
--- katedocument.cpp	7 May 2004 09:28:45 -0000	1.711
+++ katedocument.cpp	9 May 2004 01:21:26 -0000
 @ -4034,9 +4044,9  @ inline bool isBracket     ( const QChar&
 /*
    Bracket matching uses the following algorithm:
    If in overwrite mode, match the bracket currently underneath the cursor.
-   Otherwise, if the character to the left of the cursor is an ending bracket,
-   match it. Otherwise if the character to the right of the cursor is a
-   starting bracket, match it. Otherwise, if the the character to the left
+   Otherwise, if the character to the right of the cursor is an starting bracket,
+   match it. Otherwise if the character to the left of the cursor is a
+   ending bracket, match it. Otherwise, if the the character to the left
    of the cursor is an starting bracket, match it. Otherwise, if the character
    to the right of the cursor is an ending bracket, match it. Otherwise, don't
    match anything.
 @ -4069,11 +4079,11  @ bool KateDocument::findMatchingBracket( 
     } else {
       return false;
     }
+  } else if ( isStartBracket( right ) ) {
+    bracket = right;
   } else if ( isEndBracket( left ) ) {
     start.setCol(start.col() - 1);
     bracket = left;
-  } else if ( isStartBracket( right ) ) {
-    bracket = right;
   } else if ( isBracket( left ) ) {
     start.setCol(start.col() - 1);
     bracket = left;
_______________________________________________
KWrite-Devel mailing list
KWrite-Devel@kde.org
https://mail.kde.org/mailman/listinfo/kwrite-devel


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

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