<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <font face="Georgia">UpdatingStringMorph new <br>
      &nbsp;&nbsp;&nbsp; target: [World activeHand position asString]; <br>
      &nbsp;&nbsp;&nbsp; getSelector: #value; <br>
      &nbsp;&nbsp;&nbsp; stepTime: 10;<br>
      &nbsp;&nbsp;&nbsp; openInWorld<br>
      <br>
      Cheers,<br>
      Bob<br>
      <br>
    </font>
    <div class="moz-cite-prefix">On 1/3/13 9:50 PM, Ralph Boland wrote:<br>
    </div>
    <blockquote
cite="mid:CAPMV+mzbRCvTm1Bd=WERDe4ajN5hFuqY9pZ7=SZ92q7dH1f05g@mail.gmail.com"
      type="cite">
      <pre wrap="">I would like to create a small TextMorph that continuously displays the position
of the cursor.  To do this I need to write something of the form:

true whileTrue: [
    x := self getCursorPosition.
    textMorph display: x.
    self sleep:  10   "milliseconds"]

I plan to use this when investigating some morph that is not displaying the way
I expect it to.

Can someone provide me with hints as how to properly do this or point
me to a package that already does this or something similar?

I have searched the code and the Internet.  I found that "getCursorPosition"
can be implemented as:

     "World activeHand position"

 I can also figure out how to build the Morph I need to display the
Cursor position.

I don't know how to implement "sleep:"
I am not sure if I should use an infinite loop as I have.

An alternative to the TextMorph I want is to construct a cursor that
continuously displays its
position but I prefer my original plan.

Any help much appreciated.

Ralph Boland


</pre>
    </blockquote>
    <br>
  </body>
</html>