#FEATURE
authorClaus Gittinger <cg@exept.de>
Sat, 05 Mar 2016 11:15:22 +0100
changeset 19300 e55b50337eb5
parent 19299 ab722ea7efc2
child 19301 21b0b9bf3a74
child 19303 0f6711342ff1
#FEATURE class: Stream added: #printf:
Stream.st
--- a/Stream.st	Sat Mar 05 10:40:09 2016 +0100
+++ b/Stream.st	Sat Mar 05 11:15:22 2016 +0100
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "
  COPYRIGHT (c) 1989 by Claus Gittinger
 	      All Rights Reserved
@@ -216,6 +214,7 @@
     ^ ChunkSeparator
 ! !
 
+
 !Stream methodsFor:'Compatibility-Dolphin'!
 
 display:someObject
@@ -277,6 +276,8 @@
     "Modified: 10.1.1996 / 19:39:19 / cg"
 ! !
 
+
+
 !Stream methodsFor:'accessing'!
 
 contents
@@ -2119,7 +2120,7 @@
     "
         ((WriteStream on:Unicode16String new)
             nextPutUtf16:$B;
-            nextPutUtf16:$Ä; 
+            nextPutUtf16:$Ä; 
             nextPutUtf16:(Character codePoint:16r10CCCC)
             yourself) contents
     "
@@ -2182,7 +2183,7 @@
     "
       (String streamContents:[:s| 
             s nextPutUtf8:$a.
-            s nextPutUtf8:$ü.
+            s nextPutUtf8:$ü.
             s nextPutUtf8: (Character value:16r1fff).
             s nextPutUtf8: (Character value:16rffff).
             s nextPutUtf8: (Character value:16r1ffffff).
@@ -3954,6 +3955,16 @@
     "Created: / 26-09-2012 / 18:21:06 / cg"
 !
 
+printf:format
+    "C-style printing into a stream"
+    
+    format printf:#() on:self.
+
+    "
+     Transcript printf:'Hello World\n'
+    "
+!
+
 printf:format with:argument
     "C-style printing into a stream"