From owner-freebsd-ports Wed Apr 3 11: 3:26 2002 Delivered-To: freebsd-ports@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 6C7A637B417 for ; Wed, 3 Apr 2002 11:00:02 -0800 (PST) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g33J02u48685; Wed, 3 Apr 2002 11:00:02 -0800 (PST) (envelope-from gnats) Received: from astart2.astart.com (tcubed-gw.access.nethere.net [216.188.53.211]) by hub.freebsd.org (Postfix) with ESMTP id 4CE7937B400 for ; Wed, 3 Apr 2002 10:53:57 -0800 (PST) Received: from h110.private (h110.private [10.0.0.110]) by astart2.astart.com (8.11.6/8.11.6) with ESMTP id g33IruE48187 for ; Wed, 3 Apr 2002 10:53:56 -0800 (PST) (envelope-from papowell@astart.com) Received: (from papowell@localhost) by h110.private (8.11.3/8.11.3) id g33Irur38049; Wed, 3 Apr 2002 10:53:56 -0800 (PST) (envelope-from papowell) Message-Id: <200204031853.g33Irur38049@h110.private> Date: Wed, 3 Apr 2002 10:53:56 -0800 (PST) From: papowell@lprng.com Reply-To: papowell@lprng.com To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: ports/36702: pic2fig port update for FreeBSD-5prerelease Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 36702 >Category: ports >Synopsis: pic2fig port update for FreeBSD-5prerelease >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed Apr 03 11:00:01 PST 2002 >Closed-Date: >Last-Modified: >Originator: Patrick Powell >Release: FreeBSD 4.3-RELEASE i386 >Organization: LPRng.com >Environment: System: FreeBSD h110.private 4.3-RELEASE FreeBSD 4.3-RELEASE #0: Sat Apr 21 10:54:49 GMT 2001 jkh@narf.osd.bsdi.com:/usr/src/sys/compile/GENERIC i386 >Description: compiled existing port under FreeBSD-5prerelease, compilation problems noted. In addition, some files were added to explain the format for the previous changes. The 'patches' files were redone against the various files that were changed so that you did not have a 'patch' of a 'patch'. >How-To-Repeat: compile it... >Fix: This patch is against the FreeBSD-5prerelease ISO image downloaded 2 April 2002. In addition, I am enclosing the SHAR of the pic2fig port. ----- diffs ----- diff -rNu /usr/ports/print/pic2fig/Makefile pic2fig/Makefile --- /usr/ports/print/pic2fig/Makefile Sat Feb 9 16:56:56 2002 +++ pic2fig/Makefile Wed Apr 3 10:46:39 2002 @@ -6,7 +6,7 @@ PORTNAME= pic2fig PORTVERSION= 1.4 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= print MASTER_SITES= ${MASTER_SITE_XCONTRIB} MASTER_SITE_SUBDIR= utilities diff -rNu /usr/ports/print/pic2fig/README.html pic2fig/README.html --- /usr/ports/print/pic2fig/README.html Sun Mar 3 00:14:42 2002 +++ pic2fig/README.html Wed Dec 31 16:00:00 1969 @@ -1,30 +0,0 @@ - - The FreeBSD Ports Collection (print/pic2fig) -

The FreeBSD Ports Collection ("print/pic2fig")


- - -

You are now in the directory for the port "print/pic2fig" (package name "pic2fig-1.4_1"). - -

This is the one-line description for this port: - -


-Pic format to fig format converter -


- -

Please read the "description file" for a -longer description. - -

Go to the top of the ports tree for -a summary on how to use the ports collection. - -

- -

- - -


- Go up one level -| - Go to top of ports tree - - diff -rNu /usr/ports/print/pic2fig/files/patch-aa pic2fig/files/patch-aa --- /usr/ports/print/pic2fig/files/patch-aa Tue Jan 16 15:01:57 2001 +++ pic2fig/files/patch-aa Wed Apr 3 10:42:06 2002 @@ -1,21 +1,566 @@ ---- Makefile.orig Mon Apr 29 10:11:02 1991 -+++ Makefile Tue Jan 16 08:26:36 2001 -@@ -1,7 +1,7 @@ - BINDIR = /usr/local/bin --CFLAGS = -O4 -s $(CROSS) -+#CFLAGS = -O4 -s $(CROSS) - #LDFLAGS= -zs --LDFLAGS= -z $(CROSS) -+#LDFLAGS= -z $(CROSS) - YFLAGS = -d - - MOFILES = main.o boxgen.o print.o misc.o symtab.o blockgen.o circgen.o \ -@@ -29,7 +29,7 @@ - -@echo "" - - pic2fig: picy.o picl.o $(OFILES) -- cc $(LDFLAGS) -o $@ picy.o picl.o $(OFILES) -lm -+ $(CC) $(LDFLAGS) -o $@ picy.o picl.o $(OFILES) -lm - - # The following .o files depend of picy.c, since they really need picy.h - picl.o: picl.c pic.h picy.c +--- FORMAT3.2.orig Wed Apr 3 10:27:14 2002 ++++ FORMAT3.2 Wed Apr 3 10:27:14 2002 +@@ -0,0 +1,563 @@ ++/* ++ * FIG : Facility for Interactive Generation of figures ++ * Copyright (c) 1985 by Supoj Sutanthavibul ++ * Parts Copyright (c) 1989-1999 by Brian V. Smith ++ * Parts Copyright (c) 1991 by Paul King ++ * Parts Copyright (c) 1995 by C. Blanc and C. Schlick ++ * ++ * The X Consortium, and any party obtaining a copy of these files from ++ * the X Consortium, directly or indirectly, is granted, free of charge, a ++ * full and unrestricted irrevocable, world-wide, paid up, royalty-free, ++ * nonexclusive right and license to deal in this software and ++ * documentation files (the "Software"), including without limitation the ++ * rights to use, copy, modify, merge, publish, distribute, sublicense, ++ * and/or sell copies of the Software, and to permit persons who receive ++ * copies from any such party to do so, with the only requirement being ++ * that this copyright notice remain intact. This license includes without ++ * limitation a license to do the foregoing actions under any patents of ++ * the party supplying this software to the X Consortium. ++ */ ++ ++The new components in protocol 3.2 are the paper size, magnification, ++single/multiple page indicator and transparent color for GIF export in the ++header. ++ ++The other modification between version 3.1 and version 3.2 of the ++protocol is the mathematical model used for splines. The new version ++uses X-splines which allows the user to mix interpolation and approximation ++points in a same curve. More precisely, it means that an X-spline curve ++is neither an interpolated spline nor an approximated one, it is BOTH ++(the behaviour of each point is controlled by one single parameter ++called "shape factor"). For additional information about X-splines, see: ++ ++ "X-Splines: A Spline Model Designed for the End User" ++ by C. Blanc and C. Schlick, Proceedings of SIGGRAPH'95 ++ ++Caveat: Because spline models of previous versions (quadratic B-splines ++and Bezier with hidden points) are no longer supported, curves that are ++present in version 3.1 and older files are automatically converted to ++X-splines. This translation is only an approximation process. It means ++that the converted curves are not exactly the same as the original ones. ++Though the translation usually provides almost identical curves, some ++hand-fitting may be needed in some pathological cases. ++ ++------------------------------------------------------------------------------- ++Description of the Fig Format Follows ++------------------------------------------------------------------------------- ++ ++(1) The very first line is a comment line containing the name and version: ++ #FIG 3.2 ++ ++ The character # at the first column of a line indicates that the line ++ is a comment line which will be preserved when the Fig file is read in. ++ The user may edit them with the popup editor. ++ ++ The comment line(s) must immediately precede the object to which they ++ are associated. In the case of the "whole figure comments" mentioned ++ below, they immediately precede the (resolution,coord_system) line. ++ ++(2) The first non-comment line consists of the following: ++ ++ string orientation ("Landscape" or "Portrait") ++ string justification ("Center" or "Flush Left") ++ string units ("Metric" or "Inches") ++ string papersize ("Letter", "Legal", "Ledger", "Tabloid", ++ "A", "B", "C", "D", "E", ++ "A4", "A3", "A2", "A1", "A0" and "B5") ++ float magnification (export and print magnification, %) ++ string multiple-page ("Single" or "Multiple" pages) ++ int transparent color (color number for transparent color for GIF ++ export. -3=background, -2=None, -1=Default, ++ 0-31 for standard colors or 32- for user colors) ++ # optional comment (An optional set of comments may be here, ++ which are associated with the whole figure) ++ int resolution coord_system (Fig units/inch and coordinate system: ++ 1: origin at lower left corner (NOT USED) ++ 2: upper left) ++ ++ Fig_resolution is the resolution of the figure in the file. ++ Xfig will always write the file with a resolution of 1200ppi so it ++ will scale the figure upon reading it in if its resolution is different ++ from 1200ppi. Pixels are assumed to be square. ++ ++ Xfig will read the orientation string and change the canvas to match ++ either the Landscape or Portrait mode of the figure file. ++ ++ The units specification is self-explanatory. ++ ++ The coordinate_system variable is ignored - the origin is ALWAYS the ++ upper-left corner. ++ ++ ** Coordinates are given in "fig_resolution" units. ++ ** Line thicknesses are given in 1/80 inch (0.3175mm) or 1 screen pixel. ++ When exporting to EPS, PostScript or any bitmap format (e.g. GIF), the ++ line thickness is reduced to 1/160 inch (0.159mm) to "lighten" the look. ++ ** dash-lengths/dot-gaps are given in 80-ths of an inch. ++ ++ ++(3) The rest of the file contains various objects. An object can be one ++ of six classes (or types). ++ ++ 0) Color pseudo-object. ++ 1) Arc. ++ 2) Ellipse which is a generalization of circle. ++ 3) Polyline which includes polygon and box. ++ 4) Spline which includes ++ closed/open approximated/interpolated/x-spline spline. ++ 5) Text. ++ 6) Compound object which is composed of one or more objects. ++ ++ In the following elaboration on object formats, every value of fig ++ output are separated by blank characters or new line ('\n'). The ++ value of the unused parameters will be -1. ++ ++ Some fields are described as "enumeration type" or "bit vector"; the ++ values which these fields can take are defined in the header file object.h. ++ The pen_style field is unused. ++ These values may be defined in some future version of Fig. ++ ++ The two color fields (pen and fill; pen only, for texts) are ++ defined as follows: ++ ++ -1 = Default ++ 0 = Black ++ 1 = Blue ++ 2 = Green ++ 3 = Cyan ++ 4 = Red ++ 5 = Magenta ++ 6 = Yellow ++ 7 = White ++ 8-11 = four shades of blue (dark to lighter) ++ 12-14 = three shades of green (dark to lighter) ++ 15-17 = three shades of cyan (dark to lighter) ++ 18-20 = three shades of red (dark to lighter) ++ 21-23 = three shades of magenta (dark to lighter) ++ 24-26 = three shades of brown (dark to lighter) ++ 27-30 = four shades of pink (dark to lighter) ++ 31 = Gold ++ ++ values from 32 to 543 (512 total) are user colors and ++ are defined in color pseudo-objects (type 0) ++ ++ Your X server may limit the number of colors to something less ++ than this, especially on a 8-bit PseudoColor visual, where ++ the number of usable colors will be 256 minus the number of colors ++ xfig preallocates for itself and the 32 standard colors (about 48). ++ ++ For WHITE color, the area fill field is defined as follows: ++ ++ -1 = not filled ++ 0 = black ++ ... values from 1 to 19 are shades of grey, from darker to lighter ++ 20 = white ++ 21-40 not used ++ 41-56 see patterns for colors, below ++ ++ For BLACK or DEFAULT color, the area fill field is defined as follows: ++ ++ -1 = not filled ++ 0 = white ++ ... values from 1 to 19 are shades of grey, from lighter to darker ++ 20 = black ++ 21-40 not used ++ 41-56 see patterns for colors, below ++ ++ For all other colors, the area fill field is defined as follows: ++ ++ -1 = not filled ++ 0 = black ++ ... values from 1 to 19 are "shades" of the color, from darker to lighter. ++ A shade is defined as the color mixed with black ++ 20 = full saturation of the color ++ ... values from 21 to 39 are "tints" of the color from the color to white. ++ A tint is defined as the color mixed with white ++ 40 = white ++ 41 = 30 degree left diagonal pattern ++ 42 = 30 degree right diagonal pattern ++ 43 = 30 degree crosshatch ++ 44 = 45 degree left diagonal pattern ++ 45 = 45 degree right diagonal pattern ++ 46 = 45 degree crosshatch ++ 47 = horizontal bricks ++ 48 = vertical bricks ++ 49 = horizontal lines ++ 50 = vertical lines ++ 51 = crosshatch ++ 52 = horizontal "shingles" skewed to the right ++ 53 = horizontal "shingles" skewed to the left ++ 54 = vertical "shingles" skewed one way ++ 55 = vertical "shingles"skewed the other way ++ 56 = fish scales ++ 57 = small fish scales ++ 58 = circles ++ 59 = hexagons ++ 60 = octagons ++ 61 = horizontal "tire treads" ++ 62 = vertical "tire treads" ++ ++ The depth field is defined as follows: ++ ++ 0 ... 999 where larger value means object is deeper than (under) ++ objects with smaller depth ++ ++ The line_style field is defined as follows: ++ ++ -1 = Default ++ 0 = Solid ++ 1 = Dashed ++ 2 = Dotted ++ 3 = Dash-dotted ++ 4 = Dash-double-dotted ++ 5 = Dash-triple-dotted ++ ++ The style_val field is defined as the length, in 1/80 inches, of the on/off ++ dashes for dashed lines, and the distance between the dots, in 1/80 inches, ++ for dotted lines. ++ ++ The join_style field is defined FOR LINES only as follows: ++ ++ 0 = Miter (the default in xfig 2.1 and earlier) ++ 1 = Round ++ 2 = Bevel ++ ++ The cap_style field is defined FOR LINES, OPEN SPLINES and ARCS only as follows: ++ ++ 0 = Butt (the default in xfig 2.1 and earlier) ++ 1 = Round ++ 2 = Projecting ++ ++ The arrow_type field is defined for LINES, ARCS and OPEN SPLINES ++ only as follows: ++ ++ 0 = Stick-type (the default in xfig 2.1 and earlier) ++ ++ \ ++ \ ++ _______________\ ++ / ++ / ++ / ++ ++ 1 = Closed triangle: ++ ++ |\ ++ | \ ++ ________| \ ++ | / ++ | / ++ |/ ++ ++ 2 = Closed with "indented" butt: ++ ++ |\ ++ \ \ ++ \ \ ++ __________\ \ ++ / / ++ / / ++ / / ++ |/ ++ ++ 3 = Closed with "pointed" butt: ++ ++ /\ ++ / \ ++ / \ ++ ________/ \ ++ \ / ++ \ / ++ \ / ++ \/ ++ ++ The arrow_style field is defined for LINES, ARCS and OPEN SPLINES ++ only as follows: ++ ++ 0 = Hollow (actually filled with white) ++ 1 = Filled with pen_color ++ ++(3.0) OBJECT DEFINITION: ++ ++ (3.1) Color Pseudo-objects (user-defined colors) ++ This is used to define arbitrary colors beyond the 32 standard colors. ++ The color objects must be defined before any other Fig objects. ++ ++ First line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int object_code (always 0) ++ int color_number (color number, from 32-543 (512 total)) ++ hex string rgb values (hexadecimal string describing red, ++ green and blue values (e.g. #330099) ) ++ ++ (3.2) ARC ++ ++ First line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int object_code (always 5) ++ int sub_type (1: open ended arc ++ 2: pie-wedge (closed) ) ++ int line_style (enumeration type) ++ int line_thickness (1/80 inch) ++ int pen_color (enumeration type, pen color) ++ int fill_color (enumeration type, fill color) ++ int depth (enumeration type) ++ int pen_style (pen style, not used) ++ int area_fill (enumeration type, -1 = no fill) ++ float style_val (1/80 inch) ++ int cap_style (enumeration type) ++ int direction (0: clockwise, 1: counterclockwise) ++ int forward_arrow (0: no forward arrow, 1: on) ++ int backward_arrow (0: no forward arrow, 1: on) ++ float center_x, center_y (center of the arc) ++ int x1, y1 (Fig units, the 1st point the user entered) ++ int x2, y2 (Fig units, the 2nd point) ++ int x3, y3 (Fig units, the last point) ++ ++ Forward arrow line (Optional; absent if forward_arrow is 0): ++ type name (brief description) ++ ---- ---- ------------------- ++ int arrow_type (enumeration type) ++ int arrow_style (enumeration type) ++ float arrow_thickness (1/80 inch) ++ float arrow_width (Fig units) ++ float arrow_height (Fig units) ++ ++ Backward arrow line (Optional; absent if backward_arrow is 0): ++ type name (brief description) ++ ---- ---- ------------------- ++ int arrow_type (enumeration type) ++ int arrow_style (enumeration type) ++ float arrow_thickness (1/80 inch) ++ float arrow_width (Fig units) ++ float arrow_height (Fig units) ++ ++ (3.3) COMPOUND ++ ++ A line with object code 6 signifies the start of a compound. ++ There are four more numbers on this line which indicate the ++ upper left corner and the lower right corner of the bounding ++ box of this compound. A line with object code -6 signifies ++ the end of the compound. Compound may be nested. ++ ++ First line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int object_code (always 6) ++ int upperleft_corner_x (Fig units) ++ int upperleft_corner_y (Fig units) ++ int lowerright_corner_x (Fig units) ++ int lowerright_corner_y (Fig units) ++ ++ Subsequent lines: ++ objects ++ . ++ . ++ ++ Last line: ++ -6 ++ ++ (3.4) ELLIPSE ++ ++ First line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int object_code (always 1) ++ int sub_type (1: ellipse defined by radii ++ 2: ellipse defined by diameters ++ 3: circle defined by radius ++ 4: circle defined by diameter) ++ int line_style (enumeration type) ++ int thickness (1/80 inch) ++ int pen_color (enumeration type, pen color) ++ int fill_color (enumeration type, fill color) ++ int depth (enumeration type) ++ int pen_style (pen style, not used) ++ int area_fill (enumeration type, -1 = no fill) ++ float style_val (1/80 inch) ++ int direction (always 1) ++ float angle (radians, the angle of the x-axis) ++ int center_x, center_y (Fig units) ++ int radius_x, radius_y (Fig units) ++ int start_x, start_y (Fig units; the 1st point entered) ++ int end_x, end_y (Fig units; the last point entered) ++ ++ (3.5) POLYLINE ++ ++ First line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int object_code (always 2) ++ int sub_type (1: polyline ++ 2: box ++ 3: polygon ++ 4: arc-box) ++ 5: imported-picture bounding-box) ++ int line_style (enumeration type) ++ int thickness (1/80 inch) ++ int pen_color (enumeration type, pen color) ++ int fill_color (enumeration type, fill color) ++ int depth (enumeration type) ++ int pen_style (pen style, not used) ++ int area_fill (enumeration type, -1 = no fill) ++ float style_val (1/80 inch) ++ int join_style (enumeration type) ++ int cap_style (enumeration type, only used for POLYLINE) ++ int radius (1/80 inch, radius of arc-boxes) ++ int forward_arrow (0: off, 1: on) ++ int backward_arrow (0: off, 1: on) ++ int npoints (number of points in line) ++ ++ Forward arrow line: same as ARC object ++ ++ Backward arrow line: same as ARC object ++ ++ Points line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int x1, y1 (Fig units) ++ int x2, y2 (Fig units) ++ . ++ . ++ int xnpoints ynpoints (this will be the same as the 1st ++ point for polygon and box) ++ ++ PIC line: ++ type name (brief description) ++ ---- ---- ------------------- ++ boolean flipped orientation = normal (0) or flipped (1) ++ char file[] name of picture file to import ++ ++ (3.6) SPLINE ++ ++ First line: ++ type name (brief description) ++ ---- ---- ------------------- ++ int object_code (always 3) ++ int sub_type (0: open approximated spline ++ 1: closed approximated spline ++ 2: open interpolated spline ++ 3: closed interpolated spline ++ 4: open x-spline ++ 5: closed x-spline) ++ int line_style (See the end of this section) ++ int thickness (1/80 inch) ++ int pen_color (enumeration type, pen color) ++ int fill_color (enumeration type, fill color) ++ int depth (enumeration type) ++ int pen_style (pen style, not used) ++ int area_fill (enumeration type, -1 = no fill) ++ float style_val (1/80 inch) ++ int cap_style (enumeration type, only used for open splines) ++ int forward_arrow (0: off, 1: on) ++ int backward_arrow (0: off, 1: on) ++ int npoints (number of control points in spline) ++ ++ Forward arrow line: same as ARC object ++ ++ Backward arrow line: same as ARC object ++ ++ Points line: same as POLYLINE object ++ ++ Control points line : ++ ++ There is one shape factor for each point. The value of this factor ++ must be between -1 (which means that the spline is interpolated at ++ this point) and 1 (which means that the spline is approximated at ++ this point). The spline is always smooth in the neighbourhood of a ++ control point, except when the value of the factor is 0 for which ++ there is a first-order discontinuity (i.e. angular point). ++ ++ (3.7) TEXT ++ type name (brief description) ++ ---- ---- ------------------- ++ int object (always 4) ++ int sub_type (0: Left justified ++ 1: Center justified ++ 2: Right justified) ++ int color (enumeration type) ++ int depth (enumeration type) ++ int pen_style (enumeration , not used) ++ int font (enumeration type) ++ float font_size (font size in points) ++ float angle (radians, the angle of the text) ++ int font_flags (bit vector) ++ float height (Fig units) ++ float length (Fig units) ++ int x, y (Fig units, coordinate of the origin ++ of the string. If sub_type = 0, it is ++ the lower left corner of the string. ++ If sub_type = 1, it is the lower ++ center. Otherwise it is the lower ++ right corner of the string.) ++ char string[] (ASCII characters; starts after a blank ++ character following the last number and ++ ends before the sequence '\001'. This ++ sequence is not part of the string. ++ Characters above octal 177 are ++ represented by \xxx where xxx is the ++ octal value. This permits fig files to ++ be edited with 7-bit editors and sent ++ by e-mail without data loss. ++ Note that the string may contain '\n'.) ++ ++ The font_flags field is defined as follows: ++ ++ Bit Description ++ ++ 0 Rigid text (text doesn't scale when scaling compound objects) ++ 1 Special text (for LaTeX) ++ 2 PostScript font (otherwise LaTeX font is used) ++ 3 Hidden text ++ ++ The font field is defined as follows: ++ ++ For font_flags bit 2 = 0 (LaTeX fonts): ++ ++ 0 Default font ++ 1 Roman ++ 2 Bold ++ 3 Italic ++ 4 Sans Serif ++ 5 Typewriter ++ ++ For font_flags bit 2 = 1 (PostScript fonts): ++ ++ (.ft value) ++ -1 Default font ++ 0 Times Roman ++ 1 Times Italic ++ 2 Times Bold ++ 3 Times Bold Italic ++ 4 AvantGarde Book ++ 5 AvantGarde Book Oblique ++ 6 AvantGarde Demi ++ 7 AvantGarde Demi Oblique ++ 8 Bookman Light ++ 9 Bookman Light Italic ++ 10 Bookman Demi ++ 11 Bookman Demi Italic ++ 12 Courier ++ 13 Courier Oblique ++ 14 Courier Bold ++ 15 Courier Bold Oblique ++ 16 Helvetica ++ 17 Helvetica Oblique ++ 18 Helvetica Bold ++ 19 Helvetica Bold Oblique ++ 20 Helvetica Narrow ++ 21 Helvetica Narrow Oblique ++ 22 Helvetica Narrow Bold ++ 23 Helvetica Narrow Bold Oblique ++ 24 New Century Schoolbook Roman ++ 25 New Century Schoolbook Italic ++ 26 New Century Schoolbook Bold ++ 27 New Century Schoolbook Bold Italic ++ 28 Palatino Roman ++ 29 Palatino Italic ++ 30 Palatino Bold ++ 31 Palatino Bold Italic ++ 32 Symbol ++ 33 Zapf Chancery Medium Italic ++ 34 Zapf Dingbats diff -rNu /usr/ports/print/pic2fig/files/patch-ab pic2fig/files/patch-ab --- /usr/ports/print/pic2fig/files/patch-ab Wed Apr 3 08:08:00 2002 +++ pic2fig/files/patch-ab Wed Apr 3 10:42:06 2002 @@ -1,489 +1,21 @@ ---- figd.c.orig Sat Aug 6 19:52:43 1988 -+++ figd.c Wed Feb 6 15:54:17 2002 -@@ -6,13 +6,16 @@ - * - * Modified by Micah Beck to produce Fig code - * Modified by Micah Beck again to produce Fig 1.4 code -+ * Modified by Patrick Powell to produce Fig 3.2 code - */ +--- Makefile.orig Mon Apr 29 10:11:02 1991 ++++ Makefile Wed Apr 3 10:27:14 2002 +@@ -1,7 +1,7 @@ + BINDIR = /usr/local/bin +-CFLAGS = -O4 -s $(CROSS) ++#CFLAGS = -O4 -s $(CROSS) + #LDFLAGS= -zs +-LDFLAGS= -z $(CROSS) ++#LDFLAGS= -z $(CROSS) + YFLAGS = -d + + MOFILES = main.o boxgen.o print.o misc.o symtab.o blockgen.o circgen.o \ +@@ -29,7 +29,7 @@ + -@echo "" + + pic2fig: picy.o picl.o $(OFILES) +- cc $(LDFLAGS) -o $@ picy.o picl.o $(OFILES) -lm ++ $(CC) $(LDFLAGS) -o $@ picy.o picl.o $(OFILES) -lm - #include - #include - #include "object.h" - --#define DEF_PEN_SIZE 8 /* Default pen diameter */ -+/* #define DEF_PEN_SIZE 8 / * Default pen diameter */ -+#define DEF_PEN_SIZE 1 /* Default pen diameter */ -+#define DEF_FONT_SIZE 12 /* Default pen diameter */ - #define MAXPOINTS 300 /* Max number of points in a path */ - - #define bool int -@@ -23,6 +26,8 @@ - #define P_BLACK 15 - #define TEXTURE 3 - #define ORTEXTURE 7 -+#define FONT_HT 12 -+#define FONT_WIDTH 8 - - extern double sqrt(), cos(), sin(); - -@@ -31,11 +36,15 @@ - #define RES 1000.0 - #define Pix_To_In(x) (((float) x) / RES) - --#define FIGRES 80 -+/* #define FIGRES 80 */ -+#define FIGRES 1200 - #define FIGCANV_W (8*FIGRES) - #define FIGCANV_H (10*FIGRES) -+#define Points_To_Figpix(x) ((int)(FIGRES * (x)/72.0)) - #define Pix_To_Figpix(x) ((int)(FIGRES * Pix_To_In(x))) --#define Pen_to_Figpix(x) ((x*FIGRES + 500) / 1000) -+/* #define Pen_to_Figpix(x) ((x*FIGRES + 500) / 1000) */ -+/* pen thickness in 1/80 of inch */ -+#define Pen_to_Figpix(x) ((Pix_To_In(x) + 79) / 80) - - - extern int dbg; /* Non-zero when debugging info wanted */ -@@ -44,7 +53,8 @@ - static float xslope,yslope,xbase,ybase;/* Convert Window to Viewport */ - static int arraylen; /* Number of points in current path */ - static bool pathsent; /* True if path has been defined */ --static int ipensize; /* Desired current pen size */ -+static int ipensize = DEF_PEN_SIZE; /* Desired current pen size */ -+static int ifontsize = DEF_FONT_SIZE; /* Desired current font size */ - extern FILE *TEXFILE; /* Output file */ - - -@@ -62,7 +72,7 @@ - yslope = RES * (hiypage-loypage) / (hiy-loy); - ybase = RES * loypage - loy*yslope; - if (dbg) -- printf("Coefficients: %10.5f%10.5f%10.5f%10.5f\n", -+ printf("Coefficients: %10.5f %10.5f %10.5f %10.5f\n", - xslope,xbase,yslope,ybase); - } - -@@ -70,14 +80,18 @@ - /* - * Set the size of the virtual pen used in drawing - */ -+static sendpath(); - pensize(x) - int x; - { - if (x != ipensize) { - ipensize = Pen_to_Figpix(x); -+ ifontsize = x; -+ if( ipensize == 0 ) ipensize = 1; - if (!pathsent) sendpath(); - clearpath(); - } -+ if( dbg) printf("pensize %d -> %d\n", x, ipensize ); - } - - -@@ -149,24 +163,84 @@ - float x, y; - int position; /* Indicates what part of text is at (x,y) */ - { -- int ix, iy, offset; -- char *cp; -+ int ix, iy, offset, c; -+ unsigned char *cp; - map(x, y, &ix, &iy, 1); - -- for (cp = text; *cp && isspace(*text); cp++); -+ for (cp = (unsigned char *)text; isspace(*cp); cp++); - if (!*cp) return; - - #ifdef TEXT_LEFT_ONLY -- if (position != T_LEFT_JUSTIFIED) offset = strlen(cp)*8; -+ if (position != T_LEFT_JUSTIFIED) offset = strlen(cp)*Points_To_Figpix(ifontsize); - if (position == T_CENTER_JUSTIFIED) offset = offset/2; - position = T_LEFT_JUSTIFIED; - #else - offset = 0; - #endif TEXT_LEFT_ONLY - -+/* FORMAT 1.4 CODE - fprintf(TEXFILE, "%d %d %d %d %d %d %6.3f %d %d %d %d %d %s%c\n", -- O_TEXT, position, -1, -1, -1, -1, 0.0, -1, 16, strlen(cp)*8, -+ 4 justification (0,1,2) -+ font (unused) -+ fontsize (unused) -+ pen (unused) -+ color -+ depth -+ angle (not used) -+ height (pixels) -+ length (pixels) -+ -+ 4, position, -1, -1, -1, -1, 0.0, -1, 16, strlen(cp)*Points_To_Figpix(ifontsize), - Pix_To_Figpix(ix) - offset, Pix_To_Figpix(iy), cp, '\01'); -+Example: -+4 1 -1 -1 -1 -1 0.000 -1 16 24 229 603 FEP^A -+ -+FORMAT 3.2 CODE -+ (3.7) TEXT -+ type name (brief description) -+ ---- ---- ------------------- -+ int object (always 4) -+ int sub_type (0: Left justified -+ 1: Center justified -+ 2: Right justified) -+ int color (enumeration type) -+ int depth (enumeration type) -+ int pen_style (enumeration , not used) -+ int font (enumeration type) -+ float font_size (font size in points) -+ float angle (radians, the angle of the text) -+ int font_flags (bit vector) -+ float height (Fig units) -+ float length (Fig units) -+ int x, y (Fig units, coordinate of the origin -+ of the string. If sub_type = 0, it is -+ the lower left corner of the string. -+ If sub_type = 1, it is the lower -+ center. Otherwise it is the lower -+ right corner of the string.) -+ char string[] (ASCII characters; starts after a blank -+ character following the last number and -+ ends before the sequence '\001'. This -+ sequence is not part of the string. -+ -+ -+Example: -+4 1 -1 0 -1 -1 12 0.0000 4 135 330 3450 9060 FEP\001 -+*/ -+ if(dbg) printf("string (%d,%d) '%s'\n", Pix_To_Figpix(ix-offset), Pix_To_Figpix(iy), cp ); -+ -+ fprintf(TEXFILE, "%d %d %d %d %d %d %d %6.3f %d %d %d %d %d ", -+ O_TEXT, position, -1, 0,-1,-1,ifontsize,0.0, 4,Pix_To_Figpix(FONT_HT),Pix_To_Figpix(strlen(cp)*FONT_WIDTH), -+ Pix_To_Figpix(ix-offset), Pix_To_Figpix(iy)); -+ while( (c = ((unsigned char *)(cp))[0]) ){ -+ if( c == '\\' ){ -+ fprintf(TEXFILE, "\\\\"); -+ } else if( isprint(c) || isspace(c) ){ -+ fprintf(TEXFILE, "%c", c); -+ } -+ ++cp; -+ } -+ fprintf(TEXFILE, "\\001\n"); - } - - -@@ -208,16 +282,54 @@ - { - register int i; - -- if (dbg) printf("Sending path ...%d\n", arraylen); -+ if (dbg) printf("Sendpath [%d], ipensize %d\n", arraylen, ipensize); - if (arraylen > 1) { - -+ /* - fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", - O_POLYLINE, T_POLYLINE, SOLID_LINE, - ipensize, -1, -1, -1, -1, -1, 0, 0); -- for (i=1; i<=arraylen; i++) -- fprintf(TEXFILE, "%d %d ", -+ -+Example: -+ 2 1 0 1 -1 -1 -1 -1 -1 0 0 -+ 19 149 19 9 179 9 179 149 19 149 9999 9999 -+ -+New format: -+ 2 1 0 1 -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 5 -+ code pen_color -+ type fill_color -+ line style -+ depth -+ pen_style -+ style_value -+ join_style -+ cap_style -+ radius -+ forward_arrow -+ count -+ thickness (1/80 inch) -+ -1 = Default -+ 0 = Solid -+ 1 = Dashed -+ 2 = Dotted -+ 3 = Dash-dotted -+ 4 = Dash-double-dotted -+ 5 = Dash-triple-dotted -+ -+ 300 2250 300 150 2700 150 2700 2250 300 2250 -+ -+ -+ */ -+ fprintf(TEXFILE, "%d %d %d %d -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 %d\n ", -+ 2, T_POLYLINE, SOLID_LINE, ipensize, arraylen ); -+ for (i=1; i<=arraylen; i++){ -+ if (dbg) printf(" (%d,%d)", Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); -+ fprintf(TEXFILE, "%d %d ", - Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); -- fprintf(TEXFILE, "9999 9999\n"); -+ } -+ if (dbg) printf("\n", Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); -+ /* fprintf(TEXFILE, "9999 9999\n"); */ -+ fprintf(TEXFILE, "\n"); - } - - pathsent = TRUE; -@@ -234,17 +346,23 @@ - { - register int i; - -- if (dbg) printf("Sending path ...%d\n", arraylen); -+ if (dbg) printf("Send_dashed_path ...%d\n", arraylen); - if (arraylen < 2) return; - else { -+/* - fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", - O_POLYLINE, T_POLYLINE, - (dotted ? DOTTED_LINE : DASH_LINE), ipensize, - -1, -1, -1, -1, -1, 0, 0); -- for (i=1; i<=arraylen; i++) -+ */ -+ fprintf(TEXFILE, "%d %d %d %d -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 %d\n ", -+ 2, T_POLYLINE, (dotted? DOTTED_LINE: DASH_LINE), ipensize, arraylen ); -+ for (i=1; i<=arraylen; i++){ - fprintf(TEXFILE, "%d %d ", - Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); -- fprintf(TEXFILE, "9999 9999\n"); -+ } -+ /* fprintf(TEXFILE, "9999 9999\n"); */ -+ fprintf(TEXFILE, "\n"); - } - - pathsent = TRUE; -@@ -294,7 +412,7 @@ - fig_arc(xcenter, ycenter, xradius, yradius, start, stop) - float xcenter, ycenter, xradius, yradius, start, stop; - { -- int X0, Y0, xrad, yrad, xend, yend; -+ int X0, Y0, xrad, yrad, xend, yend, xstart, ystart; - extern double cos(), sin(); - - map(xcenter, ycenter, &X0, &Y0, FALSE); -@@ -304,18 +422,85 @@ - if (is_onarc(PI/2, start, stop)) ckbounds(X0, Y0+yrad); - if (is_onarc(PI, start, stop)) ckbounds(X0-xrad, Y0); - if (is_onarc(1.5*PI, start, stop)) ckbounds(X0, Y0-yrad); -- xend = X0 + xrad * cos(start) + 0.5; -- yend = Y0 + yrad * sin(start) + 0.5; -- ckbounds(xend, yend); -+ xstart = X0 + xrad * cos(start) + 0.5; -+ ystart = Y0 + yrad * sin(start) + 0.5; -+ ckbounds(xstart, ystart); - xend = X0 + xrad * cos(stop); - yend = Y0 + yrad * sin(stop); - ckbounds(xend, yend); -+ if(dbg) printf("Ellipse: X0 %d, Y0 %d, xrad %d, yrad %d, xstart %d, ystart %d, xend %d, yend %d\n", -+ Pix_To_Figpix(X0), Pix_To_Figpix(Y0), -+ Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), -+ Pix_To_Figpix(xstart), Pix_To_Figpix(ystart), -+ Pix_To_Figpix(xend), Pix_To_Figpix(yend)); -+ -+/* -+ int object_code (always 1) -+ int sub_type (1 : ellipse defined by radiuses -+ 2 : ellipse defined by diameters -+ 3 : circle defined by radius -+ 4 : circle defined by diameter) -+ int line_style (See the end of this section) -+ int thickness (pixels, not used) -+ int color (not used) -+ int depth (not used) -+ int pen (not used) -+ int area_fill (not used) -+ float style_val (pixels, not used) -+ int direction (always 1) -+ float angle (radian, the angle of the x-axis) -+ int center_x, center_y (pixels) -+ int radius_x, radius_y (pixels) -+ int start_x, start_y (pixels; the 1st point entered) -+ int end_x, end_y (pixels; the last point entered) -+ -+Example: -+ 1 1 0 1 -1, -1 -1 -1 -1 1 0 0.000 0.000 0.000 0.000 0.000 0.000 - - fprintf(TEXFILE, "%d %d %d %d %d, %d %d %d %d %d %d %6.3f %6.3f %6.3f %6.3f %6.3f %6.3f\n", - O_ELLIPSE, T_ELLIPSE_BY_RAD, - SOLID_LINE, ipensize, -1, -1, -1, -1, -1, 1, 0.0, - Pix_To_Figpix(X0), Pix_To_Figpix(Y0), - Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), 0.0, 0.0, 0.0, 0.0); -+ -+ -+ int object_code (always 1) -+ int sub_type (1: ellipse defined by radii -+ 2: ellipse defined by diameters -+ 3: circle defined by radius -+ 4: circle defined by diameter) -+ int line_style (enumeration type) -+ int thickness (1/80 inch) -+ -- -+ int pen_color (enumeration type, pen color) -+ int fill_color (enumeration type, fill color) -+ int depth (enumeration type) -+ int pen_style (pen style, not used) -+ int area_fill (enumeration type, -1 = no fill) -+ float style_val (1/80 inch) -+ int direction (always 1) -+ float angle (radians, the angle of the x-axis) -+ int center_x, center_y (Fig units) -+ int radius_x, radius_y (Fig units) -+ int start_x, start_y (Fig units; the 1st point entered) -+ int end_x, end_y (Fig units; the last point entered) -+ -+Example: -+ 1 1 0 1 0 7 50 0 -1 0.000 1 0.0000 1125 975 675 375 1125 975 1800 1350 -+ pen areafill -+ fill styleval -+ depth -+ pen_style -+*/ -+ -+ -+ fprintf(TEXFILE, "%d %d %d %d", O_ELLIPSE, T_ELLIPSE_BY_RAD, SOLID_LINE, ipensize ); -+ fprintf(TEXFILE, " 0 7 50 0 -1 0.0 1 0.0" ); -+ fprintf(TEXFILE, " %d %d %d %d %d %d %d %d\n", -+ Pix_To_Figpix(X0), Pix_To_Figpix(Y0), -+ Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), -+ Pix_To_Figpix(xstart), Pix_To_Figpix(ystart), -+ Pix_To_Figpix(xend), Pix_To_Figpix(yend)); - } - - -@@ -347,14 +532,56 @@ - */ - fig_begin_drawing() - { -- fprintf(TEXFILE, "#FIG 1.4\n%d %d\n", FIGRES, 2); -+ -+/* -+(1) The very first line is a comment line containing the name and version: -+ #FIG 3.2 -+(2) The first non-comment line consists of the following: -+ -+ string orientation ("Landscape" or "Portrait") -+ string justification ("Center" or "Flush Left") -+ string units ("Metric" or "Inches") -+ string papersize ("Letter", "Legal", "Ledger", "Tabloid", -+ "A", "B", "C", "D", "E", -+ "A4", "A3", "A2", "A1", "A0" and "B5") -+ float magnification (export and print magnification, %) -+ string multiple-page ("Single" or "Multiple" pages) -+ int transparent color (color number for transparent color for GIF -+ export. -3=background, -2=None, -1=Default, -+ 0-31 for standard colors or 32- for user colors) -+ # optional comment (An optional set of comments may be here, -+ which are associated with the whole figure) -+ int resolution coord_system (Fig units/inch and coordinate system: -+ 1: origin at lower left corner (NOT USED) -+ 2: upper left) -+Example: -+ #FIG 3.2 -+ Landscape -+ Center -+ Inches -+ Letter -+ 100.00 -+ Single -+ -2 -+ 1200 2 -+ -+*/ -+ fprintf(TEXFILE, "#FIG 3.2\n"); -+ fprintf(TEXFILE, "Landscape\n"); -+ fprintf(TEXFILE, "Center\n"); -+ fprintf(TEXFILE, "Inches\n"); -+ fprintf(TEXFILE, "Letter\n"); -+ fprintf(TEXFILE, "100.00\n"); -+ fprintf(TEXFILE, "Single\n"); -+ fprintf(TEXFILE, "-2\n"); -+ fprintf(TEXFILE, "%d %d\n", FIGRES, 2 ); - - fig_window(0.0, 0.0, 10.0, 10.0, 0.0, 0.0, 3.0, 3.0); - xmin = 30000; xmax = -30000; - ymin = 30000; ymax = -30000; - arraylen = 0; - pathsent = FALSE; -- ipensize = Pen_to_Figpix(DEF_PEN_SIZE); -+ pensize(DEF_PEN_SIZE); - } - - -@@ -392,15 +619,67 @@ - clearpath(); - } - -+/* - fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", - O_SPLINE, T_OPEN_NORMAL, - SOLID_LINE, ipensize, -1, -1, -1, -1, -1, 0, 0); -+ fprintf(TEXFILE, "9999 9999\n"); -+ -+New format: -+ int object_code (always 3) -+ int sub_type (0: open approximated spline -+ 1: closed approximated spline -+ 2: open interpolated spline -+ 3: closed interpolated spline -+ 4: open x-spline -+ 5: closed x-spline) -+ int line_style (See the end of this section) -+ int thickness (1/80 inch) -+ int pen_color (enumeration type, pen color) -+ int fill_color (enumeration type, fill color) -+ int depth (enumeration type) -+ int pen_style (pen style, not used) -+ int area_fill (enumeration type, -1 = no fill) -+ float style_val (1/80 inch) -+ int cap_style (enumeration type, only used for open splines) -+ int forward_arrow (0: off, 1: on) -+ int backward_arrow (0: off, 1: on) -+ int npoints (number of control points in spline) -+ -+ Forward arrow line: same as ARC object -+ -+ Backward arrow line: same as ARC object -+ -+ Points line: same as POLYLINE object -+ -+ Control points line : -+ -+ There is one shape factor for each point. The value of this factor -+ must be between -1 (which means that the spline is interpolated at -+ this point) and 1 (which means that the spline is approximated at -+ this point). The spline is always smooth in the neighbourhood of a -+ control point, except when the value of the factor is 0 for which -+ there is a first-order discontinuity (i.e. angular point). -+ -+Example: -+ 3 2 0 1 0 7 50 0 -1 0.000 0 0 0 3 -+ 975 1950 1875 1500 2550 1950 -+ 0.000 -1.000 0.000 -+ -+*/ -+ fprintf(TEXFILE, "%d %d %d %d", 3, 2, SOLID_LINE, ipensize ); -+ fprintf(TEXFILE, " 0 7 50 0 -1 0.000 0 0 0 %d\n ", N-1 ); - for (i=1; i - #include -+#include - #include "pic.h" - #include "picy.h" +--- figd.c.orig Sat Aug 6 19:52:43 1988 ++++ figd.c Wed Apr 3 10:27:14 2002 +@@ -6,13 +6,16 @@ + * + * Modified by Micah Beck to produce Fig code + * Modified by Micah Beck again to produce Fig 1.4 code ++ * Modified by Patrick Powell to produce Fig 3.2 code + */ + + #include + #include + #include "object.h" + +-#define DEF_PEN_SIZE 8 /* Default pen diameter */ ++/* #define DEF_PEN_SIZE 8 / * Default pen diameter */ ++#define DEF_PEN_SIZE 1 /* Default pen diameter */ ++#define DEF_FONT_SIZE 12 /* Default pen diameter */ + #define MAXPOINTS 300 /* Max number of points in a path */ + + #define bool int +@@ -23,6 +26,8 @@ + #define P_BLACK 15 + #define TEXTURE 3 + #define ORTEXTURE 7 ++#define FONT_HT 12 ++#define FONT_WIDTH 8 + + extern double sqrt(), cos(), sin(); + +@@ -31,11 +36,15 @@ + #define RES 1000.0 + #define Pix_To_In(x) (((float) x) / RES) + +-#define FIGRES 80 ++/* #define FIGRES 80 */ ++#define FIGRES 1200 + #define FIGCANV_W (8*FIGRES) + #define FIGCANV_H (10*FIGRES) ++#define Points_To_Figpix(x) ((int)(FIGRES * (x)/72.0)) + #define Pix_To_Figpix(x) ((int)(FIGRES * Pix_To_In(x))) +-#define Pen_to_Figpix(x) ((x*FIGRES + 500) / 1000) ++/* #define Pen_to_Figpix(x) ((x*FIGRES + 500) / 1000) */ ++/* pen thickness in 1/80 of inch */ ++#define Pen_to_Figpix(x) ((Pix_To_In(x) + 79) / 80) + + + extern int dbg; /* Non-zero when debugging info wanted */ +@@ -44,8 +53,10 @@ + static float xslope,yslope,xbase,ybase;/* Convert Window to Viewport */ + static int arraylen; /* Number of points in current path */ + static bool pathsent; /* True if path has been defined */ +-static int ipensize; /* Desired current pen size */ ++static int ipensize = DEF_PEN_SIZE; /* Desired current pen size */ ++static int ifontsize = DEF_FONT_SIZE; /* Desired current font size */ + extern FILE *TEXFILE; /* Output file */ ++int font = -1; /* font number */ + + + /* +@@ -62,7 +73,7 @@ + yslope = RES * (hiypage-loypage) / (hiy-loy); + ybase = RES * loypage - loy*yslope; + if (dbg) +- printf("Coefficients: %10.5f%10.5f%10.5f%10.5f\n", ++ printf("Coefficients: %10.5f %10.5f %10.5f %10.5f\n", + xslope,xbase,yslope,ybase); + } + +@@ -70,14 +81,18 @@ + /* + * Set the size of the virtual pen used in drawing + */ ++static sendpath(); + pensize(x) + int x; + { + if (x != ipensize) { + ipensize = Pen_to_Figpix(x); ++ ifontsize = x; ++ if( ipensize == 0 ) ipensize = 1; + if (!pathsent) sendpath(); + clearpath(); + } ++ if( dbg) printf("pensize %d -> %d\n", x, ipensize ); + } + + +@@ -149,24 +164,85 @@ + float x, y; + int position; /* Indicates what part of text is at (x,y) */ + { +- int ix, iy, offset; +- char *cp; ++ int ix, iy, offset, c; ++ unsigned char *cp; + map(x, y, &ix, &iy, 1); + +- for (cp = text; *cp && isspace(*text); cp++); ++ for (cp = (unsigned char *)text; isspace(*cp); cp++); + if (!*cp) return; + + #ifdef TEXT_LEFT_ONLY +- if (position != T_LEFT_JUSTIFIED) offset = strlen(cp)*8; ++ if (position != T_LEFT_JUSTIFIED) offset = strlen(cp)*Points_To_Figpix(ifontsize); + if (position == T_CENTER_JUSTIFIED) offset = offset/2; + position = T_LEFT_JUSTIFIED; + #else + offset = 0; + #endif TEXT_LEFT_ONLY + ++/* FORMAT 1.4 CODE + fprintf(TEXFILE, "%d %d %d %d %d %d %6.3f %d %d %d %d %d %s%c\n", +- O_TEXT, position, -1, -1, -1, -1, 0.0, -1, 16, strlen(cp)*8, ++ 4 justification (0,1,2) ++ font (unused) ++ fontsize (unused) ++ pen (unused) ++ color ++ depth ++ angle (not used) ++ height (pixels) ++ length (pixels) ++ ++ 4, position, -1, -1, -1, -1, 0.0, -1, 16, strlen(cp)*Points_To_Figpix(ifontsize), + Pix_To_Figpix(ix) - offset, Pix_To_Figpix(iy), cp, '\01'); ++Example: ++4 1 -1 -1 -1 -1 0.000 -1 16 24 229 603 FEP^A ++ ++FORMAT 3.2 CODE ++Example: ++4 1 -1 0 -1 -1 12 0.0000 4 135 330 3450 9060 FEP\001 ++1 2 3 4 5 6 7 8 9 10 11 12 13 14 ++ (3.7) TEXT ++ type name (brief description) ++ ---- ---- ------------------- ++ int object (always 4) 1 ++ int sub_type (0: Left justified 2 ++ 1: Center justified ++ 2: Right justified) ++ int color (enumeration type) 3 ++ int depth (enumeration type) 4 ++ int pen_style (enumeration , not used) 5 ++ int font (enumeration type) 6 ++ float font_size (font size in points) 7 ++ float angle (radians, the angle of the text) 8 ++ int font_flags (bit vector) 9 ++ float height (Fig units) 10 ++ float length (Fig units) 11 ++ int x, y (Fig units, coordinate of the origin 12,13 ++ of the string. If sub_type = 0, it is ++ the lower left corner of the string. ++ If sub_type = 1, it is the lower ++ center. Otherwise it is the lower ++ right corner of the string.) ++ char string[] (ASCII characters; starts after a blank 14 ++ character following the last number and ++ ends before the sequence '\001'. This ++ sequence is not part of the string. ++ ++ ++*/ ++ if(dbg) printf("string (%d,%d) '%s'\n", Pix_To_Figpix(ix-offset), Pix_To_Figpix(iy), cp ); ++ ++ fprintf(TEXFILE, "%d %d %d %d %d %d %d %6.3f %d %d %d %d %d ", ++ O_TEXT, position, -1, 0,-1,font,ifontsize,0.0, 4,Pix_To_Figpix(FONT_HT),Pix_To_Figpix(strlen(cp)*FONT_WIDTH), ++ Pix_To_Figpix(ix-offset), Pix_To_Figpix(iy)); ++ while( (c = ((unsigned char *)(cp))[0]) ){ ++ if( c == '\\' ){ ++ fprintf(TEXFILE, "\\\\"); ++ } else if( isprint(c) || isspace(c) ){ ++ fprintf(TEXFILE, "%c", c); ++ } ++ ++cp; ++ } ++ fprintf(TEXFILE, "\\001\n"); + } + + +@@ -208,16 +284,54 @@ + { + register int i; + +- if (dbg) printf("Sending path ...%d\n", arraylen); ++ if (dbg) printf("Sendpath [%d], ipensize %d\n", arraylen, ipensize); + if (arraylen > 1) { + ++ /* + fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", + O_POLYLINE, T_POLYLINE, SOLID_LINE, + ipensize, -1, -1, -1, -1, -1, 0, 0); +- for (i=1; i<=arraylen; i++) +- fprintf(TEXFILE, "%d %d ", ++ ++Example: ++ 2 1 0 1 -1 -1 -1 -1 -1 0 0 ++ 19 149 19 9 179 9 179 149 19 149 9999 9999 ++ ++New format: ++ 2 1 0 1 -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 5 ++ code pen_color ++ type fill_color ++ line style ++ depth ++ pen_style ++ style_value ++ join_style ++ cap_style ++ radius ++ forward_arrow ++ count ++ thickness (1/80 inch) ++ -1 = Default ++ 0 = Solid ++ 1 = Dashed ++ 2 = Dotted ++ 3 = Dash-dotted ++ 4 = Dash-double-dotted ++ 5 = Dash-triple-dotted ++ ++ 300 2250 300 150 2700 150 2700 2250 300 2250 ++ ++ ++ */ ++ fprintf(TEXFILE, "%d %d %d %d -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 %d\n ", ++ 2, T_POLYLINE, SOLID_LINE, ipensize, arraylen ); ++ for (i=1; i<=arraylen; i++){ ++ if (dbg) printf(" (%d,%d)", Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); ++ fprintf(TEXFILE, "%d %d ", + Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); +- fprintf(TEXFILE, "9999 9999\n"); ++ } ++ if (dbg) printf("\n", Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); ++ /* fprintf(TEXFILE, "9999 9999\n"); */ ++ fprintf(TEXFILE, "\n"); + } + + pathsent = TRUE; +@@ -234,17 +348,26 @@ + { + register int i; + +- if (dbg) printf("Sending path ...%d\n", arraylen); ++ if (dbg) printf("Send_dashed_path ...%d, inchesperdash %f, dotted %d\n", ++ arraylen, inchesperdash, dotted ); + if (arraylen < 2) return; + else { ++/* + fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", + O_POLYLINE, T_POLYLINE, + (dotted ? DOTTED_LINE : DASH_LINE), ipensize, + -1, -1, -1, -1, -1, 0, 0); +- for (i=1; i<=arraylen; i++) ++ */ ++ fprintf(TEXFILE, "%d %d %d %d -1 -1 0 -1 -1 %f 0 0 -1 0 0 %d\n ", ++ 2, T_POLYLINE, (dotted? DOTTED_LINE: DASH_LINE), ipensize, ++ inchesperdash*80, ++ arraylen ); ++ for (i=1; i<=arraylen; i++){ + fprintf(TEXFILE, "%d %d ", + Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); +- fprintf(TEXFILE, "9999 9999\n"); ++ } ++ /* fprintf(TEXFILE, "9999 9999\n"); */ ++ fprintf(TEXFILE, "\n"); + } + + pathsent = TRUE; +@@ -294,7 +417,7 @@ + fig_arc(xcenter, ycenter, xradius, yradius, start, stop) + float xcenter, ycenter, xradius, yradius, start, stop; + { +- int X0, Y0, xrad, yrad, xend, yend; ++ int X0, Y0, xrad, yrad, xend, yend, xstart, ystart; + extern double cos(), sin(); + + map(xcenter, ycenter, &X0, &Y0, FALSE); +@@ -304,18 +427,85 @@ + if (is_onarc(PI/2, start, stop)) ckbounds(X0, Y0+yrad); + if (is_onarc(PI, start, stop)) ckbounds(X0-xrad, Y0); + if (is_onarc(1.5*PI, start, stop)) ckbounds(X0, Y0-yrad); +- xend = X0 + xrad * cos(start) + 0.5; +- yend = Y0 + yrad * sin(start) + 0.5; +- ckbounds(xend, yend); ++ xstart = X0 + xrad * cos(start) + 0.5; ++ ystart = Y0 + yrad * sin(start) + 0.5; ++ ckbounds(xstart, ystart); + xend = X0 + xrad * cos(stop); + yend = Y0 + yrad * sin(stop); + ckbounds(xend, yend); ++ if(dbg) printf("Ellipse: X0 %d, Y0 %d, xrad %d, yrad %d, xstart %d, ystart %d, xend %d, yend %d\n", ++ Pix_To_Figpix(X0), Pix_To_Figpix(Y0), ++ Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), ++ Pix_To_Figpix(xstart), Pix_To_Figpix(ystart), ++ Pix_To_Figpix(xend), Pix_To_Figpix(yend)); ++ ++/* ++ int object_code (always 1) ++ int sub_type (1 : ellipse defined by radiuses ++ 2 : ellipse defined by diameters ++ 3 : circle defined by radius ++ 4 : circle defined by diameter) ++ int line_style (See the end of this section) ++ int thickness (pixels, not used) ++ int color (not used) ++ int depth (not used) ++ int pen (not used) ++ int area_fill (not used) ++ float style_val (pixels, not used) ++ int direction (always 1) ++ float angle (radian, the angle of the x-axis) ++ int center_x, center_y (pixels) ++ int radius_x, radius_y (pixels) ++ int start_x, start_y (pixels; the 1st point entered) ++ int end_x, end_y (pixels; the last point entered) ++ ++Example: ++ 1 1 0 1 -1, -1 -1 -1 -1 1 0 0.000 0.000 0.000 0.000 0.000 0.000 + + fprintf(TEXFILE, "%d %d %d %d %d, %d %d %d %d %d %d %6.3f %6.3f %6.3f %6.3f %6.3f %6.3f\n", + O_ELLIPSE, T_ELLIPSE_BY_RAD, + SOLID_LINE, ipensize, -1, -1, -1, -1, -1, 1, 0.0, + Pix_To_Figpix(X0), Pix_To_Figpix(Y0), + Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), 0.0, 0.0, 0.0, 0.0); ++ ++ ++ int object_code (always 1) ++ int sub_type (1: ellipse defined by radii ++ 2: ellipse defined by diameters ++ 3: circle defined by radius ++ 4: circle defined by diameter) ++ int line_style (enumeration type) ++ int thickness (1/80 inch) ++ -- ++ int pen_color (enumeration type, pen color) ++ int fill_color (enumeration type, fill color) ++ int depth (enumeration type) ++ int pen_style (pen style, not used) ++ int area_fill (enumeration type, -1 = no fill) ++ float style_val (1/80 inch) ++ int direction (always 1) ++ float angle (radians, the angle of the x-axis) ++ int center_x, center_y (Fig units) ++ int radius_x, radius_y (Fig units) ++ int start_x, start_y (Fig units; the 1st point entered) ++ int end_x, end_y (Fig units; the last point entered) ++ ++Example: ++ 1 1 0 1 0 7 50 0 -1 0.000 1 0.0000 1125 975 675 375 1125 975 1800 1350 ++ pen areafill ++ fill styleval ++ depth ++ pen_style ++*/ ++ ++ ++ fprintf(TEXFILE, "%d %d %d %d", O_ELLIPSE, T_ELLIPSE_BY_RAD, SOLID_LINE, ipensize ); ++ fprintf(TEXFILE, " 0 7 50 0 -1 0.0 1 0.0" ); ++ fprintf(TEXFILE, " %d %d %d %d %d %d %d %d\n", ++ Pix_To_Figpix(X0), Pix_To_Figpix(Y0), ++ Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), ++ Pix_To_Figpix(xstart), Pix_To_Figpix(ystart), ++ Pix_To_Figpix(xend), Pix_To_Figpix(yend)); + } + + +@@ -347,14 +537,56 @@ + */ + fig_begin_drawing() + { +- fprintf(TEXFILE, "#FIG 1.4\n%d %d\n", FIGRES, 2); ++ ++/* ++(1) The very first line is a comment line containing the name and version: ++ #FIG 3.2 ++(2) The first non-comment line consists of the following: ++ ++ string orientation ("Landscape" or "Portrait") ++ string justification ("Center" or "Flush Left") ++ string units ("Metric" or "Inches") ++ string papersize ("Letter", "Legal", "Ledger", "Tabloid", ++ "A", "B", "C", "D", "E", ++ "A4", "A3", "A2", "A1", "A0" and "B5") ++ float magnification (export and print magnification, %) ++ string multiple-page ("Single" or "Multiple" pages) ++ int transparent color (color number for transparent color for GIF ++ export. -3=background, -2=None, -1=Default, ++ 0-31 for standard colors or 32- for user colors) ++ # optional comment (An optional set of comments may be here, ++ which are associated with the whole figure) ++ int resolution coord_system (Fig units/inch and coordinate system: ++ 1: origin at lower left corner (NOT USED) ++ 2: upper left) ++Example: ++ #FIG 3.2 ++ Landscape ++ Center ++ Inches ++ Letter ++ 100.00 ++ Single ++ -2 ++ 1200 2 ++ ++*/ ++ fprintf(TEXFILE, "#FIG 3.2\n"); ++ fprintf(TEXFILE, "Landscape\n"); ++ fprintf(TEXFILE, "Center\n"); ++ fprintf(TEXFILE, "Inches\n"); ++ fprintf(TEXFILE, "Letter\n"); ++ fprintf(TEXFILE, "100.00\n"); ++ fprintf(TEXFILE, "Single\n"); ++ fprintf(TEXFILE, "-2\n"); ++ fprintf(TEXFILE, "%d %d\n", FIGRES, 2 ); + + fig_window(0.0, 0.0, 10.0, 10.0, 0.0, 0.0, 3.0, 3.0); + xmin = 30000; xmax = -30000; + ymin = 30000; ymax = -30000; + arraylen = 0; + pathsent = FALSE; +- ipensize = Pen_to_Figpix(DEF_PEN_SIZE); ++ pensize(DEF_PEN_SIZE); + } + + +@@ -392,15 +624,67 @@ + clearpath(); + } + ++/* + fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", + O_SPLINE, T_OPEN_NORMAL, + SOLID_LINE, ipensize, -1, -1, -1, -1, -1, 0, 0); ++ fprintf(TEXFILE, "9999 9999\n"); ++ ++New format: ++ int object_code (always 3) ++ int sub_type (0: open approximated spline ++ 1: closed approximated spline ++ 2: open interpolated spline ++ 3: closed interpolated spline ++ 4: open x-spline ++ 5: closed x-spline) ++ int line_style (See the end of this section) ++ int thickness (1/80 inch) ++ int pen_color (enumeration type, pen color) ++ int fill_color (enumeration type, fill color) ++ int depth (enumeration type) ++ int pen_style (pen style, not used) ++ int area_fill (enumeration type, -1 = no fill) ++ float style_val (1/80 inch) ++ int cap_style (enumeration type, only used for open splines) ++ int forward_arrow (0: off, 1: on) ++ int backward_arrow (0: off, 1: on) ++ int npoints (number of control points in spline) ++ ++ Forward arrow line: same as ARC object ++ ++ Backward arrow line: same as ARC object ++ ++ Points line: same as POLYLINE object ++ ++ Control points line : ++ ++ There is one shape factor for each point. The value of this factor ++ must be between -1 (which means that the spline is interpolated at ++ this point) and 1 (which means that the spline is approximated at ++ this point). The spline is always smooth in the neighbourhood of a ++ control point, except when the value of the factor is 0 for which ++ there is a first-order discontinuity (i.e. angular point). ++ ++Example: ++ 3 2 0 1 0 7 50 0 -1 0.000 0 0 0 3 ++ 975 1950 1875 1500 2550 1950 ++ 0.000 -1.000 0.000 ++ ++*/ ++ fprintf(TEXFILE, "%d %d %d %d", 3, 2, SOLID_LINE, ipensize ); ++ fprintf(TEXFILE, " 0 7 50 0 -1 0.000 0 0 0 %d\n ", N-1 ); + for (i=1; i + #include ++#include + #include "pic.h" + #include "picy.h" + + static reset(); +-extern char *sprintf(), *strcpy(); + + struct obj *objlist[MAXOBJ]; /* store the elements here */ + int nobj = 0; +@@ -27,7 +27,7 @@ + float deltx = 6; /* max x value in output, for scaling */ + float delty = 6; /* max y value in output, for scaling */ + int dbg = 0; +-extern FILE *yyin; /* input file pointer */ ++extern FILE *yyin, *yyout; /* input and out file pointers */ + FILE *TEXFILE; /* Output file */ + int lineno = 0; + char *filename = "-"; +@@ -51,6 +51,7 @@ + { + char TEXfilename[BUFSIZ], buffer[BUFSIZ], *bp, *rindex(); + ++ yyin = stdin; yyout = stdout; + cmdname = argv[0]; + while (argc > 1 && *argv[1] == '-') { + switch (argv[1][1]) { diff -rNu /usr/ports/print/pic2fig/files/patch-ae pic2fig/files/patch-ae --- /usr/ports/print/pic2fig/files/patch-ae Wed Dec 31 16:00:00 1969 +++ pic2fig/files/patch-ae Wed Apr 3 10:42:06 2002 @@ -0,0 +1,7 @@ +--- pic.h.orig Wed Apr 3 10:27:42 2002 ++++ pic.h Wed Apr 3 10:29:33 2002 +@@ -128,4 +128,3 @@ + extern struct pushstack stack[]; + extern int nstack; + +-extern float atof(); diff -rNu /usr/ports/print/pic2fig/files/patch-af pic2fig/files/patch-af --- /usr/ports/print/pic2fig/files/patch-af Wed Dec 31 16:00:00 1969 +++ pic2fig/files/patch-af Wed Apr 3 10:42:06 2002 @@ -0,0 +1,54 @@ +--- pic2fig.1.orig Thu Feb 11 05:34:07 1988 ++++ pic2fig.1 Wed Apr 3 10:27:14 2002 +@@ -55,6 +55,51 @@ + must be given in the first column. Changing the drawing thickness applies + to solid, dashed, and dotted lines, as well as circles, arcs, and ellipses. + .PP ++Setting the font for text may be done using a ++.ti +.5i ++\&.ft \fIn\fR ++ ++command, where \fIn\fR corresponds to the following PostScript fonts: ++.nf ++-1 Default font ++ 0 Times Roman ++ 1 Times Italic ++ 2 Times Bold ++ 3 Times Bold Italic ++ 4 AvantGarde Book ++ 5 AvantGarde Book Oblique ++ 6 AvantGarde Demi ++ 7 AvantGarde Demi Oblique ++ 8 Bookman Light ++ 9 Bookman Light Italic ++10 Bookman Demi ++11 Bookman Demi Italic ++12 Courier ++13 Courier Oblique ++14 Courier Bold ++15 Courier Bold Oblique ++16 Helvetica ++17 Helvetica Oblique ++18 Helvetica Bold ++19 Helvetica Bold Oblique ++20 Helvetica Narrow ++21 Helvetica Narrow Oblique ++22 Helvetica Narrow Bold ++23 Helvetica Narrow Bold Oblique ++24 New Century Schoolbook Roman ++25 New Century Schoolbook Italic ++26 New Century Schoolbook Bold ++27 New Century Schoolbook Bold Italic ++28 Palatino Roman ++29 Palatino Italic ++30 Palatino Bold ++31 Palatino Bold Italic ++32 Symbol ++33 Zapf Chancery Medium Italic ++34 Zapf Dingbats ++.fi ++ ++.PP + Normally, the distance between text is 12 points. If you're using larger + text to label objects, this should be set to an appropriate larger value. + This can be done using the diff -rNu /usr/ports/print/pic2fig/files/patch-ag pic2fig/files/patch-ag --- /usr/ports/print/pic2fig/files/patch-ag Wed Dec 31 16:00:00 1969 +++ pic2fig/files/patch-ag Wed Apr 3 10:42:06 2002 @@ -0,0 +1,19 @@ +--- picl.c.orig Wed Apr 3 10:27:34 2002 ++++ picl.c Wed Apr 3 10:29:53 2002 +@@ -17,7 +17,7 @@ + int yymorfg; + extern char *yysptr, yysbuf[]; + int yytchar; +-FILE *yyin = {stdin}, *yyout = {stdout}; ++FILE *yyin, *yyout; + extern int yylineno; + struct yysvf { + struct yywork *yystoff; +@@ -40,7 +40,6 @@ + #include "pic.h" + # include "picy.h" + +-extern float atof(); + extern char *filename; + extern int synerr; + diff -rNu /usr/ports/print/pic2fig/files/patch-ah pic2fig/files/patch-ah --- /usr/ports/print/pic2fig/files/patch-ah Wed Dec 31 16:00:00 1969 +++ pic2fig/files/patch-ah Wed Apr 3 10:42:06 2002 @@ -0,0 +1,69 @@ +--- plfig.c.orig Tue Jul 5 09:21:25 1988 ++++ plfig.c Wed Apr 3 10:27:15 2002 +@@ -121,7 +121,48 @@ + htrue = vtrue = 0; + } + +-troff(s) /* handle ".ps n" to set the pen size to "n" pixels */ ++/* handle ".ps n" to set the pen size to "n" pixels */ ++/* handle ".ft n" to set the output font to number n ++ (.ft value) ++ -1 Default font ++ 0 Times Roman ++ 1 Times Italic ++ 2 Times Bold ++ 3 Times Bold Italic ++ 4 AvantGarde Book ++ 5 AvantGarde Book Oblique ++ 6 AvantGarde Demi ++ 7 AvantGarde Demi Oblique ++ 8 Bookman Light ++ 9 Bookman Light Italic ++ 10 Bookman Demi ++ 11 Bookman Demi Italic ++ 12 Courier ++ 13 Courier Oblique ++ 14 Courier Bold ++ 15 Courier Bold Oblique ++ 16 Helvetica ++ 17 Helvetica Oblique ++ 18 Helvetica Bold ++ 19 Helvetica Bold Oblique ++ 20 Helvetica Narrow ++ 21 Helvetica Narrow Oblique ++ 22 Helvetica Narrow Bold ++ 23 Helvetica Narrow Bold Oblique ++ 24 New Century Schoolbook Roman ++ 25 New Century Schoolbook Italic ++ 26 New Century Schoolbook Bold ++ 27 New Century Schoolbook Bold Italic ++ 28 Palatino Roman ++ 29 Palatino Italic ++ 30 Palatino Bold ++ 31 Palatino Bold Italic ++ 32 Symbol ++ 33 Zapf Chancery Medium Italic ++ 34 Zapf Dingbats ++*/ ++ ++troff(s) + char *s; + { + if (strncmp (s, ".ps", 3) == 0) { +@@ -131,6 +172,16 @@ + pensize (size); + else + fprintf (stderr, "Malformed .ps command: %s\n", s); ++ return; ++ } ++ if (strncmp (s, ".ft", 3) == 0) { ++ int size; ++ extern int font; ++ ++ if (sscanf (s + 3, " %d ", &size) == 1) ++ font = size; ++ else ++ fprintf (stderr, "Malformed .ft command: %s\n", s); + return; + } + ---- shar ---- # This is a shell archive. Save it in a file, remove anything before # this line, and then unpack it by entering "sh file". Note, it may # create directories; files and directories will be owned by you and # have default permissions. # # This archive contains: # # pic2fig # pic2fig/Makefile # pic2fig/distinfo # pic2fig/pkg-comment # pic2fig/pkg-descr # pic2fig/pkg-plist # pic2fig/files # pic2fig/files/patch-ae # pic2fig/files/patch-ac # pic2fig/files/patch-aa # pic2fig/files/patch-ab # pic2fig/files/patch-ad # pic2fig/files/patch-af # pic2fig/files/patch-ag # pic2fig/files/patch-ah # echo c - pic2fig mkdir -p pic2fig > /dev/null 2>&1 echo x - pic2fig/Makefile sed 's/^X//' >pic2fig/Makefile << 'END-of-pic2fig/Makefile' X# New ports collection makefile for: pic2fig X# Date created: 14 Jan 2001 X# Whom: Patrick Powell X# X# $FreeBSD: ports/print/pic2fig/Makefile,v 1.3 2002/02/10 00:56:56 pat Exp $ X XPORTNAME= pic2fig XPORTVERSION= 1.4 XPORTREVISION= 2 XCATEGORIES= print XMASTER_SITES= ${MASTER_SITE_XCONTRIB} XMASTER_SITE_SUBDIR= utilities XEXTRACT_SUFX= .tar.Z X XMAINTAINER= papowell@astart.com X XWRKSRC= ${WRKDIR}/${PORTNAME} XMAN1= pic2fig.1 X Xdo-install: X ${INSTALL_PROGRAM} -m 755 ${WRKSRC}/pic2fig ${PREFIX}/bin X ${INSTALL_MAN} ${WRKSRC}/pic2fig.1 ${PREFIX}/man/man1 X X.include END-of-pic2fig/Makefile echo x - pic2fig/distinfo sed 's/^X//' >pic2fig/distinfo << 'END-of-pic2fig/distinfo' XMD5 (pic2fig-1.4.tar.Z) = 98845b0fc9d9ad7e9484f22ef3057996 END-of-pic2fig/distinfo echo x - pic2fig/pkg-comment sed 's/^X//' >pic2fig/pkg-comment << 'END-of-pic2fig/pkg-comment' XPic format to fig format converter END-of-pic2fig/pkg-comment echo x - pic2fig/pkg-descr sed 's/^X//' >pic2fig/pkg-descr << 'END-of-pic2fig/pkg-descr' XPic2fig is a pic(l) preprocessor for drawing simple figures in Fig code. XThe basic objects are box, line, arrow, circle, ellipse, arc and text. X XWhen pic2fig is executed, it produces an output file in the Xcurrent directory. The name is constructed from the input file's Xname. If the input filename ends with .pic, then that extension Xwill be replaced by .fig. Otherwise, .fig is appended to the input Xfilename. If file does not exist, then pic2fig tries appending .pic Xto the name. X XUpdated to produce FIG 3.2 format by Patrick Powell X XWeb Site: ftp://ftp.x.org/contrib/utilities/ X XNote: this version does not support the groff/pic 'thickness' attribute. END-of-pic2fig/pkg-descr echo x - pic2fig/pkg-plist sed 's/^X//' >pic2fig/pkg-plist << 'END-of-pic2fig/pkg-plist' Xbin/pic2fig END-of-pic2fig/pkg-plist echo c - pic2fig/files mkdir -p pic2fig/files > /dev/null 2>&1 echo x - pic2fig/files/patch-ae sed 's/^X//' >pic2fig/files/patch-ae << 'END-of-pic2fig/files/patch-ae' X--- pic.h.orig Wed Apr 3 10:27:42 2002 X+++ pic.h Wed Apr 3 10:29:33 2002 X@@ -128,4 +128,3 @@ X extern struct pushstack stack[]; X extern int nstack; X X-extern float atof(); END-of-pic2fig/files/patch-ae echo x - pic2fig/files/patch-ac sed 's/^X//' >pic2fig/files/patch-ac << 'END-of-pic2fig/files/patch-ac' X--- figd.c.orig Sat Aug 6 19:52:43 1988 X+++ figd.c Wed Apr 3 10:27:14 2002 X@@ -6,13 +6,16 @@ X * X * Modified by Micah Beck to produce Fig code X * Modified by Micah Beck again to produce Fig 1.4 code X+ * Modified by Patrick Powell to produce Fig 3.2 code X */ X X #include X #include X #include "object.h" X X-#define DEF_PEN_SIZE 8 /* Default pen diameter */ X+/* #define DEF_PEN_SIZE 8 / * Default pen diameter */ X+#define DEF_PEN_SIZE 1 /* Default pen diameter */ X+#define DEF_FONT_SIZE 12 /* Default pen diameter */ X #define MAXPOINTS 300 /* Max number of points in a path */ X X #define bool int X@@ -23,6 +26,8 @@ X #define P_BLACK 15 X #define TEXTURE 3 X #define ORTEXTURE 7 X+#define FONT_HT 12 X+#define FONT_WIDTH 8 X X extern double sqrt(), cos(), sin(); X X@@ -31,11 +36,15 @@ X #define RES 1000.0 X #define Pix_To_In(x) (((float) x) / RES) X X-#define FIGRES 80 X+/* #define FIGRES 80 */ X+#define FIGRES 1200 X #define FIGCANV_W (8*FIGRES) X #define FIGCANV_H (10*FIGRES) X+#define Points_To_Figpix(x) ((int)(FIGRES * (x)/72.0)) X #define Pix_To_Figpix(x) ((int)(FIGRES * Pix_To_In(x))) X-#define Pen_to_Figpix(x) ((x*FIGRES + 500) / 1000) X+/* #define Pen_to_Figpix(x) ((x*FIGRES + 500) / 1000) */ X+/* pen thickness in 1/80 of inch */ X+#define Pen_to_Figpix(x) ((Pix_To_In(x) + 79) / 80) X X X extern int dbg; /* Non-zero when debugging info wanted */ X@@ -44,8 +53,10 @@ X static float xslope,yslope,xbase,ybase;/* Convert Window to Viewport */ X static int arraylen; /* Number of points in current path */ X static bool pathsent; /* True if path has been defined */ X-static int ipensize; /* Desired current pen size */ X+static int ipensize = DEF_PEN_SIZE; /* Desired current pen size */ X+static int ifontsize = DEF_FONT_SIZE; /* Desired current font size */ X extern FILE *TEXFILE; /* Output file */ X+int font = -1; /* font number */ X X X /* X@@ -62,7 +73,7 @@ X yslope = RES * (hiypage-loypage) / (hiy-loy); X ybase = RES * loypage - loy*yslope; X if (dbg) X- printf("Coefficients: %10.5f%10.5f%10.5f%10.5f\n", X+ printf("Coefficients: %10.5f %10.5f %10.5f %10.5f\n", X xslope,xbase,yslope,ybase); X } X X@@ -70,14 +81,18 @@ X /* X * Set the size of the virtual pen used in drawing X */ X+static sendpath(); X pensize(x) X int x; X { X if (x != ipensize) { X ipensize = Pen_to_Figpix(x); X+ ifontsize = x; X+ if( ipensize == 0 ) ipensize = 1; X if (!pathsent) sendpath(); X clearpath(); X } X+ if( dbg) printf("pensize %d -> %d\n", x, ipensize ); X } X X X@@ -149,24 +164,85 @@ X float x, y; X int position; /* Indicates what part of text is at (x,y) */ X { X- int ix, iy, offset; X- char *cp; X+ int ix, iy, offset, c; X+ unsigned char *cp; X map(x, y, &ix, &iy, 1); X X- for (cp = text; *cp && isspace(*text); cp++); X+ for (cp = (unsigned char *)text; isspace(*cp); cp++); X if (!*cp) return; X X #ifdef TEXT_LEFT_ONLY X- if (position != T_LEFT_JUSTIFIED) offset = strlen(cp)*8; X+ if (position != T_LEFT_JUSTIFIED) offset = strlen(cp)*Points_To_Figpix(ifontsize); X if (position == T_CENTER_JUSTIFIED) offset = offset/2; X position = T_LEFT_JUSTIFIED; X #else X offset = 0; X #endif TEXT_LEFT_ONLY X X+/* FORMAT 1.4 CODE X fprintf(TEXFILE, "%d %d %d %d %d %d %6.3f %d %d %d %d %d %s%c\n", X- O_TEXT, position, -1, -1, -1, -1, 0.0, -1, 16, strlen(cp)*8, X+ 4 justification (0,1,2) X+ font (unused) X+ fontsize (unused) X+ pen (unused) X+ color X+ depth X+ angle (not used) X+ height (pixels) X+ length (pixels) X+ X+ 4, position, -1, -1, -1, -1, 0.0, -1, 16, strlen(cp)*Points_To_Figpix(ifontsize), X Pix_To_Figpix(ix) - offset, Pix_To_Figpix(iy), cp, '\01'); X+Example: X+4 1 -1 -1 -1 -1 0.000 -1 16 24 229 603 FEP^A X+ X+FORMAT 3.2 CODE X+Example: X+4 1 -1 0 -1 -1 12 0.0000 4 135 330 3450 9060 FEP\001 X+1 2 3 4 5 6 7 8 9 10 11 12 13 14 X+ (3.7) TEXT X+ type name (brief description) X+ ---- ---- ------------------- X+ int object (always 4) 1 X+ int sub_type (0: Left justified 2 X+ 1: Center justified X+ 2: Right justified) X+ int color (enumeration type) 3 X+ int depth (enumeration type) 4 X+ int pen_style (enumeration , not used) 5 X+ int font (enumeration type) 6 X+ float font_size (font size in points) 7 X+ float angle (radians, the angle of the text) 8 X+ int font_flags (bit vector) 9 X+ float height (Fig units) 10 X+ float length (Fig units) 11 X+ int x, y (Fig units, coordinate of the origin 12,13 X+ of the string. If sub_type = 0, it is X+ the lower left corner of the string. X+ If sub_type = 1, it is the lower X+ center. Otherwise it is the lower X+ right corner of the string.) X+ char string[] (ASCII characters; starts after a blank 14 X+ character following the last number and X+ ends before the sequence '\001'. This X+ sequence is not part of the string. X+ X+ X+*/ X+ if(dbg) printf("string (%d,%d) '%s'\n", Pix_To_Figpix(ix-offset), Pix_To_Figpix(iy), cp ); X+ X+ fprintf(TEXFILE, "%d %d %d %d %d %d %d %6.3f %d %d %d %d %d ", X+ O_TEXT, position, -1, 0,-1,font,ifontsize,0.0, 4,Pix_To_Figpix(FONT_HT),Pix_To_Figpix(strlen(cp)*FONT_WIDTH), X+ Pix_To_Figpix(ix-offset), Pix_To_Figpix(iy)); X+ while( (c = ((unsigned char *)(cp))[0]) ){ X+ if( c == '\\' ){ X+ fprintf(TEXFILE, "\\\\"); X+ } else if( isprint(c) || isspace(c) ){ X+ fprintf(TEXFILE, "%c", c); X+ } X+ ++cp; X+ } X+ fprintf(TEXFILE, "\\001\n"); X } X X X@@ -208,16 +284,54 @@ X { X register int i; X X- if (dbg) printf("Sending path ...%d\n", arraylen); X+ if (dbg) printf("Sendpath [%d], ipensize %d\n", arraylen, ipensize); X if (arraylen > 1) { X X+ /* X fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", X O_POLYLINE, T_POLYLINE, SOLID_LINE, X ipensize, -1, -1, -1, -1, -1, 0, 0); X- for (i=1; i<=arraylen; i++) X- fprintf(TEXFILE, "%d %d ", X+ X+Example: X+ 2 1 0 1 -1 -1 -1 -1 -1 0 0 X+ 19 149 19 9 179 9 179 149 19 149 9999 9999 X+ X+New format: X+ 2 1 0 1 -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 5 X+ code pen_color X+ type fill_color X+ line style X+ depth X+ pen_style X+ style_value X+ join_style X+ cap_style X+ radius X+ forward_arrow X+ count X+ thickness (1/80 inch) X+ -1 = Default X+ 0 = Solid X+ 1 = Dashed X+ 2 = Dotted X+ 3 = Dash-dotted X+ 4 = Dash-double-dotted X+ 5 = Dash-triple-dotted X+ X+ 300 2250 300 150 2700 150 2700 2250 300 2250 X+ X+ X+ */ X+ fprintf(TEXFILE, "%d %d %d %d -1 -1 0 -1 -1 -1.000 0 0 -1 0 0 %d\n ", X+ 2, T_POLYLINE, SOLID_LINE, ipensize, arraylen ); X+ for (i=1; i<=arraylen; i++){ X+ if (dbg) printf(" (%d,%d)", Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); X+ fprintf(TEXFILE, "%d %d ", X Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); X- fprintf(TEXFILE, "9999 9999\n"); X+ } X+ if (dbg) printf("\n", Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); X+ /* fprintf(TEXFILE, "9999 9999\n"); */ X+ fprintf(TEXFILE, "\n"); X } X X pathsent = TRUE; X@@ -234,17 +348,26 @@ X { X register int i; X X- if (dbg) printf("Sending path ...%d\n", arraylen); X+ if (dbg) printf("Send_dashed_path ...%d, inchesperdash %f, dotted %d\n", X+ arraylen, inchesperdash, dotted ); X if (arraylen < 2) return; X else { X+/* X fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", X O_POLYLINE, T_POLYLINE, X (dotted ? DOTTED_LINE : DASH_LINE), ipensize, X -1, -1, -1, -1, -1, 0, 0); X- for (i=1; i<=arraylen; i++) X+ */ X+ fprintf(TEXFILE, "%d %d %d %d -1 -1 0 -1 -1 %f 0 0 -1 0 0 %d\n ", X+ 2, T_POLYLINE, (dotted? DOTTED_LINE: DASH_LINE), ipensize, X+ inchesperdash*80, X+ arraylen ); X+ for (i=1; i<=arraylen; i++){ X fprintf(TEXFILE, "%d %d ", X Pix_To_Figpix(xx[i]), Pix_To_Figpix(yy[i])); X- fprintf(TEXFILE, "9999 9999\n"); X+ } X+ /* fprintf(TEXFILE, "9999 9999\n"); */ X+ fprintf(TEXFILE, "\n"); X } X X pathsent = TRUE; X@@ -294,7 +417,7 @@ X fig_arc(xcenter, ycenter, xradius, yradius, start, stop) X float xcenter, ycenter, xradius, yradius, start, stop; X { X- int X0, Y0, xrad, yrad, xend, yend; X+ int X0, Y0, xrad, yrad, xend, yend, xstart, ystart; X extern double cos(), sin(); X X map(xcenter, ycenter, &X0, &Y0, FALSE); X@@ -304,18 +427,85 @@ X if (is_onarc(PI/2, start, stop)) ckbounds(X0, Y0+yrad); X if (is_onarc(PI, start, stop)) ckbounds(X0-xrad, Y0); X if (is_onarc(1.5*PI, start, stop)) ckbounds(X0, Y0-yrad); X- xend = X0 + xrad * cos(start) + 0.5; X- yend = Y0 + yrad * sin(start) + 0.5; X- ckbounds(xend, yend); X+ xstart = X0 + xrad * cos(start) + 0.5; X+ ystart = Y0 + yrad * sin(start) + 0.5; X+ ckbounds(xstart, ystart); X xend = X0 + xrad * cos(stop); X yend = Y0 + yrad * sin(stop); X ckbounds(xend, yend); X+ if(dbg) printf("Ellipse: X0 %d, Y0 %d, xrad %d, yrad %d, xstart %d, ystart %d, xend %d, yend %d\n", X+ Pix_To_Figpix(X0), Pix_To_Figpix(Y0), X+ Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), X+ Pix_To_Figpix(xstart), Pix_To_Figpix(ystart), X+ Pix_To_Figpix(xend), Pix_To_Figpix(yend)); X+ X+/* X+ int object_code (always 1) X+ int sub_type (1 : ellipse defined by radiuses X+ 2 : ellipse defined by diameters X+ 3 : circle defined by radius X+ 4 : circle defined by diameter) X+ int line_style (See the end of this section) X+ int thickness (pixels, not used) X+ int color (not used) X+ int depth (not used) X+ int pen (not used) X+ int area_fill (not used) X+ float style_val (pixels, not used) X+ int direction (always 1) X+ float angle (radian, the angle of the x-axis) X+ int center_x, center_y (pixels) X+ int radius_x, radius_y (pixels) X+ int start_x, start_y (pixels; the 1st point entered) X+ int end_x, end_y (pixels; the last point entered) X+ X+Example: X+ 1 1 0 1 -1, -1 -1 -1 -1 1 0 0.000 0.000 0.000 0.000 0.000 0.000 X X fprintf(TEXFILE, "%d %d %d %d %d, %d %d %d %d %d %d %6.3f %6.3f %6.3f %6.3f %6.3f %6.3f\n", X O_ELLIPSE, T_ELLIPSE_BY_RAD, X SOLID_LINE, ipensize, -1, -1, -1, -1, -1, 1, 0.0, X Pix_To_Figpix(X0), Pix_To_Figpix(Y0), X Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), 0.0, 0.0, 0.0, 0.0); X+ X+ X+ int object_code (always 1) X+ int sub_type (1: ellipse defined by radii X+ 2: ellipse defined by diameters X+ 3: circle defined by radius X+ 4: circle defined by diameter) X+ int line_style (enumeration type) X+ int thickness (1/80 inch) X+ -- X+ int pen_color (enumeration type, pen color) X+ int fill_color (enumeration type, fill color) X+ int depth (enumeration type) X+ int pen_style (pen style, not used) X+ int area_fill (enumeration type, -1 = no fill) X+ float style_val (1/80 inch) X+ int direction (always 1) X+ float angle (radians, the angle of the x-axis) X+ int center_x, center_y (Fig units) X+ int radius_x, radius_y (Fig units) X+ int start_x, start_y (Fig units; the 1st point entered) X+ int end_x, end_y (Fig units; the last point entered) X+ X+Example: X+ 1 1 0 1 0 7 50 0 -1 0.000 1 0.0000 1125 975 675 375 1125 975 1800 1350 X+ pen areafill X+ fill styleval X+ depth X+ pen_style X+*/ X+ X+ X+ fprintf(TEXFILE, "%d %d %d %d", O_ELLIPSE, T_ELLIPSE_BY_RAD, SOLID_LINE, ipensize ); X+ fprintf(TEXFILE, " 0 7 50 0 -1 0.0 1 0.0" ); X+ fprintf(TEXFILE, " %d %d %d %d %d %d %d %d\n", X+ Pix_To_Figpix(X0), Pix_To_Figpix(Y0), X+ Pix_To_Figpix(xrad), Pix_To_Figpix(yrad), X+ Pix_To_Figpix(xstart), Pix_To_Figpix(ystart), X+ Pix_To_Figpix(xend), Pix_To_Figpix(yend)); X } X X X@@ -347,14 +537,56 @@ X */ X fig_begin_drawing() X { X- fprintf(TEXFILE, "#FIG 1.4\n%d %d\n", FIGRES, 2); X+ X+/* X+(1) The very first line is a comment line containing the name and version: X+ #FIG 3.2 X+(2) The first non-comment line consists of the following: X+ X+ string orientation ("Landscape" or "Portrait") X+ string justification ("Center" or "Flush Left") X+ string units ("Metric" or "Inches") X+ string papersize ("Letter", "Legal", "Ledger", "Tabloid", X+ "A", "B", "C", "D", "E", X+ "A4", "A3", "A2", "A1", "A0" and "B5") X+ float magnification (export and print magnification, %) X+ string multiple-page ("Single" or "Multiple" pages) X+ int transparent color (color number for transparent color for GIF X+ export. -3=background, -2=None, -1=Default, X+ 0-31 for standard colors or 32- for user colors) X+ # optional comment (An optional set of comments may be here, X+ which are associated with the whole figure) X+ int resolution coord_system (Fig units/inch and coordinate system: X+ 1: origin at lower left corner (NOT USED) X+ 2: upper left) X+Example: X+ #FIG 3.2 X+ Landscape X+ Center X+ Inches X+ Letter X+ 100.00 X+ Single X+ -2 X+ 1200 2 X+ X+*/ X+ fprintf(TEXFILE, "#FIG 3.2\n"); X+ fprintf(TEXFILE, "Landscape\n"); X+ fprintf(TEXFILE, "Center\n"); X+ fprintf(TEXFILE, "Inches\n"); X+ fprintf(TEXFILE, "Letter\n"); X+ fprintf(TEXFILE, "100.00\n"); X+ fprintf(TEXFILE, "Single\n"); X+ fprintf(TEXFILE, "-2\n"); X+ fprintf(TEXFILE, "%d %d\n", FIGRES, 2 ); X X fig_window(0.0, 0.0, 10.0, 10.0, 0.0, 0.0, 3.0, 3.0); X xmin = 30000; xmax = -30000; X ymin = 30000; ymax = -30000; X arraylen = 0; X pathsent = FALSE; X- ipensize = Pen_to_Figpix(DEF_PEN_SIZE); X+ pensize(DEF_PEN_SIZE); X } X X X@@ -392,15 +624,67 @@ X clearpath(); X } X X+/* X fprintf(TEXFILE, "%d %d %d %d %d %d %d %d %d %d %d\n", X O_SPLINE, T_OPEN_NORMAL, X SOLID_LINE, ipensize, -1, -1, -1, -1, -1, 0, 0); X+ fprintf(TEXFILE, "9999 9999\n"); X+ X+New format: X+ int object_code (always 3) X+ int sub_type (0: open approximated spline X+ 1: closed approximated spline X+ 2: open interpolated spline X+ 3: closed interpolated spline X+ 4: open x-spline X+ 5: closed x-spline) X+ int line_style (See the end of this section) X+ int thickness (1/80 inch) X+ int pen_color (enumeration type, pen color) X+ int fill_color (enumeration type, fill color) X+ int depth (enumeration type) X+ int pen_style (pen style, not used) X+ int area_fill (enumeration type, -1 = no fill) X+ float style_val (1/80 inch) X+ int cap_style (enumeration type, only used for open splines) X+ int forward_arrow (0: off, 1: on) X+ int backward_arrow (0: off, 1: on) X+ int npoints (number of control points in spline) X+ X+ Forward arrow line: same as ARC object X+ X+ Backward arrow line: same as ARC object X+ X+ Points line: same as POLYLINE object X+ X+ Control points line : X+ X+ There is one shape factor for each point. The value of this factor X+ must be between -1 (which means that the spline is interpolated at X+ this point) and 1 (which means that the spline is approximated at X+ this point). The spline is always smooth in the neighbourhood of a X+ control point, except when the value of the factor is 0 for which X+ there is a first-order discontinuity (i.e. angular point). X+ X+Example: X+ 3 2 0 1 0 7 50 0 -1 0.000 0 0 0 3 X+ 975 1950 1875 1500 2550 1950 X+ 0.000 -1.000 0.000 X+ X+*/ X+ fprintf(TEXFILE, "%d %d %d %d", 3, 2, SOLID_LINE, ipensize ); X+ fprintf(TEXFILE, " 0 7 50 0 -1 0.000 0 0 0 %d\n ", N-1 ); X for (i=1; ipic2fig/files/patch-aa << 'END-of-pic2fig/files/patch-aa' X--- FORMAT3.2.orig Wed Apr 3 10:27:14 2002 X+++ FORMAT3.2 Wed Apr 3 10:27:14 2002 X@@ -0,0 +1,563 @@ X+/* X+ * FIG : Facility for Interactive Generation of figures X+ * Copyright (c) 1985 by Supoj Sutanthavibul X+ * Parts Copyright (c) 1989-1999 by Brian V. Smith X+ * Parts Copyright (c) 1991 by Paul King X+ * Parts Copyright (c) 1995 by C. Blanc and C. Schlick X+ * X+ * The X Consortium, and any party obtaining a copy of these files from X+ * the X Consortium, directly or indirectly, is granted, free of charge, a X+ * full and unrestricted irrevocable, world-wide, paid up, royalty-free, X+ * nonexclusive right and license to deal in this software and X+ * documentation files (the "Software"), including without limitation the X+ * rights to use, copy, modify, merge, publish, distribute, sublicense, X+ * and/or sell copies of the Software, and to permit persons who receive X+ * copies from any such party to do so, with the only requirement being X+ * that this copyright notice remain intact. This license includes without X+ * limitation a license to do the foregoing actions under any patents of X+ * the party supplying this software to the X Consortium. X+ */ X+ X+The new components in protocol 3.2 are the paper size, magnification, X+single/multiple page indicator and transparent color for GIF export in the X+header. X+ X+The other modification between version 3.1 and version 3.2 of the X+protocol is the mathematical model used for splines. The new version X+uses X-splines which allows the user to mix interpolation and approximation X+points in a same curve. More precisely, it means that an X-spline curve X+is neither an interpolated spline nor an approximated one, it is BOTH X+(the behaviour of each point is controlled by one single parameter X+called "shape factor"). For additional information about X-splines, see: X+ X+ "X-Splines: A Spline Model Designed for the End User" X+ by C. Blanc and C. Schlick, Proceedings of SIGGRAPH'95 X+ X+Caveat: Because spline models of previous versions (quadratic B-splines X+and Bezier with hidden points) are no longer supported, curves that are X+present in version 3.1 and older files are automatically converted to X+X-splines. This translation is only an approximation process. It means X+that the converted curves are not exactly the same as the original ones. X+Though the translation usually provides almost identical curves, some X+hand-fitting may be needed in some pathological cases. X+ X+------------------------------------------------------------------------------- X+Description of the Fig Format Follows X+------------------------------------------------------------------------------- X+ X+(1) The very first line is a comment line containing the name and version: X+ #FIG 3.2 X+ X+ The character # at the first column of a line indicates that the line X+ is a comment line which will be preserved when the Fig file is read in. X+ The user may edit them with the popup editor. X+ X+ The comment line(s) must immediately precede the object to which they X+ are associated. In the case of the "whole figure comments" mentioned X+ below, they immediately precede the (resolution,coord_system) line. X+ X+(2) The first non-comment line consists of the following: X+ X+ string orientation ("Landscape" or "Portrait") X+ string justification ("Center" or "Flush Left") X+ string units ("Metric" or "Inches") X+ string papersize ("Letter", "Legal", "Ledger", "Tabloid", X+ "A", "B", "C", "D", "E", X+ "A4", "A3", "A2", "A1", "A0" and "B5") X+ float magnification (export and print magnification, %) X+ string multiple-page ("Single" or "Multiple" pages) X+ int transparent color (color number for transparent color for GIF X+ export. -3=background, -2=None, -1=Default, X+ 0-31 for standard colors or 32- for user colors) X+ # optional comment (An optional set of comments may be here, X+ which are associated with the whole figure) X+ int resolution coord_system (Fig units/inch and coordinate system: X+ 1: origin at lower left corner (NOT USED) X+ 2: upper left) X+ X+ Fig_resolution is the resolution of the figure in the file. X+ Xfig will always write the file with a resolution of 1200ppi so it X+ will scale the figure upon reading it in if its resolution is different X+ from 1200ppi. Pixels are assumed to be square. X+ X+ Xfig will read the orientation string and change the canvas to match X+ either the Landscape or Portrait mode of the figure file. X+ X+ The units specification is self-explanatory. X+ X+ The coordinate_system variable is ignored - the origin is ALWAYS the X+ upper-left corner. X+ X+ ** Coordinates are given in "fig_resolution" units. X+ ** Line thicknesses are given in 1/80 inch (0.3175mm) or 1 screen pixel. X+ When exporting to EPS, PostScript or any bitmap format (e.g. GIF), the X+ line thickness is reduced to 1/160 inch (0.159mm) to "lighten" the look. X+ ** dash-lengths/dot-gaps are given in 80-ths of an inch. X+ X+ X+(3) The rest of the file contains various objects. An object can be one X+ of six classes (or types). X+ X+ 0) Color pseudo-object. X+ 1) Arc. X+ 2) Ellipse which is a generalization of circle. X+ 3) Polyline which includes polygon and box. X+ 4) Spline which includes X+ closed/open approximated/interpolated/x-spline spline. X+ 5) Text. X+ 6) Compound object which is composed of one or more objects. X+ X+ In the following elaboration on object formats, every value of fig X+ output are separated by blank characters or new line ('\n'). The X+ value of the unused parameters will be -1. X+ X+ Some fields are described as "enumeration type" or "bit vector"; the X+ values which these fields can take are defined in the header file object.h. X+ The pen_style field is unused. X+ These values may be defined in some future version of Fig. X+ X+ The two color fields (pen and fill; pen only, for texts) are X+ defined as follows: X+ X+ -1 = Default X+ 0 = Black X+ 1 = Blue X+ 2 = Green X+ 3 = Cyan X+ 4 = Red X+ 5 = Magenta X+ 6 = Yellow X+ 7 = White X+ 8-11 = four shades of blue (dark to lighter) X+ 12-14 = three shades of green (dark to lighter) X+ 15-17 = three shades of cyan (dark to lighter) X+ 18-20 = three shades of red (dark to lighter) X+ 21-23 = three shades of magenta (dark to lighter) X+ 24-26 = three shades of brown (dark to lighter) X+ 27-30 = four shades of pink (dark to lighter) X+ 31 = Gold X+ X+ values from 32 to 543 (512 total) are user colors and X+ are defined in color pseudo-objects (type 0) X+ X+ Your X server may limit the number of colors to something less X+ than this, especially on a 8-bit PseudoColor visual, where X+ the number of usable colors will be 256 minus the number of colors X+ xfig preallocates for itself and the 32 standard colors (about 48). X+ X+ For WHITE color, the area fill field is defined as follows: X+ X+ -1 = not filled X+ 0 = black X+ ... values from 1 to 19 are shades of grey, from darker to lighter X+ 20 = white X+ 21-40 not used X+ 41-56 see patterns for colors, below X+ X+ For BLACK or DEFAULT color, the area fill field is defined as follows: X+ X+ -1 = not filled X+ 0 = white X+ ... values from 1 to 19 are shades of grey, from lighter to darker X+ 20 = black X+ 21-40 not used X+ 41-56 see patterns for colors, below X+ X+ For all other colors, the area fill field is defined as follows: X+ X+ -1 = not filled X+ 0 = black X+ ... values from 1 to 19 are "shades" of the color, from darker to lighter. X+ A shade is defined as the color mixed with black X+ 20 = full saturation of the color X+ ... values from 21 to 39 are "tints" of the color from the color to white. X+ A tint is defined as the color mixed with white X+ 40 = white X+ 41 = 30 degree left diagonal pattern X+ 42 = 30 degree right diagonal pattern X+ 43 = 30 degree crosshatch X+ 44 = 45 degree left diagonal pattern X+ 45 = 45 degree right diagonal pattern X+ 46 = 45 degree crosshatch X+ 47 = horizontal bricks X+ 48 = vertical bricks X+ 49 = horizontal lines X+ 50 = vertical lines X+ 51 = crosshatch X+ 52 = horizontal "shingles" skewed to the right X+ 53 = horizontal "shingles" skewed to the left X+ 54 = vertical "shingles" skewed one way X+ 55 = vertical "shingles"skewed the other way X+ 56 = fish scales X+ 57 = small fish scales X+ 58 = circles X+ 59 = hexagons X+ 60 = octagons X+ 61 = horizontal "tire treads" X+ 62 = vertical "tire treads" X+ X+ The depth field is defined as follows: X+ X+ 0 ... 999 where larger value means object is deeper than (under) X+ objects with smaller depth X+ X+ The line_style field is defined as follows: X+ X+ -1 = Default X+ 0 = Solid X+ 1 = Dashed X+ 2 = Dotted X+ 3 = Dash-dotted X+ 4 = Dash-double-dotted X+ 5 = Dash-triple-dotted X+ X+ The style_val field is defined as the length, in 1/80 inches, of the on/off X+ dashes for dashed lines, and the distance between the dots, in 1/80 inches, X+ for dotted lines. X+ X+ The join_style field is defined FOR LINES only as follows: X+ X+ 0 = Miter (the default in xfig 2.1 and earlier) X+ 1 = Round X+ 2 = Bevel X+ X+ The cap_style field is defined FOR LINES, OPEN SPLINES and ARCS only as follows: X+ X+ 0 = Butt (the default in xfig 2.1 and earlier) X+ 1 = Round X+ 2 = Projecting X+ X+ The arrow_type field is defined for LINES, ARCS and OPEN SPLINES X+ only as follows: X+ X+ 0 = Stick-type (the default in xfig 2.1 and earlier) X+ X+ \ X+ \ X+ _______________\ X+ / X+ / X+ / X+ X+ 1 = Closed triangle: X+ X+ |\ X+ | \ X+ ________| \ X+ | / X+ | / X+ |/ X+ X+ 2 = Closed with "indented" butt: X+ X+ |\ X+ \ \ X+ \ \ X+ __________\ \ X+ / / X+ / / X+ / / X+ |/ X+ X+ 3 = Closed with "pointed" butt: X+ X+ /\ X+ / \ X+ / \ X+ ________/ \ X+ \ / X+ \ / X+ \ / X+ \/ X+ X+ The arrow_style field is defined for LINES, ARCS and OPEN SPLINES X+ only as follows: X+ X+ 0 = Hollow (actually filled with white) X+ 1 = Filled with pen_color X+ X+(3.0) OBJECT DEFINITION: X+ X+ (3.1) Color Pseudo-objects (user-defined colors) X+ This is used to define arbitrary colors beyond the 32 standard colors. X+ The color objects must be defined before any other Fig objects. X+ X+ First line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int object_code (always 0) X+ int color_number (color number, from 32-543 (512 total)) X+ hex string rgb values (hexadecimal string describing red, X+ green and blue values (e.g. #330099) ) X+ X+ (3.2) ARC X+ X+ First line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int object_code (always 5) X+ int sub_type (1: open ended arc X+ 2: pie-wedge (closed) ) X+ int line_style (enumeration type) X+ int line_thickness (1/80 inch) X+ int pen_color (enumeration type, pen color) X+ int fill_color (enumeration type, fill color) X+ int depth (enumeration type) X+ int pen_style (pen style, not used) X+ int area_fill (enumeration type, -1 = no fill) X+ float style_val (1/80 inch) X+ int cap_style (enumeration type) X+ int direction (0: clockwise, 1: counterclockwise) X+ int forward_arrow (0: no forward arrow, 1: on) X+ int backward_arrow (0: no forward arrow, 1: on) X+ float center_x, center_y (center of the arc) X+ int x1, y1 (Fig units, the 1st point the user entered) X+ int x2, y2 (Fig units, the 2nd point) X+ int x3, y3 (Fig units, the last point) X+ X+ Forward arrow line (Optional; absent if forward_arrow is 0): X+ type name (brief description) X+ ---- ---- ------------------- X+ int arrow_type (enumeration type) X+ int arrow_style (enumeration type) X+ float arrow_thickness (1/80 inch) X+ float arrow_width (Fig units) X+ float arrow_height (Fig units) X+ X+ Backward arrow line (Optional; absent if backward_arrow is 0): X+ type name (brief description) X+ ---- ---- ------------------- X+ int arrow_type (enumeration type) X+ int arrow_style (enumeration type) X+ float arrow_thickness (1/80 inch) X+ float arrow_width (Fig units) X+ float arrow_height (Fig units) X+ X+ (3.3) COMPOUND X+ X+ A line with object code 6 signifies the start of a compound. X+ There are four more numbers on this line which indicate the X+ upper left corner and the lower right corner of the bounding X+ box of this compound. A line with object code -6 signifies X+ the end of the compound. Compound may be nested. X+ X+ First line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int object_code (always 6) X+ int upperleft_corner_x (Fig units) X+ int upperleft_corner_y (Fig units) X+ int lowerright_corner_x (Fig units) X+ int lowerright_corner_y (Fig units) X+ X+ Subsequent lines: X+ objects X+ . X+ . X+ X+ Last line: X+ -6 X+ X+ (3.4) ELLIPSE X+ X+ First line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int object_code (always 1) X+ int sub_type (1: ellipse defined by radii X+ 2: ellipse defined by diameters X+ 3: circle defined by radius X+ 4: circle defined by diameter) X+ int line_style (enumeration type) X+ int thickness (1/80 inch) X+ int pen_color (enumeration type, pen color) X+ int fill_color (enumeration type, fill color) X+ int depth (enumeration type) X+ int pen_style (pen style, not used) X+ int area_fill (enumeration type, -1 = no fill) X+ float style_val (1/80 inch) X+ int direction (always 1) X+ float angle (radians, the angle of the x-axis) X+ int center_x, center_y (Fig units) X+ int radius_x, radius_y (Fig units) X+ int start_x, start_y (Fig units; the 1st point entered) X+ int end_x, end_y (Fig units; the last point entered) X+ X+ (3.5) POLYLINE X+ X+ First line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int object_code (always 2) X+ int sub_type (1: polyline X+ 2: box X+ 3: polygon X+ 4: arc-box) X+ 5: imported-picture bounding-box) X+ int line_style (enumeration type) X+ int thickness (1/80 inch) X+ int pen_color (enumeration type, pen color) X+ int fill_color (enumeration type, fill color) X+ int depth (enumeration type) X+ int pen_style (pen style, not used) X+ int area_fill (enumeration type, -1 = no fill) X+ float style_val (1/80 inch) X+ int join_style (enumeration type) X+ int cap_style (enumeration type, only used for POLYLINE) X+ int radius (1/80 inch, radius of arc-boxes) X+ int forward_arrow (0: off, 1: on) X+ int backward_arrow (0: off, 1: on) X+ int npoints (number of points in line) X+ X+ Forward arrow line: same as ARC object X+ X+ Backward arrow line: same as ARC object X+ X+ Points line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int x1, y1 (Fig units) X+ int x2, y2 (Fig units) X+ . X+ . X+ int xnpoints ynpoints (this will be the same as the 1st X+ point for polygon and box) X+ X+ PIC line: X+ type name (brief description) X+ ---- ---- ------------------- X+ boolean flipped orientation = normal (0) or flipped (1) X+ char file[] name of picture file to import X+ X+ (3.6) SPLINE X+ X+ First line: X+ type name (brief description) X+ ---- ---- ------------------- X+ int object_code (always 3) X+ int sub_type (0: open approximated spline X+ 1: closed approximated spline X+ 2: open interpolated spline X+ 3: closed interpolated spline X+ 4: open x-spline X+ 5: closed x-spline) X+ int line_style (See the end of this section) X+ int thickness (1/80 inch) X+ int pen_color (enumeration type, pen color) X+ int fill_color (enumeration type, fill color) X+ int depth (enumeration type) X+ int pen_style (pen style, not used) X+ int area_fill (enumeration type, -1 = no fill) X+ float style_val (1/80 inch) X+ int cap_style (enumeration type, only used for open splines) X+ int forward_arrow (0: off, 1: on) X+ int backward_arrow (0: off, 1: on) X+ int npoints (number of control points in spline) X+ X+ Forward arrow line: same as ARC object X+ X+ Backward arrow line: same as ARC object X+ X+ Points line: same as POLYLINE object X+ X+ Control points line : X+ X+ There is one shape factor for each point. The value of this factor X+ must be between -1 (which means that the spline is interpolated at X+ this point) and 1 (which means that the spline is approximated at X+ this point). The spline is always smooth in the neighbourhood of a X+ control point, except when the value of the factor is 0 for which X+ there is a first-order discontinuity (i.e. angular point). X+ X+ (3.7) TEXT X+ type name (brief description) X+ ---- ---- ------------------- X+ int object (always 4) X+ int sub_type (0: Left justified X+ 1: Center justified X+ 2: Right justified) X+ int color (enumeration type) X+ int depth (enumeration type) X+ int pen_style (enumeration , not used) X+ int font (enumeration type) X+ float font_size (font size in points) X+ float angle (radians, the angle of the text) X+ int font_flags (bit vector) X+ float height (Fig units) X+ float length (Fig units) X+ int x, y (Fig units, coordinate of the origin X+ of the string. If sub_type = 0, it is X+ the lower left corner of the string. X+ If sub_type = 1, it is the lower X+ center. Otherwise it is the lower X+ right corner of the string.) X+ char string[] (ASCII characters; starts after a blank X+ character following the last number and X+ ends before the sequence '\001'. This X+ sequence is not part of the string. X+ Characters above octal 177 are X+ represented by \xxx where xxx is the X+ octal value. This permits fig files to X+ be edited with 7-bit editors and sent X+ by e-mail without data loss. X+ Note that the string may contain '\n'.) X+ X+ The font_flags field is defined as follows: X+ X+ Bit Description X+ X+ 0 Rigid text (text doesn't scale when scaling compound objects) X+ 1 Special text (for LaTeX) X+ 2 PostScript font (otherwise LaTeX font is used) X+ 3 Hidden text X+ X+ The font field is defined as follows: X+ X+ For font_flags bit 2 = 0 (LaTeX fonts): X+ X+ 0 Default font X+ 1 Roman X+ 2 Bold X+ 3 Italic X+ 4 Sans Serif X+ 5 Typewriter X+ X+ For font_flags bit 2 = 1 (PostScript fonts): X+ X+ (.ft value) X+ -1 Default font X+ 0 Times Roman X+ 1 Times Italic X+ 2 Times Bold X+ 3 Times Bold Italic X+ 4 AvantGarde Book X+ 5 AvantGarde Book Oblique X+ 6 AvantGarde Demi X+ 7 AvantGarde Demi Oblique X+ 8 Bookman Light X+ 9 Bookman Light Italic X+ 10 Bookman Demi X+ 11 Bookman Demi Italic X+ 12 Courier X+ 13 Courier Oblique X+ 14 Courier Bold X+ 15 Courier Bold Oblique X+ 16 Helvetica X+ 17 Helvetica Oblique X+ 18 Helvetica Bold X+ 19 Helvetica Bold Oblique X+ 20 Helvetica Narrow X+ 21 Helvetica Narrow Oblique X+ 22 Helvetica Narrow Bold X+ 23 Helvetica Narrow Bold Oblique X+ 24 New Century Schoolbook Roman X+ 25 New Century Schoolbook Italic X+ 26 New Century Schoolbook Bold X+ 27 New Century Schoolbook Bold Italic X+ 28 Palatino Roman X+ 29 Palatino Italic X+ 30 Palatino Bold X+ 31 Palatino Bold Italic X+ 32 Symbol X+ 33 Zapf Chancery Medium Italic X+ 34 Zapf Dingbats END-of-pic2fig/files/patch-aa echo x - pic2fig/files/patch-ab sed 's/^X//' >pic2fig/files/patch-ab << 'END-of-pic2fig/files/patch-ab' X--- Makefile.orig Mon Apr 29 10:11:02 1991 X+++ Makefile Wed Apr 3 10:27:14 2002 X@@ -1,7 +1,7 @@ X BINDIR = /usr/local/bin X-CFLAGS = -O4 -s $(CROSS) X+#CFLAGS = -O4 -s $(CROSS) X #LDFLAGS= -zs X-LDFLAGS= -z $(CROSS) X+#LDFLAGS= -z $(CROSS) X YFLAGS = -d X X MOFILES = main.o boxgen.o print.o misc.o symtab.o blockgen.o circgen.o \ X@@ -29,7 +29,7 @@ X -@echo "" X X pic2fig: picy.o picl.o $(OFILES) X- cc $(LDFLAGS) -o $@ picy.o picl.o $(OFILES) -lm X+ $(CC) $(LDFLAGS) -o $@ picy.o picl.o $(OFILES) -lm X X # The following .o files depend of picy.c, since they really need picy.h X picl.o: picl.c pic.h picy.c END-of-pic2fig/files/patch-ab echo x - pic2fig/files/patch-ad sed 's/^X//' >pic2fig/files/patch-ad << 'END-of-pic2fig/files/patch-ad' X--- main.c.orig Mon Feb 8 06:21:12 1988 X+++ main.c Wed Apr 3 10:28:56 2002 X@@ -1,10 +1,10 @@ X #include X #include X+#include X #include "pic.h" X #include "picy.h" X X static reset(); X-extern char *sprintf(), *strcpy(); X X struct obj *objlist[MAXOBJ]; /* store the elements here */ X int nobj = 0; X@@ -27,7 +27,7 @@ X float deltx = 6; /* max x value in output, for scaling */ X float delty = 6; /* max y value in output, for scaling */ X int dbg = 0; X-extern FILE *yyin; /* input file pointer */ X+extern FILE *yyin, *yyout; /* input and out file pointers */ X FILE *TEXFILE; /* Output file */ X int lineno = 0; X char *filename = "-"; X@@ -51,6 +51,7 @@ X { X char TEXfilename[BUFSIZ], buffer[BUFSIZ], *bp, *rindex(); X X+ yyin = stdin; yyout = stdout; X cmdname = argv[0]; X while (argc > 1 && *argv[1] == '-') { X switch (argv[1][1]) { END-of-pic2fig/files/patch-ad echo x - pic2fig/files/patch-af sed 's/^X//' >pic2fig/files/patch-af << 'END-of-pic2fig/files/patch-af' X--- pic2fig.1.orig Thu Feb 11 05:34:07 1988 X+++ pic2fig.1 Wed Apr 3 10:27:14 2002 X@@ -55,6 +55,51 @@ X must be given in the first column. Changing the drawing thickness applies X to solid, dashed, and dotted lines, as well as circles, arcs, and ellipses. X .PP X+Setting the font for text may be done using a X+.ti +.5i X+\&.ft \fIn\fR X+ X+command, where \fIn\fR corresponds to the following PostScript fonts: X+.nf X+-1 Default font X+ 0 Times Roman X+ 1 Times Italic X+ 2 Times Bold X+ 3 Times Bold Italic X+ 4 AvantGarde Book X+ 5 AvantGarde Book Oblique X+ 6 AvantGarde Demi X+ 7 AvantGarde Demi Oblique X+ 8 Bookman Light X+ 9 Bookman Light Italic X+10 Bookman Demi X+11 Bookman Demi Italic X+12 Courier X+13 Courier Oblique X+14 Courier Bold X+15 Courier Bold Oblique X+16 Helvetica X+17 Helvetica Oblique X+18 Helvetica Bold X+19 Helvetica Bold Oblique X+20 Helvetica Narrow X+21 Helvetica Narrow Oblique X+22 Helvetica Narrow Bold X+23 Helvetica Narrow Bold Oblique X+24 New Century Schoolbook Roman X+25 New Century Schoolbook Italic X+26 New Century Schoolbook Bold X+27 New Century Schoolbook Bold Italic X+28 Palatino Roman X+29 Palatino Italic X+30 Palatino Bold X+31 Palatino Bold Italic X+32 Symbol X+33 Zapf Chancery Medium Italic X+34 Zapf Dingbats X+.fi X+ X+.PP X Normally, the distance between text is 12 points. If you're using larger X text to label objects, this should be set to an appropriate larger value. X This can be done using the END-of-pic2fig/files/patch-af echo x - pic2fig/files/patch-ag sed 's/^X//' >pic2fig/files/patch-ag << 'END-of-pic2fig/files/patch-ag' X--- picl.c.orig Wed Apr 3 10:27:34 2002 X+++ picl.c Wed Apr 3 10:29:53 2002 X@@ -17,7 +17,7 @@ X int yymorfg; X extern char *yysptr, yysbuf[]; X int yytchar; X-FILE *yyin = {stdin}, *yyout = {stdout}; X+FILE *yyin, *yyout; X extern int yylineno; X struct yysvf { X struct yywork *yystoff; X@@ -40,7 +40,6 @@ X #include "pic.h" X # include "picy.h" X X-extern float atof(); X extern char *filename; X extern int synerr; X END-of-pic2fig/files/patch-ag echo x - pic2fig/files/patch-ah sed 's/^X//' >pic2fig/files/patch-ah << 'END-of-pic2fig/files/patch-ah' X--- plfig.c.orig Tue Jul 5 09:21:25 1988 X+++ plfig.c Wed Apr 3 10:27:15 2002 X@@ -121,7 +121,48 @@ X htrue = vtrue = 0; X } X X-troff(s) /* handle ".ps n" to set the pen size to "n" pixels */ X+/* handle ".ps n" to set the pen size to "n" pixels */ X+/* handle ".ft n" to set the output font to number n X+ (.ft value) X+ -1 Default font X+ 0 Times Roman X+ 1 Times Italic X+ 2 Times Bold X+ 3 Times Bold Italic X+ 4 AvantGarde Book X+ 5 AvantGarde Book Oblique X+ 6 AvantGarde Demi X+ 7 AvantGarde Demi Oblique X+ 8 Bookman Light X+ 9 Bookman Light Italic X+ 10 Bookman Demi X+ 11 Bookman Demi Italic X+ 12 Courier X+ 13 Courier Oblique X+ 14 Courier Bold X+ 15 Courier Bold Oblique X+ 16 Helvetica X+ 17 Helvetica Oblique X+ 18 Helvetica Bold X+ 19 Helvetica Bold Oblique X+ 20 Helvetica Narrow X+ 21 Helvetica Narrow Oblique X+ 22 Helvetica Narrow Bold X+ 23 Helvetica Narrow Bold Oblique X+ 24 New Century Schoolbook Roman X+ 25 New Century Schoolbook Italic X+ 26 New Century Schoolbook Bold X+ 27 New Century Schoolbook Bold Italic X+ 28 Palatino Roman X+ 29 Palatino Italic X+ 30 Palatino Bold X+ 31 Palatino Bold Italic X+ 32 Symbol X+ 33 Zapf Chancery Medium Italic X+ 34 Zapf Dingbats X+*/ X+ X+troff(s) X char *s; X { X if (strncmp (s, ".ps", 3) == 0) { X@@ -131,6 +172,16 @@ X pensize (size); X else X fprintf (stderr, "Malformed .ps command: %s\n", s); X+ return; X+ } X+ if (strncmp (s, ".ft", 3) == 0) { X+ int size; X+ extern int font; X+ X+ if (sscanf (s + 3, " %d ", &size) == 1) X+ font = size; X+ else X+ fprintf (stderr, "Malformed .ft command: %s\n", s); X return; X } X END-of-pic2fig/files/patch-ah exit >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message