TextCollector.st
changeset 5301 3280021411a0
parent 5246 28887183d75f
child 5302 cb9b58fe53e9
--- a/TextCollector.st	Mon Mar 02 12:23:20 2015 +0100
+++ b/TextCollector.st	Mon Mar 02 13:15:58 2015 +0100
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
 "
  COPYRIGHT (c) 1989 by Claus Gittinger
 	      All Rights Reserved
@@ -19,7 +21,8 @@
 		timeDelay access currentEmphasis alwaysAppendAtEnd collectSize
 		autoRaise'
 	classVariableNames:'TranscriptQuerySignal DebugSendersOfMessagePattern
-		TraceSendersOfMessagePattern TimestampMessages'
+		TraceSendersOfMessagePattern TimestampMessage s DefaultLineLimit
+		DefaultTimeDelay DefaultCollectSize'
 	poolDictionaries:''
 	category:'Views-Text'
 !
@@ -101,7 +104,8 @@
 !
 
 newTranscript:name
-    "create and open a new transcript.
+    "create and open a new transcript, unless one already exists by that name.
+     The transcript is remembered in a global by that name.
      This is a leftOver method from times were the Launcher & Transcript
      were two different views. It is no longer recommended."
 
@@ -220,23 +224,79 @@
 !TextCollector class methodsFor:'defaults'!
 
 defaultCollectSize
-    "the number of lines buffered for delayed update"
+    "the number of lines buffered for delayed update.
+     At most this number of lines to be shown are buffered (without redrawing),
+     before a redraw is done. Thus, if a lot of output is generated fast,
+     the redrawing is performed in chunks. 
+     This has a significant effect on the performane, 
+     as the view does not have to scroll and redraw for each
+     individual line, but does junp-scrolling instead.
+     See also defaultTimeDelay"
+
+    ^ DefaultCollectSize ? 1000
 
-    ^ 1000
+    "Modified: / 27.7.1998 / 16:14:51 / cg"
+!
+
+defaultCollectSize:numberOfLines
+    "the number of lines buffered for delayed update.
+     At most this number of lines to be shown are buffered (without redrawing),
+     before a redraw is done. Thus, if a lot of output is generated fast,
+     the redrawing is performed in chunks. 
+     This has a significant effect on the performane, 
+     as the view does not have to scroll and redraw for each
+     individual line, but does junp-scrolling instead.
+     See also defaultTimeDelay"
+
+    DefaultCollectSize := numberOfLines
 
     "Modified: / 27.7.1998 / 16:14:51 / cg"
 !
 
 defaultLineLimit
-    "the number of lines remembered by default"
+    "the number of lines remembered by default.
+     Only the last n lines are remembered and can be seen by scrolling.
+     Older lines are forgotten.
+     This limit can be changed by the userPreferences dialog"
+
+    ^ DefaultLineLimit ? 1000
+!
 
-    ^ 1000
+defaultLineLimit:numberOfLines
+    "the number of lines remembered by default.
+     Only the last n lines are remembered and can be seen by scrolling.
+     Older lines are forgotten.
+     This limit can be changed by the userPreferences dialog"
+
+    DefaultLineLimit := numberOfLines
 !
 
 defaultTimeDelay
-    "the time in seconds to wait & collect by default"
+    "the time in seconds to wait & collect by default.
+     At most this number of seconds incoming text is buffered (without redrawing),
+     before a redraw is done. Thus, if a lot of output is generated fast,
+     the redrawing is performed in chunks. 
+     This has a significant effect on the performane, 
+     as the view does not have to scroll and redraw for each
+     individual line, but does junp-scrolling instead.
+     The value may be a float (eg. 0.5)
+     See also defaultCollectSize"
+
+    ^ DefaultTimeDelay ? 0.5 
+!
 
-    ^ 0.2 
+defaultTimeDelay:seconds
+    "the time in seconds to wait & collect by default.
+     At most this number of seconds incoming text is buffered (without redrawing),
+     before a redraw is done. Thus, if a lot of output is generated fast,
+     the redrawing is performed in chunks. 
+     This has a significant effect on the performane, 
+     as the view does not have to scroll and redraw for each
+     individual line, but does junp-scrolling instead.
+     The argument may be a float (eg. 0.5)
+     See also defaultCollectSize"
+
+    DefaultTimeDelay := seconds 
 !
 
 defaultTranscriptSize
@@ -521,7 +581,8 @@
 
 current
     "return the current (your screen's) transcript.
-     In multiDisplay applications, this need NOT be the main transcript.
+     In multiDisplay applications, this need NOT be the main transcript,
+     as each display may have its own transcript.
      But typically, this is the same as Transcript."
 
     |theTranscript app|
@@ -1184,11 +1245,11 @@
 !TextCollector class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg/TextCollector.st,v 1.140 2015-02-03 09:19:42 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/TextCollector.st,v 1.141 2015-03-02 12:15:58 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libwidg/TextCollector.st,v 1.140 2015-02-03 09:19:42 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/TextCollector.st,v 1.141 2015-03-02 12:15:58 cg Exp $'
 ! !