#DOCUMENTATION by exept
authorClaus Gittinger <cg@exept.de>
Thu, 20 Feb 2020 10:52:26 +0100
changeset 8995 a54112003192
parent 8994 89309ccab456
child 8996 fa5b2f7727c1
#DOCUMENTATION by exept class: SimpleView comment/format in: #waitUntilVisible
SimpleView.st
--- a/SimpleView.st	Wed Feb 19 21:02:22 2020 +0100
+++ b/SimpleView.st	Thu Feb 20 10:52:26 2020 +0100
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
 "
  COPYRIGHT (c) 1989 by Claus Gittinger
 	      All Rights Reserved
@@ -11978,23 +11980,32 @@
         ].
     ].
 
-    "does not work (the view is in its opening phase,
-     when we attempt to draw a line - this gives an error, since
-     its internals are not yet correctly setup):
+    "Example where this is useful:
+     The following does not work, because the view is in its opening phase,
+     when we attempt to draw a line. 
+     This either gives an error or will be drawn into the void, since
+     its internals are not yet correctly setup 
+     (the view has its own async process, which gets forked with the open):
 
         |v|
 
         v := View new open.
         v displayLineFrom:0@0 to:50@50
 
-     does work (since we wait until the view has completely finished
-     its startup phase):
+     the following does work (since we wait until the view has completely finished its startup phase):
 
         |v|
 
         v := View new open.
         v waitUntilVisible.
         v displayLineFrom:0@0 to:50@50
+
+     or, a combined open and waitUntilVisible:
+
+        |v|
+
+        v := View new openAndWait.
+        v displayLineFrom:0@0 to:50@50.
     "
 
     "Modified: / 08-08-2010 / 14:46:34 / cg"