JSignage:TextTutorial8

From SpinetiX Support Wiki

Jump to: navigation, search

Description

Text of unknown length on one line

  • Finally there is a third method to display one line of text of unknown length: the pingPongTextArea.
  • It will automatically scroll the line to the left.

Source code

  $.textArea({ top: 100, right: 645, height: 48, textAlign: 'end', fontSize: 32, fontWeight: 'bold', fill: '#C0C040' }).text('Departure to:').addTo('svg');

$.pingPongTextArea({
        left: 640,
        width: 250,
        top: 100,
        height: 48,
        fontSize: 32,
        fontWeight: 'bold',
        fill: '#4040C0',
        delay: '500ms',
        speed: 50
}).text('Paris, London, New York, Los Angeles, Hong Kong, Buenos Aires').addTo('svg');

Preview

This page was last modified on 9 August 2017, at 17:21.