NAME EPS - Routines for creating Encapsulated-Postscript Images SYNOPSIS use EPS; p = EPS -> new(150, 100); # new image with 150x100 mm size q = p -> clone; # clone the image p p -> background(0,0,1); # blue to background (RGB values) p -> background(0,0,1,0,0,0); # color gradient blue-black p -> line([10,10],[20,10],[30,20]); p -> circle(50,20,15); p -> filled_circle(50,20,15); p -> polygon([20,20],[30,20],[40,40],[20,50]); p -> filled_polygon([20,20],[30,20],[40,40],[20,50]); p -> color(1,0.5,0); # setting RGB values p -> rawcode("0 0 moveto 20 10 lineto stroke"); p -> font('Helvetica',10); # setting font (10 pt size) p -> text('This is a left justified text','l'); p -> text('This is a centered text','c'); p -> text('This is a right justified text','r'); p -> any_postscript_command($a,$b,$c,$d); p -> Write("picture.eps"); DESCRIPTION This Perl package allows the creation of Encapsulated Postscript images (level 3) with a single color or a color gradient as background, containing simple shapes (as lines, polygons, circles etc.) and text. Additionally, any Postscript code can be included verbatim. All dimensions (except for the fontsize, which is given in points) are assumed to be millimeters. The methods stated above should be self-explanatory. Additional to those, any Postscript command can be declared as a method, which will be translated via AUTOLOAD into the respective Postscript command in the following way: p -> any_postscript_command($a,$b,$c,$d,...) is translated to $a $b $c $d ... any_postscript_command Thus, basic knowledge of the Postscript language is helpful. Examples p -> newpath; p -> setlinewidth(0.35); p -> translate(100,20); p -> scale(2,2); p -> rotate(45); p -> setrgbcolor(1,0.5,0); p -> moveto(10,10); p -> lineto(10,20); p -> stroke; ... etc. etc. ... VERSION EPS 1.0 (2002-03-25) AUTHOR Wilhelm Haager, HTL St.Poelten, Austria "(wilhelm.haager@htlstp.ac.at)" COPYRIGHT Copyright 2002, Wilhelm Haager This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.