I am creating a label in my main.brs with CreateObject, which I thought would be fairly simple. However, it is not rendering, and I have no idea why.
This happens within a function where I create a VideoNode via CreateObject, and that seems to show up fine.
My code is:
label = CreateObject("roSGNode", "Label")
label.text = "EPISODES AVAILABLE"
label.translation="[50, 50]"
label.numlines="1"
label.color="0xFFFFFF"
label.id = "episodeslabel"
If I print label, I get this, which looks correct to me, but it just doesn't appear anywhere on the screen (as if visibility were false)! What am I missing?!
<Component: roSGNode:Label> =
{
color: -1
displayPartialLines: false
ellipsisText: ""
ellipsizeOnBoundary: false
font: <Component: roSGNode:Font>
height: 0
horizAlign: "left"
isTextEllipsized: false
lineSpacing: 8
maxLines: 0
numLines: 1
text: "EPISODES AVAILABLE"
truncateOnDelimiter: ""
vertAlign: "top"
width: 0
wordBreakChars: ""
wrap: false
childRenderOrder: "last"
clippingRect: <Component: roAssociativeArray>
enableRenderTracking: false
inheritParentOpacity: true
inheritParentTransform: true
muteAudioGuide: false
opacity: 1
renderPass: 0
renderTracking: "disabled"
rotation: 0
scale: <Component: roArray>
scaleRotateCenter: <Component: roArray>
translation: <Component: roArray>
visible: true
change: <Component: roAssociativeArray>
focusable: false
focusedChild: <Component: roInvalid>
id: "episodeslabel"
}