Bläddra i källkod

* fix small bug in previous commit

pierre 23 år sedan
förälder
incheckning
97ab9a8f3c
2 ändrade filer med 8 tillägg och 4 borttagningar
  1. 6 3
      ide/fpviews.pas
  2. 2 1
      ide/test.pas

+ 6 - 3
ide/fpviews.pas

@@ -1245,7 +1245,7 @@ begin
             NextResWord:='';
             GetDisplayTextFormat(Y,LineText,LineAttr);
             if LineCount<>1 then X:=-1
-            else if ord(LineAttr[X])<>coReservedWordColor then
+            else if ord(LineAttr[X+1])<>coReservedWordColor then
               exit;
             repeat
               Inc(X);
@@ -1285,7 +1285,7 @@ begin
             GetDisplayTextFormat(Y,LineText,LineAttr);
             if LineCount<>1 then
               X:=Length(LineText)
-            else if ord(LineAttr[X])<>coReservedWordColor then
+            else if ord(LineAttr[X+1])<>coReservedWordColor then
               exit;
             repeat
               Dec(X);
@@ -4357,7 +4357,10 @@ end;
 END.
 {
   $Log$
-  Revision 1.27  2002-09-05 10:49:48  pierre
+  Revision 1.28  2002-09-05 10:57:08  pierre
+   * fix small bug in previous commit
+
+  Revision 1.27  2002/09/05 10:49:48  pierre
    + FindMatchingDelimiter for pascal keywords with level counting
 
   Revision 1.26  2002/09/05 05:58:58  pierre

+ 2 - 1
ide/test.pas

@@ -7,7 +7,7 @@ uses
   dpmiexcp,
 {$endif}
     test1, Test2;
-    
+
 
 const A =  1234;
       C =  #1#2#3#4;
@@ -159,6 +159,7 @@ var i : longint;
 BEGIN
   ClassVar1:=TClass2.create;
   X:=nil;
+  // fg
   for i:=1 to 2000 do
     CharArray[i]:=chr(32+(i mod (255-32)));
   writeln('Hello world!');