Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 9

Fixed width-height Scenegraph Button

I want to populate a button with image coming from API, i've set the minWidth and maxWidth to be "64" but whenever I populate the iconUri with image from server, the button just grows in size. How can I prevent this?

0 Kudos
2 Replies
Roku Employee
Roku Employee

Re: Fixed width-height Scenegraph Button

Hi @mramim,

Can you provide the XML/BrightScript code for your Button node. 

0 Kudos
Level 9

Re: Fixed width-height Scenegraph Button

Sure, I've a button group that holds multiple buttons with different ids, and they all have a placeholder iconUri and focusedIconUri, my intention is to change these icons with a network Image that I receive from the API(that image is not always 64px)




<Button id="id1" minWidth="64" maxWidth="64"
height="64" text=""
focusedIconUri="pkg:/images/2_quality.png" />



On the brightscript side of the code, I've a task that loads info from api and then I just try to set the field 

m.btn1.iconUri =
m.btn1.focusedIconUri =


Let me know if you need any other information.

0 Kudos