Re: Re: Ticker Tape/Theater Marquee Display?
- To: mathgroup at smc.vnet.net
- Subject: [mg21285] Re: [mg21232] Re: [mg20967] Ticker Tape/Theater Marquee Display?
- From: BobHanlon at aol.com
- Date: Tue, 21 Dec 1999 03:47:04 -0500 (EST)
- Sender: owner-wri-mathgroup at wolfram.com
I use a Macintosh. To abort (stop the scroll), I just repeatedly type Command-. (i.e., Command-period) until it aborts. I frequently find that it takes multiple abort commands to terminate a notebook calculation. I suspect that the abort command has to hit the kernel at a time when it is open to such a "suggestion." Bob Hanlon In a message dated 12/20/1999 4:24:30 AM, murray at math.umass.edu writes: >How can one get that loop actually to stop? Aborting the evaluation >doesn't seem to do it. The only way I could was to close the target >notebook. > >BobHanlon at aol.com wrote: >> >> The following will put the message in a continuous loop until aborted. >> >> w = 40; nb = NotebookCreate[]; >> >> s = "This string will scroll continuously across the screen--like a stock >\ >> market ticker tape--until aborted. " ; >> >> While[1 > 0, NotebookWrite[nb, StringTake[s, w]]; >> s = StringJoin[RotateLeft[Characters[s]]]; SelectionMove[nb, All, Cell];] >> >> To speed up the scrolling, remove your Pause statement. I don't believe >that >> Pause can delay less than $TimeUnit >> >> ?? $TimeUnit >> >> "$TimeUnit gives the minimum time interval in seconds \ >> recorded on your computer system." >> >> Attributes[$TimeUnit] = {Locked, Protected} >> >> $TimeUnit = Rational[1, 60] >> >> Bob Hanlon >> >> In a message dated 12/1/1999 3:44:45 AM, siegman at stanford.edu writes: >> >> >I'd like to have a small routine that would scroll a text message across >> >the screen inside a window, like a theater marquee or the old Times >Square >> >advertising displays or the stock markets quotes at the bottom of certain >> >television programs. >> > >> >The crude solution I've come up with is: >> > >> >s = "This is a test string that will be scrolled across the screen like >> >a >> >stock market ticker tape." ; >> > >> >w = 40; n = 1; >> >nb = NotebookCreate[]; >> >While[n <=StringLength[s] - w, >> > (NotebookWrite[nb, StringTake[s, {n, n+w}], After]; >> > Pause[0.00001]; >> > SelectionMove[nb, All, Cell]; >> > n = n + 1)] >> > >> >Can anyone suggest anything more sophisticated? Why does this version >> >scroll so slowly? Anyone know of a dot matrix type font that would >make >> >the output look more realistic? >