Datasets for TV station

Hi. I’m using XIBO for my TV station. Since we want to implement datasets into the layouts for automating the TV content, we are dealing with having to split items if their text is too long.

I don’t know how to implement something that splits the content into two region timeline items, so we wanted to scroll the text up.

At first, the first lines of the text have to be readable and after around 5 seconds, the text should start to move up, to show the rest of the content.

This is what I have now as custom javascript at the dataset, but I am not sure how to fix the last bits…

The standard marquee up is too fast and starts immediately, also the full text is not visible at the start, so we decided to use our own custom javascript code…

It doesn’t give me error’s in Google Chrome debugger in preview mode (anymore lol), but it does also not scroll…

function funcOnload()
{
	// el = document.getElementById('#content div.item');
	el = $('#content div.item'); // https://community.xibo.org.uk/t/heres-how-to-show-as-many-ticker-items-as-will-fit/10675 // https://community.xibo.org.uk/t/why-isnt-my-javascript-responding-the-way-it-does-on-jsfiddle/10645/2
	if (!el)
	{
		alert('No!');
	}
	else
	{
		el.scrollTop(0);
		
		if (el.prop('scrollHeight') > 712)
		{
			// Wait a few moments to start scrolling (6 x 2.24 = 13.44)
			var delay = 80 * 28 * 6;
			// Scroll content, 2.24 seconds per line
			var i = 0;
			for (i = 0; i < el.prop('scrollHeight') - 713; i++)
			{
				// 28 pixels per line, 2.24 seconds per line -> old comments, pls ignore.
				setTimeout("el.scrollTop(" + i + ")", (i * 80) + delay);
			}
		}
		else
		{
			// el.style.height = 'auto';
			var delay = el.prop('scrollHeight') * 80;
			if (delay < 8000) 
			{
				delay = 8000;
			}
		}
	}
}
funcOnload();

You could try adjusting the speed to see if that can improve the playback.

As for the custom js, it is not something we’ve wrote or tested, but I’d expect it to work, you might want to execute that code on document ready though (unless you already do that).