# This file is a Tcl script to test out GIF reading and writing. # It is organized in the standard fashion for Tcl tests. # puts "img::xpm [package require img::xpm]" set xpmdata \ {/* XPM */ static char * InlineData[] = { "16 12 3 1", " s None c None", ". c #000000", "# c #f0ff80", " .... ", " .####. ", " .######. ", "............. ", ".###########. ", ".###########. ", ".###########. ", ".###########. ", ".###########. ", ".###########. ", ".###########. ", "............. "};} test xpm-1.1 {} { catch {image delete i} image create photo i -file [file join $tcltest::testsDirectory folder.xpm] i data -format xpm } $xpmdata test xpm-1.2 {} { catch {image delete i} image create photo i -data $xpmdata set data [i data -format xpm] } $xpmdata test xpm-1.3 {} { i blank i put $data set data [i data -format xpm] } $xpmdata test xpm-1.4 {} { i blank i put $data -format xpm set data [i data -format xpm] } $xpmdata