Home Segments Top Top Previous Next

888: Mainline

By arranging to call decrementPosition at regular intervals, you can ensure that the message will scroll from right to left.

Accordingly, you need to define a subclass of the Thread class—say MarqueeThread—that runs independently, and that calls decrementPosition, with the component as the target, at regular intervals.