That one should be easy to implement...
You could do something like this...
SimplePanel container = new SimplePanel();
container.getElement().getStyle().setOverflow(Style.Overflow.HIDDEN);
Label label = new Label("Text that you want to scroll");
label.getElement().getStyle().setPosition(Style.Position.ABSOLUTE);
container.add(label);
private final Timer t = new Timer() {
@Override
public void run() {
label.getElement().getStyle().setLeft(Integer.parseInt(label.getElement.getStyle().getLeft()) - 10, Unit.PX);
}
};
t.scheduleRepeating(100);
This will move label to the left for 10px on every 100 miliseconds. So now in run() method just add math that is needed and that should be it.
PS. this might not work exactly as I typed it in, as I typed it in straight from my head without any checking, but the concept is valid.
Best,
Milan Cvejic