Debian Codegraph @

tclpkg/gdtclft/examples/writePNGvar.tcl

raw
1 #!/bin/sh
2 # next line is a comment in tcl \
3 exec tclsh "$0" ${1+"$@"}
4
5 package require Gdtclft
6
7 set gd [gd create 200 200]
8 set white [gd color new $gd 255 255 255]
9 set black [gd color new $gd 0 0 0]
10 gd fillpolygon $gd $black 0 0 0 200 200 0
11 gd writePNGvar $gd foobar
12
13 fconfigure stdout -encoding binary
14 puts $foobar