This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
widget [2020/12/01 15:23] – justin | widget [2021/04/21 20:24] (current) – justin | ||
---|---|---|---|
Line 11: | Line 11: | ||
You can access and change certain element properties from within a [[script]] by simply referencing the parent [[widget]] and the child element by their unique IDs. The following example code assumes there is a [[widget]] with an ID of " | You can access and change certain element properties from within a [[script]] by simply referencing the parent [[widget]] and the child element by their unique IDs. The following example code assumes there is a [[widget]] with an ID of " | ||
- | This script will close the [[widget]] | + | This script will close the [[widget]], store the text that was entered into the [[text field]] |
<code bauxite> | <code bauxite> | ||
hide_widget(" | hide_widget(" | ||
$name = widget[" | $name = widget[" | ||
- | display_message(" | + | display_message(" |
</ | </ | ||
- | This script will change the text of the [[button]] to now be "New Text". | + | This script will change the text of the [[button]] to "New Text". |
<code bauxite> | <code bauxite> | ||
- | widget[" | + | widget[" |
</ | </ | ||
~~NOTOC~~ | ~~NOTOC~~ |