Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
jedashford
Channel Surfer

Very Slow MarkupList w/Fonts

When adding fonts to any label in a MarkupList I get a very slow scroll. Right now I only have an image, 3 labels and a button. When adding custom fonts/sizes for each label and the button, the UI slows very bad. To the point where it takes 1-2+ seconds to scroll. As soon as I remove the <font> nodes, its sped up to normal speed. I've tried to remove all node attributes such as translation, colors, alignments, ellips, wrap, etc.. Nothing makes a change except removing fonts. Unfortunately this makes the markuplist very ugly since we can't control the font or size. 

As a side note, even adding the system font attribute causes the same issue.
We dont see this issue on the Roku 4, but do on the express and roku 3. 

What are we doing wrong here? The markuplist must support fonts, right? Even adding one font on the screen kills the scroll speed significantly. Any ideas?

Here is one node example on the markuplist:


<Label id="itemDescription" color="0xF2FFFFFF" translation="[ 1000, 100 ]"
width="500" horizAlign="left" vertAlign="center" maxLines="4"
ellipsizeOnBoundary="true" wrap="true">
<Font role="font" uri="pkg:/fonts/AzoSans-regular.ttf" size="24" />
</Label>
0 Kudos
3 REPLIES 3
jedashford
Channel Surfer

Re: Very Slow MarkupList w/Fonts

Additonal information. Any font added to any visible screen slows the entire UI. Meaning even the roku keyboard takes seconds to move the cursor to each letter. This doesn't happen on the Roku 4, but does on the Roku 3. If I don't get a reply from anyone else who has seen/worked around this issue, I'll recreate this with the Roku scene graph example package and upload.
0 Kudos
Veeta
Visitor

Re: Very Slow MarkupList w/Fonts

This doesn't sound normal and is probably due to an unintended side-effect, like the observers for "focusPercent" are doing more than you expected.  The SimpleMarkupList example from Roku has text in its components.  See here https://sdkdocs.roku.com/display/sdkdoc/MarkupList
0 Kudos
jedashford
Channel Surfer

Re: Very Slow MarkupList w/Fonts

We answered this...

In some version of the firmware, Roku added "loadWidth" and "loadHeight" to the poster node . We don't know which version, but using WayBackMachine on this page indicates it was added sometime in the past year. Our images were coming through larger than the bounding boxes and were slowing the UI. For some reason the fonts made the UI completely unusable. Once we scaled the images down using the load* values, then our UI sped up a lot. hopefully this helps the next group of developers who are fighting their way through... [/font][/color][/font][/color]
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.