Initial values for scriptMenuStripRadio items in custom menu

   977   1   1
User Avatar
Member
15 posts
Joined: Feb. 2016
Offline
Hi there,

Does anyone know how to initialize the selection of a scriptMenuStripRadio item in a custom menu? I'm able to create it, and use the variableValues from it just fine, but when first opening the menu, none of the radio items are selected. I can't seem to find anything obvious in the docs [www.sidefx.com], and the built-in menus seem to do it magically*.

Side note - the same applied for setting scriptToggleItems to start enabled (1).

Thanks!


Edit: * from MainMenuMPlay.xml:
<menuStripRadio id = "anim_loop">
<value>loop.val</value>
<radioItem id = "loop"> <label>Loop</label></radioItem>
<radioItem id = "once"> <label>Play Once</label></radioItem>
<radioItem id = "zigzag"><label>Zig-Zag</label></radioItem>
Not exactly sure where
loop.val
comes from
Edited by jamesr - Feb. 6, 2021 23:52:04
User Avatar
Member
7 posts
Joined: Jan. 2024
Offline
Did you ever figure this out?

I am hitting the same thing, and none of the radio buttons is selected, which should never happen of course, as by definition, a radio button always has 1 selected.
  • Quick Links