X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=chiark-tcl-applet.git;a=blobdiff_plain;f=example;h=bd05b1787c97e1eac55a04fbd26b9e3586f40613;hp=4edb4041a650e919ba539d0987e2bb3ea371c067;hb=4af7e789e3afd4b9a7afb81a6cde31c37386e5c4;hpb=37338efc873355a4ba7ec6994283e75a1fc1d7c3 diff --git a/example b/example index 4edb404..bd05b17 100755 --- a/example +++ b/example @@ -1,10 +1,13 @@ #!/usr/bin/wish8.4 -f # -*- Tcl -*- +# usage: +# xbatmon-simple-tray + source applet.tcl source subproc.tcl -#----- menu ----- +applet::setup-debug puts foreach b {1 3} { applet::setup-button-menu $b @@ -21,8 +24,9 @@ foreach b {1 3} { applet::setup-tooltip { puts VIS } { puts INVIS } applet::tooltip-set "line\nanother" -proc cmdline {id} { - return [list xacpi-simple -into $id] +proc cmdline {id orientation} { + global argv + return [concat $argv $id] } -applet::setup-subproc 40 darkblue 1 cmdline +applet::setup-subproc cmdline