velocity property

double velocity
final

The scrolling velocity in pixels per second.

If a negative velocity is provided, the marquee scrolls in the reverse direction (to the right for horizontal marquees and to the top for vertical ones).

Sample code

This marquee scrolls backwards with 1000 pixels per second:

Marquee(
  velocity: -1000.0,
  text: 'Gotta go fast in the reverse direction',
)

See also:

  • scrollAxis to change the axis in which the scrolling takes place.

Implementation

final double velocity;