TextStream.st
changeset 3001 314f68c6ad13
parent 2537 d186547b3459
child 3480 4afdd00dd4c1
--- a/TextStream.st	Mon Jun 03 18:30:22 2013 +0200
+++ b/TextStream.st	Mon Jun 03 19:50:14 2013 +0200
@@ -175,7 +175,7 @@
     "change the emphasis; all followup elements are appended with
      that emphasis in effect"
 
-    position ~~ ZeroPosition ifTrue:[
+    position ~~ 0 ifTrue:[
         currentEmphasis ~= newEmphasis ifTrue:[
             self closeRun.
         ]
@@ -223,11 +223,11 @@
 !TextStream methodsFor:'private'!
 
 closeRun
-    position ~~ ZeroPosition ifTrue:[
+    position ~~ 0 ifTrue:[
         runs isNil ifTrue:[
-            runs := RunArray new:position-ZeroPosition withAll:currentEmphasis.
+            runs := RunArray new:position withAll:currentEmphasis.
         ] ifFalse:[
-            runs add:currentEmphasis withOccurrences:(position-ZeroPosition-runs size)
+            runs add:currentEmphasis withOccurrences:(position-runs size)
         ]
     ]
 ! !
@@ -258,9 +258,10 @@
 !TextStream class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic2/TextStream.st,v 1.14 2011-02-17 13:13:22 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic2/TextStream.st,v 1.15 2013-06-03 17:50:14 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic2/TextStream.st,v 1.14 2011-02-17 13:13:22 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic2/TextStream.st,v 1.15 2013-06-03 17:50:14 cg Exp $'
 ! !
+