Menu

Diff of /trunk/Src/URTFStyles.pas [r3098] .. [r3099]  Maximize  Restore

Switch to side-by-side view

--- a/trunk/Src/URTFStyles.pas
+++ b/trunk/Src/URTFStyles.pas
@@ -3,7 +3,7 @@
  * v. 2.0. If a copy of the MPL was not distributed with this file, You can
  * obtain one at http://mozilla.org/MPL/2.0/
  *
- * Copyright (C) 2012, Peter Johnson (www.delphidabbler.com).
+ * Copyright (C) 2012-2013, Peter Johnson (www.delphidabbler.com).
  *
  * $Rev$
  * $Date$
@@ -174,13 +174,14 @@
 class operator TRTFParaSpacing.Equal(const Left,
   Right: TRTFParaSpacing): Boolean;
 begin
-  Result := (Left.Before = Right.Before) and (Left.After = Right.After);
+  Result := SameValue(Left.Before, Right.Before) and
+    SameValue(Left.After, Right.After);
 end;
 
 class operator TRTFParaSpacing.NotEqual(const Left,
   Right: TRTFParaSpacing): Boolean;
 begin
-  Result := (Left.Before <> Right.Before) or (Left.After <> Right.After);
+  Result := not (Left = Right);
 end;
 
 { TRTFStyle }
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.