1 TGD

        Produce GIF files from text description
        
        tgd file
        
        File is a plain text file describing the contents of the gif 
        file to be created.

2 Commands

  arc --  arc handle x y width height start_degree end_degree color
  
  blue -- blue handle color
          Prints blue value of color
          
  boundssafe -- boundssafe handle x y
                Print "1" if x,y is within the image, "0" otherwise.
                
  char -- char handle font x y character color
  
  charup -- char handle font x y character color
  
  checksyntax -- checksyntax
                 checksyntax stops command processing but continues
                 checking the syntax of the lines in the rest of the
                 file.
                 
  colorallocate -- colorallocate handle color red_val green_val blue_val
                   n.b. the first color allocated is the background color
                   
  colorclosest -- colorclosest handle red_val green_val blue_val
                  (ouputs color)
  
  colordeallocate -- colordeallocate handle color
  
  colorexact -- colorexact handle red_val green_val blue_val 
                (ouputs color or string "-1" )
  colorstotal -- colorstotal handle
  
  colortransparent -- colortransparent color
  
  copy -- copy handle_to handle_from x_to y_to x_from y_from width height
  
  copyresized -- copyresized handle_to handle_from x_to y_to x_from y_from 
                             width_to height_to width_from height_from
                             
  create -- create handle width height
  
  createfromgd -- createfromgd handle filename
  
  createfromgif -- createfromgif handle filename
  
  createfromxbm -- createfromxbm handle filename
  
  dashedline -- dashedline handle x1 y1 x2 y2
  
  debug -- debug debug_level
           For debugging output try debug 2001.
           
  destroy -- destroy handle
  
  fill -- fill handle x y color
  
  filltoborder -- filltoborder handle x y border_color fill_color
  
  filledpolygon -- filledpolygon handle x1 y1  x2 y2 ... xN yN N color
  
  filledrectangle -- filledrectangle handle x1 y1 x2 y2 color
  
  gd -- gd handle filename 
       (if filename is stdout, tgd writes to standard output)
       
  getinterlaced -- getinterlaced handle
                   Print "1" if interlaced, "0" otherwise.
  getpixel -- getpixel handle x y
              prints color of pixel x,y.
              
  gettransparent -- gettransparent handle
                    Prints name of transparent color for this image,
                    "-1" if none.
                    
  gif -- gif handle filename 
        (if filename is stdout, tgd writes to standard output)
        
  green -- green handle color
           Prints green value for color.
           
  interlace -- interlace handle N
               if N = 1, interlace the image, if N = 0, do not.
               
  line -- line handle x1 y1 x2 y2 color
  
  polygon -- polygon handle x1 y1  x2 y2 ... xN yN N color
  
  rectangle -- rectangle handle x1 y1 x2 y2 color
  
  red -- red handle color
         Prints red value for color.
         
  setbrush -- setbrush handle brush
  
  setpixel -- setpixel handle x y color
  
  setstyle -- setstyle handle XXX
  
  settile -- settile handle tile
  
  stockimage -- stockimage handle N
  
  string -- string handle font x y s color
  
  stringup -- stringup handle font x y s color
  
  stringcenter -- stringcenter handle f x y s c
                  Write string s using font f in color c centered at
                  the pixel x,y.
                  
  sx -- sx handle
        Prints width of image in pixels. 
        
  sy -- sy handle
        Prints height of image in pixels.

2 Example 

    create myimage 200 100
    colorallocate myimage white 255 255 255
    colorallocate myimage black 0 0 0
    string myimage gdFontLarge 40 40 "hello, world!" black
    gif myimage helloworld.gif
