Category:Guish: Difference between revisions
Content added Content deleted
No edit summary |
No edit summary |
||
Line 325: | Line 325: | ||
; '''=> <signal> <subcmd>''' |
; '''=> <signal> <subcmd>''' |
||
: register a sub-command <subcmd> to run when <signal> triggers. For normal signals (eg. signals tied to elements), there must exist an implied subject. |
: register a sub-command <subcmd> to run when <signal> triggers. For normal signals (eg. signals tied to elements), there must exist an implied subject. |
||
; '''global <var> = <val>''' |
; '''global <var> = [<val>]''' |
||
: defines a variable using the same rules of variable definition, but defining that variable in the global scope; this usually can be used inside functions to define a global variable which doesn't exist already. |
: defines a variable using the same rules of variable definition, but defining that variable in the global scope; this usually can be used inside functions to define a global variable which doesn't exist already. |
||
; '''q''' |
; '''q''' |
||
Line 335: | Line 335: | ||
; '''run <cmd>''' |
; '''run <cmd>''' |
||
: execute shell command <cmd>. |
: execute shell command <cmd>. |
||
; ''' |
; '''puts [<...>]''' |
||
: |
: prints remaining phrase to stdout with a newline added. |
||
; ''' |
; '''p [<...>]''' |
||
: |
: prints remaining phrase to stdout. |
||
; ''' |
; '''e [<...>]''' |
||
: |
: prints remaining phrase to stderr. |
||
; ''' |
; '''unset <name|num|wid> [<attr>]''' |
||
: unsets a variable (<name>) or timed scheduled procedure registered with <num>, see '''every''' command. If, instead of <name|num>, an element id <wid> is given and a name attribute <attr> is given, deletes that element attribute. |
|||
: print <arg> to stderr. |
|||
; '''unset <namescheduled num>''' |
|||
: unset variable or timed scheduled procedure registered with <num>, see '''every''' command. |
|||
; '''source <file>''' |
; '''source <file>''' |
||
: execute commands from file. |
: execute commands from file. |
||
; '''vars''' |
; '''vars [<wid>]''' |
||
: shows all variables present in the current scope or, if <wid> element id is given, shows all element attributes (uses stderr). |
|||
: display all variables on standard error. |
|||
; '''ls''' |
; '''ls''' |
||
: display all existing widgets |
: display all existing widgets (stderr). |
||
; '''del <wid>''' |
; '''del <wid>''' |
||
: delete a widget with id <wid>. |
: delete a widget with id <wid>. |
||
Line 636: | Line 634: | ||
<pre> |b||b||b|+ |
<pre> |b||b||b|+ |
||
puts *</pre> |
|||
== Variable substitution == |
== Variable substitution == |
||