#! /bin/sh
# This is a shell archive.  Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file".  To overwrite existing
# files, type "sh file -c".  You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g..  If this archive is complete, you
# will see the following message at the end:
#		"End of shell archive."
# Contents:  Imakefile XTobdf.ad chars.c defs.h header.c props.c
#   trailer.c xtobdf.c xtobdf.man
# Wrapped by jim@verbosa on Fri Apr  9 22:02:33 1993
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'Imakefile' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'Imakefile'\"
else
echo shar: Extracting \"'Imakefile'\" \(288 characters\)
sed "s/^X//" >'Imakefile' <<'END_OF_FILE'
X        DEPLIBS = $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB)
XLOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB)
X           SRCS = xtobdf.c header.c props.c chars.c trailer.c 
X           OBJS = xtobdf.o header.o props.o chars.o trailer.o 
X
XComplexProgramTarget(xtobdf)
XInstallAppDefaults(XTobdf)
END_OF_FILE
if test 288 -ne `wc -c <'Imakefile'`; then
    echo shar: \"'Imakefile'\" unpacked with wrong size!
fi
# end of 'Imakefile'
fi
if test -f 'XTobdf.ad' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'XTobdf.ad'\"
else
echo shar: Extracting \"'XTobdf.ad'\" \(1439 characters\)
sed "s/^X//" >'XTobdf.ad' <<'END_OF_FILE'
X*Prop.ADD_STYLE_NAME:		string
X*Prop.AUTHOR:			string
X*Prop.AVERAGE_WIDTH:		card
X*Prop.AVG_CAPITAL_WIDTH:	int
X*Prop.AVG_LOWERCASE_WIDTH:	int
X*Prop.CAP_HEIGHT:		card
X*Prop.CHARSET_COLLECTIONS:	string
X*Prop.CHARSET_ENCODING:		string
X*Prop.CHARSET_REGISTRY:		string
X*Prop.COPYRIGHT:		string
X*Prop.DATE:			string
X*Prop.DEFAULT_CHAR:		card
X*Prop.DESTINATION:		card
X*Prop.DEVICE_FONT_NAME:		string
X*Prop.END_SPACE:		card
X*Prop.FACE_NAME:		string
X*Prop.FAMILY_NAME:		string
X*Prop.FIGURE_WIDTH:		int
X*Prop.FONT:			string
X*Prop.FONTNAME_REGISTRY:	string
X*Prop.FONT_ASCENT:		int
X*Prop.FONT_DESCENT:		int
X*Prop.FOUNDRY:			string
X*Prop.FULL_NAME:		string
X*Prop.ITALIC_ANGLE:		int
X*Prop.MAX_SPACE:		card
X*Prop.MIN_SPACE:		card
X*Prop.NAME:			string
X*Prop.NORM_SPACE:		card
X*Prop.NOTICE:			string
X*Prop.PIXEL_SIZE:		card
X*Prop.POINT_SIZE:		card
X*Prop.QUAD_WIDTH:		int
X*Prop.RELATIVE_SETWIDTH:	card
X*Prop.RELATIVE_WEIGHT:		card
X*Prop.RESOLUTION:		card
X*Prop.RESOLUTION_X:		card
X*Prop.RESOLUTION_Y:		card
X*Prop.SETWIDTH_NAME:		string
X*Prop.SLANT:			string
X*Prop.SMALL_CAP_SIZE:		card
X*Prop.SPACING:			string
X*Prop.STRIKEOUT_ASCENT:		int
X*Prop.STRIKEOUT_DESCENT:	int
X*Prop.SUBSCRIPT_SIZE:		card
X*Prop.SUBSCRIPT_X:		int
X*Prop.SUBSCRIPT_Y:		int
X*Prop.SUPERSCRIPT_SIZE:		card
X*Prop.SUPERSCRIPT_X:		int
X*Prop.SUPERSCRIPT_Y:		int
X*Prop.UNDERLINE_POSITION:	int
X*Prop.UNDERLINE_THICKNESS:	card
X*Prop.WEIGHT:			card
X*Prop.WEIGHT_NAME:		string
X*Prop.X_HEIGHT:			card
END_OF_FILE
if test 1439 -ne `wc -c <'XTobdf.ad'`; then
    echo shar: \"'XTobdf.ad'\" unpacked with wrong size!
fi
# end of 'XTobdf.ad'
fi
if test -f 'chars.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'chars.c'\"
else
echo shar: Extracting \"'chars.c'\" \(7105 characters\)
sed "s/^X//" >'chars.c' <<'END_OF_FILE'
X/*
X * $XConsortium: chars.c,v 1.7 90/05/11 17:55:59 jim Exp $
X *
X * Copyright 1990 Massachusetts Institute of Technology
X *
X * Permission to use, copy, modify, distribute, and sell this software and its
X * documentation for any purpose is hereby granted without fee, provided that
X * the above copyright notice appear in all copies and that both that
X * copyright notice and this permission notice appear in supporting
X * documentation, and that the name of M.I.T. not be used in advertising or
X * publicity pertaining to distribution of the software without specific,
X * written prior permission.  M.I.T. makes no representations about the
X * suitability of this software for any purpose.  It is provided "as is"
X * without express or implied warranty.
X *
X * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
X * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
X * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
X * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
X * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
X *
X * Author:  Jim Fulton, MIT X Consortium
X */
X
X#include "defs.h"
X
X
Xstatic void emit_bitmap (output, dpy, fs, cs, n, boldit)
X    FILE *output;
X    Display *dpy;
X    XFontStruct *fs;
X    XCharStruct *cs;
X    unsigned int n;
X    Bool boldit;
X{
X    char *glyphname;
X    static GC gc = NULL, gcclear = NULL;
X    static Pixmap pixmap = None;
X    static unsigned int pixmap_width = 0, pixmap_height = 0;
X    unsigned int width, height;
X    XChar2b thechar;
X    XImage *image;
X
X    if (!fs) {
X	if (pixmap) {
X	    XFreePixmap (dpy, pixmap);
X	    pixmap = None;
X	    pixmap_width = pixmap_height = 0;
X	}
X	if (gc) {
X	    XFreeGC (dpy, gc);
X	    XFreeGC (dpy, gcclear);
X	    gc = gcclear = NULL;
X	}
X	return;
X    }
X
X    /*
X     * format:
X     *     STARTCHAR name
X     *     ENCODING index
X     *     SWIDTH scalablewidth 0
X     *     DWIDTH pixels 0
X     *     BBX width height xoff yoff
X     *     ATTRIBUTES xxxx
X     *     BITMAP
X     *     hhhhhhhh
X     *     ...
X     *     ENDCHAR
X     *
X     * where, SWIDTH * (point / 1000) * (yres / 72) = DWIDTH
X     *    or, SWIDTH = 72000 * DWIDTH / (point * yres)
X     */
X
X    fprintf (output, "STARTCHAR ");
X    glyphname = XKeysymToString ((KeySym) n);
X    if (glyphname) {
X	fputs (glyphname, output);
X    } else {
X	fprintf (output, (fs->max_byte1 > 0 ? "C%06o" : "C%03o"), n);
X    }
X    putc ('\n', output);
X    fprintf (output, "ENCODING %u\n", n);
X    fprintf (output, "SWIDTH %ld 0\n", 
X	     (((long) cs->width) * 72000L) / (font_point_size * font_yres));
X    fprintf (output, "DWIDTH %d 0\n", cs->width);
X    fprintf (output, "BBX %d %d %d %d\n",
X	     cs->rbearing - cs->lbearing, cs->ascent + cs->descent,
X	     cs->lbearing, -cs->descent);
X    if (cs->attributes)
X      fprintf (output, "ATTRIBUTES 0x%04x\n", cs->attributes);
X    fprintf (output, "BITMAP\n");
X
X    /*
X     * draw into a pixmap, get the image, walk through it, emit
X     */
X    width = (unsigned) (cs->rbearing - cs->lbearing);
X    height = (unsigned) (cs->ascent + cs->descent);
X    if (width > pixmap_width || height > pixmap_height || pixmap == None) {
X	if (pixmap) XFreePixmap (dpy, pixmap);
X	pixmap_width = width + (unsigned int) font_point_size + 1;
X	pixmap_height = height + (unsigned int) font_point_size + 1;
X	pixmap = XCreatePixmap (dpy, RootWindow(dpy,DefaultScreen(dpy)),
X				pixmap_width, pixmap_height, (unsigned int) 1);
X    }
X    if (!gc) {
X	XGCValues gcv;
X
X	gcv.background = 0L;
X	gcv.foreground = 1L;
X	gcv.font = fs->fid;
X	gc = XCreateGC (dpy, pixmap, (GCForeground | GCBackground | GCFont),
X			&gcv);
X	gcclear = XCreateGC (dpy, pixmap, 0L, NULL);
X    }
X    if (boldit) {
X	width++;
X	height++;
X    }
X    XFillRectangle (dpy, pixmap, gcclear, 0, 0, width, height);
X    thechar.byte1 = ((n >> 8) & 0xff00);  /* high eight bits */
X    thechar.byte2 = (n & 0x00ff);	/* low eight bits */
X    XDrawString16 (dpy, pixmap, gc, -cs->lbearing, cs->ascent, &thechar, 1);
X    if (boldit)
X	XDrawString16 (dpy, pixmap, gc, -cs->lbearing + 1,
X		       cs->ascent, &thechar, 1);
X    image = XGetImage (dpy, pixmap, 0, 0, width, height, AllPlanes, XYPixmap);
X    if (!image) {
X	fprintf (stderr, "%s:  unable to get image for character ",
X		 ProgramName);
X	if (glyphname) {
X	    fprintf (stderr, "\"%s\"\n", glyphname);
X	} else {
X	    fprintf (stderr, "0x%04x\n", n);
X	}
X    } else {
X	int x, y;
X
X	/*
X	 * walk through image from left to right, setting MSB
X	 */
X	for (y = 0; y < height; y++) {
X	    static unsigned int masktab[] = {
X		(1 << 7), (1 << 6), (1 << 5), (1 << 4),
X		(1 << 3), (1 << 2), (1 << 1), (1 << 0), 
X	    };
X	    unsigned int val;
X	    int bit;
X	    for (x = 0, bit = 0, val = 0; x < width; x++) {
X		if (XGetPixel (image, x, y)) val |= masktab[bit];
X		if (++bit == 8) {
X		    fprintf (output, "%02x", val);
X		    bit = 0;
X		    val = 0;
X		}
X	    }
X	    if (bit) fprintf (output, "%02x", val);
X	    putc ('\n', output);
X	}
X	XDestroyImage (image);
X    }
X
X    fprintf (output, "ENDCHAR\n");
X}
X
X
XBool emit_characters (output, dpy, fs, boldit)
X    FILE *output;
X    Display *dpy;
X    XFontStruct *fs;
X    Bool boldit;
X{
X    XCharStruct *cs;
X    unsigned int n, saven;
X    int byte1, byte2;
X    unsigned int nchars = 0;
X    XChar2b defc;
X    Bool nonzerodefc;
X
X#define NONZERO_CHAR(cs) ((cs)->width != 0 || (cs)->lbearing != (cs)->rbearing)
X
X    /*
X     * determine whether or not default character is different from zero-width
X     * character
X     */
X    defc.byte1 = ((fs->default_char >> 8) & 0xff00);  /* high */
X    defc.byte2 = (fs->default_char & 0x00ff);  /* low */
X    nonzerodefc = (defc.byte1 >= fs->min_byte1 &&
X		   defc.byte1 <= fs->max_byte1 &&
X		   defc.byte2 >= fs->min_char_or_byte2 &&
X		   defc.byte2 <= fs->max_char_or_byte2);
X    if (nonzerodefc) {			/* if default character exists */
X	int dir, fasc, fdesc;
X	XCharStruct defmetrics;
X
X	XTextExtents (fs, &defc, 1, &dir, &fasc, &fdesc, &defmetrics);
X	if (!NONZERO_CHAR (&defmetrics)) nonzerodefc = False;
X    }
X
X    /*
X     * count the number of actual characters
X     */
X    cs = (fs->per_char ? fs->per_char : &fs->max_bounds);
X    for (byte1 = fs->min_byte1; byte1 <= fs->max_byte1; byte1++) {
X	for (byte2 = fs->min_char_or_byte2; byte2 <= fs->max_char_or_byte2;
X	     byte2++) {
X	    if (NONZERO_CHAR(cs) || nonzerodefc)
X	      nchars++;
X	    if (fs->per_char) cs++;
X	}
X    }
X
X    fprintf (output, "CHARS %u\n", nchars);
X
X    /*
X     * actually emit the characters
X     */
X    cs = (fs->per_char ? fs->per_char : &fs->max_bounds);
X    saven = ((fs->min_byte1 << 8) | fs->min_char_or_byte2);
X    for (byte1 = fs->min_byte1; byte1 <= fs->max_byte1; byte1++) {
X	n = saven;
X	for (byte2 = fs->min_char_or_byte2; byte2 <= fs->max_char_or_byte2;
X	     byte2++) {
X	    if (NONZERO_CHAR(cs) || nonzerodefc)
X	      emit_bitmap (output, dpy, fs, cs, n, boldit);
X	    if (fs->per_char) cs++;
X	    n++;
X	}
X	saven += 256;
X    }
X    emit_bitmap (NULL, dpy, NULL, NULL, 0, False);  /* clean up */
X    return True;
X}
END_OF_FILE
if test 7105 -ne `wc -c <'chars.c'`; then
    echo shar: \"'chars.c'\" unpacked with wrong size!
fi
# end of 'chars.c'
fi
if test -f 'defs.h' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'defs.h'\"
else
echo shar: Extracting \"'defs.h'\" \(2619 characters\)
sed "s/^X//" >'defs.h' <<'END_OF_FILE'
X/*
X * $XConsortium: defs.h,v 1.7 90/05/11 15:14:42 jim Exp $
X *
X * Copyright 1990 Massachusetts Institute of Technology
X *
X * Permission to use, copy, modify, distribute, and sell this software and its
X * documentation for any purpose is hereby granted without fee, provided that
X * the above copyright notice appear in all copies and that both that
X * copyright notice and this permission notice appear in supporting
X * documentation, and that the name of M.I.T. not be used in advertising or
X * publicity pertaining to distribution of the software without specific,
X * written prior permission.  M.I.T. makes no representations about the
X * suitability of this software for any purpose.  It is provided "as is"
X * without express or implied warranty.
X *
X * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
X * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
X * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
X * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
X * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
X *
X * Author:  Jim Fulton, MIT X Consortium
X */
X
X#include <stdio.h>
X#include <X11/Xos.h>
X#include <X11/Xlib.h>
X#include <X11/Xutil.h>
X#include <X11/Xatom.h>
X
Xextern char *ProgramName;
X
Xextern Bool emit_header (
X#if NeedFunctionPrototypes
X    FILE *		/* output */,
X    Display *		/* dpy */,
X    XFontStruct *	/* fs */
X#endif
X);
Xextern Bool emit_properties(
X#if NeedFunctionPrototypes
X    FILE *		/* output */,
X    Display *		/* dpy */,
X    XFontStruct *	/* fs */
X#endif
X);
Xextern Bool emit_characters(
X#if NeedFunctionPrototypes
X    FILE *		/* output */,
X    Display *		/* dpy */,
X    XFontStruct *	/* fs */
X    Bool		/* boldit */
X#endif
X);
Xextern Bool emit_trailer(
X#if NeedFunctionPrototypes
X    FILE *		/* output */,
X    Display *		/* dpy */,
X    XFontStruct *	/* fs */
X#endif
X);
X
Xextern void setup_atoms (
X#if NeedFunctionPrototypes
X    Display *		/* dpy */
X#endif
X);
X
X#define XA_RESOLUTION_X extraatoms[0]
X#define XA_RESOLUTION_Y extraatoms[1]
X#define XA_FONT_ASCENT extraatoms[2]
X#define XA_FONT_DESCENT extraatoms[3]
X#define XA_DEFAULT_CHAR extraatoms[4]
X#define NATOMLIST 5
Xextern Atom extraatoms[NATOMLIST];
X
Xextern long font_point_size, font_yres;
X
X#define PROPTYPE_NONE 0
X#define PROPTYPE_STRING 1
X#define PROPTYPE_INT 2
X#define PROPTYPE_CARD 3
X#define XtRFontPropType "FontPropType"
X
Xextern int find_atom_type (
X#if NeedFunctionPrototypes
X    Atom		/* atom */,
X    char **		/* propname */
X#endif
X);
X
END_OF_FILE
if test 2619 -ne `wc -c <'defs.h'`; then
    echo shar: \"'defs.h'\" unpacked with wrong size!
fi
# end of 'defs.h'
fi
if test -f 'header.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'header.c'\"
else
echo shar: Extracting \"'header.c'\" \(4387 characters\)
sed "s/^X//" >'header.c' <<'END_OF_FILE'
X/*
X * $XConsortium: header.c,v 1.6 90/05/10 15:25:29 jim Exp $
X *
X * Copyright 1990 Massachusetts Institute of Technology
X *
X * Permission to use, copy, modify, distribute, and sell this software and its
X * documentation for any purpose is hereby granted without fee, provided that
X * the above copyright notice appear in all copies and that both that
X * copyright notice and this permission notice appear in supporting
X * documentation, and that the name of M.I.T. not be used in advertising or
X * publicity pertaining to distribution of the software without specific,
X * written prior permission.  M.I.T. makes no representations about the
X * suitability of this software for any purpose.  It is provided "as is"
X * without express or implied warranty.
X *
X * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
X * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
X * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
X * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
X * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
X *
X * Author:  Jim Fulton, MIT X Consortium
X */
X
X#include "defs.h"
X
Xlong font_point_size, font_yres;
X
Xstatic char *warning[] = {
X"COMMENT  ",
X"COMMENT  WARNING:  This bdf file was generated from an X server using",
X"COMMENT  xtobdf.  The resulting font is subject to the same copyright,",
X"COMMENT  license, and trademark restrictions as the original font.  The",
X"COMMENT  authors and distributors of xtobdf disclaim all liability for",
X"COMMENT  misuse of the program or its output.",
X"COMMENT  ",
XNULL
X};
X
Xstatic char *find_string_prop (dpy, fs, atom, present)
X    Display *dpy;
X    register XFontStruct *fs;
X    Atom atom;
X    Bool *present;
X{
X    register XFontProp *p;
X    register int i;
X
X    for (i = 0, p = fs->properties; i < fs->n_properties; i++, p++) {
X	if (p->name == atom) {
X	    if (present) *present = True;
X	    return XGetAtomName (dpy, (Atom) p->card32);
X	}
X    }
X    if (present) *present = False;
X    return NULL;
X}
X
X/* ARGSUSED */
Xstatic unsigned long find_number_prop (dpy, fs, atom, present)
X    Display *dpy;
X    register XFontStruct *fs;
X    Atom atom;
X    Bool *present;
X{
X    register XFontProp *p;
X    register int i;
X
X    for (i = 0, p = fs->properties; i < fs->n_properties; i++, p++) {
X	if (p->name == atom) {
X	    if (present) *present = True;
X	    return p->card32;
X	}
X    }
X    if (present) *present = False;
X    return 0L;
X}
X
X
X/*
X * emit_header - print STARTFONT, COMMENT lines, FONT, SIZE, and 
X * FONTBOUNDINGBOX lines
X */
XBool emit_header (output, dpy, fs)
X    FILE *output;
X    Display *dpy;
X    XFontStruct *fs;
X{
X    char **cpp, *cp;
X    unsigned long ul;
X    long xres;
X    Bool present;
X
X    fprintf (output, "STARTFONT 2.1\n");
X
X    /*
X     * find copyright message and print it first, followed by warning
X     */
X    cp = find_string_prop (dpy, fs, XA_COPYRIGHT, NULL);
X    if (cp) {
X	fprintf (output, "COMMENT  \n");
X	fprintf (output, "COMMENT  %s\n", cp);
X	XFree (cp);
X    }
X    for (cpp = warning; *cpp; cpp++) {
X	fprintf (output, "%s\n", *cpp);
X    }
X
X    /*
X     * FONT name
X     */
X    cp = find_string_prop (dpy, fs, XA_FONT, NULL);
X    if (cp) {
X	fprintf (output, "FONT %s\n", cp);
X	XFree (cp);
X    } else {
X	fprintf (stderr, "%s:  unable to font FONT property\n",
X		 ProgramName);
X	return False;
X    }
X
X    /*
X     * SIZE point xres yres
X     * 
X     * Get XLFD values if possible, else fake it
X     */
X    ul = find_number_prop (dpy, fs, XA_RESOLUTION_X, &present);
X    xres = (present ? (int) ul : 72);
X
X    ul = find_number_prop (dpy, fs, XA_RESOLUTION_Y, &present);
X    font_yres = (present ? (int) ul : 72);
X
X    ul = find_number_prop (dpy, fs, XA_POINT_SIZE, &present);
X    if (present) {
X	font_point_size = (((int) ul) + 5) / 10;
X    } else {
X	font_point_size = ((fs->ascent + fs->descent) * 72) / font_yres;
X    }
X
X    fprintf (output, "SIZE %ld %ld %ld\n", font_point_size, xres, font_yres);
X
X    /*
X     * FONTBOUNDINGBOX width height xoff yoff
X     * 
X     */
X    fprintf (output, "FONTBOUNDINGBOX %d %d %d %d\n",
X	     fs->max_bounds.width,	/* escapement, not right - left... */
X	     fs->max_bounds.ascent + fs->max_bounds.descent,
X	     fs->min_bounds.lbearing, -fs->max_bounds.descent);
X    return True;
X}
END_OF_FILE
if test 4387 -ne `wc -c <'header.c'`; then
    echo shar: \"'header.c'\" unpacked with wrong size!
fi
# end of 'header.c'
fi
if test -f 'props.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'props.c'\"
else
echo shar: Extracting \"'props.c'\" \(5259 characters\)
sed "s/^X//" >'props.c' <<'END_OF_FILE'
X/*
X * $XConsortium: props.c,v 1.8 90/05/10 15:25:31 jim Exp $
X *
X * Copyright 1990 Massachusetts Institute of Technology
X *
X * Permission to use, copy, modify, distribute, and sell this software and its
X * documentation for any purpose is hereby granted without fee, provided that
X * the above copyright notice appear in all copies and that both that
X * copyright notice and this permission notice appear in supporting
X * documentation, and that the name of M.I.T. not be used in advertising or
X * publicity pertaining to distribution of the software without specific,
X * written prior permission.  M.I.T. makes no representations about the
X * suitability of this software for any purpose.  It is provided "as is"
X * without express or implied warranty.
X *
X * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
X * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
X * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
X * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
X * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
X *
X * Author:  Jim Fulton, MIT X Consortium
X */
X
X#include "defs.h"
X#include <X11/Xmd.h>
X
Xtypedef struct {
X    char *propname;			/* name of property */
X    Atom atom;				/* atom value for property name */
X    int type;				/* PROPTYPE_ */
X    union {				/* value */
X	char *string;
X	unsigned long cardinal;
X	long integer;
X    } u;
X} Propdata;
X
XAtom extraatoms[NATOMLIST];		/* for fake XA_ atoms */
X
Xextern char *calloc();
X
Xvoid setup_atoms (dpy)
X    Display *dpy;
X{
X    XA_RESOLUTION_X = XInternAtom (dpy, "RESOLUTION_X", False);
X    XA_RESOLUTION_Y = XInternAtom (dpy, "RESOLUTION_Y", False);
X    XA_FONT_ASCENT = XInternAtom (dpy, "FONT_ASCENT", False);
X    XA_FONT_DESCENT = XInternAtom (dpy, "FONT_DESCENT", False);
X    XA_DEFAULT_CHAR = XInternAtom (dpy, "DEFAULT_CHAR", False);
X}
X
X
XBool emit_properties (output, dpy, fs)
X    FILE *output;
X    Display *dpy;
X    XFontStruct *fs;
X{
X    XFontProp *fp;			/* iterator over font props */
X    Propdata *pd, *cur;			/* tmp prop data array pointers */
X    int npd;				/* number of valid props */
X    int i;				/* iterator tmp variable */
X    char *cp;				/* string tmp variable */
X    int needdefchar = 1, needfontasc = 1, needfontdesc = 1;
X
X    if (fs->n_properties < 1) {
X	fprintf (output, "STARTPROPERTIES 0\nENDPROPERTIES\n");
X	return True;
X    }
X
X    pd = (Propdata *) calloc (fs->n_properties, sizeof(Propdata));
X    if (!pd) {
X	fprintf (stderr, "%s:  unable to allocate space for %d propdatas\n",
X		 ProgramName, fs->n_properties);
X	fprintf (output, "STARTPROPERTIES 0\nENDPROPERTIES\n");
X	return False;
X    }
X    cur = pd;
X
X    /*
X     * Lookup property type in resource database (also returns name).  Build
X     * up a list of valid properties to emit so that we don't accidentally
X     * output bogus values for unrecognized properties.
X     */
X    for (i = 0, fp = fs->properties; i < fs->n_properties; i++, fp++) {
X	char *propname;
X	int type;
X
X	if ((type = find_atom_type (fp->name, &propname)) == PROPTYPE_NONE) {
X	    fprintf (stderr, "%s:  unknown type for atom ", ProgramName);
X	    if (propname) {
X		fprintf (stderr, "\"%s\"\n", propname);
X		XFree (propname);
X	    } else {
X		fprintf (stderr, "0x%lx (%ld)\n", fp->name, fp->name);
X	    }
X	    continue;
X	}
X
X	cur->propname = propname;
X	cur->atom = fp->name;
X	cur->type = type;
X	if (cur->atom == XA_DEFAULT_CHAR) needdefchar = 0;
X	if (cur->atom == XA_FONT_ASCENT) needfontasc = 0;
X	if (cur->atom == XA_FONT_DESCENT) needfontdesc = 0;
X	switch (cur->type) {
X	  case PROPTYPE_STRING:		/* string stored as atom */
X	    cp = XGetAtomName (dpy, (Atom) fp->card32);
X	    if (!cp) {
X		fprintf (stderr, "%s:  no string value for %s property\n",
X			 ProgramName, cur->propname);
X		XFree (propname);
X		continue;
X	    }
X	    cur->u.string = cp;
X	    break;
X
X	  case PROPTYPE_CARD:	/* just use */
X	    cur->u.cardinal = (unsigned long) fp->card32;
X	    break;
X
X	  case PROPTYPE_INT:	/* need to sign-extend */
X	    cur->u.integer = cvtINT32toLong(fp->card32);
X	    break;
X	}
X	cur++;
X    }
X					       
X    /*
X     * print the suckers, free the data, and return
X     */
X    npd = (cur - pd);
X    fprintf (output, "STARTPROPERTIES %d\n",
X	     npd + needdefchar + needfontasc + needfontdesc);
X    for (i = 0, cur = pd; i < npd; i++, cur++) {
X	fprintf (output, "%s ", cur->propname);
X	XFree (cur->propname);
X	switch (cur->type) {
X	  case PROPTYPE_STRING:
X	    putc ('"', output);
X	    for (cp = cur->u.string; *cp; cp++) {
X		if (*cp == '"') putc ('"', output);
X		putc (*cp, output);
X	    }
X	    putc ('"', output);
X	    XFree (cur->u.string);
X	    break;
X
X	  case PROPTYPE_CARD:
X	    fprintf (output, "%lu", cur->u.cardinal);
X	    break;
X
X	  case PROPTYPE_INT:
X	    fprintf (output, "%ld", cur->u.integer);
X	    break;
X	}
X	putc ('\n', output);
X    }
X    if (needdefchar) fprintf (output, "DEFAULT_CHAR %u\n", fs->default_char);
X    if (needfontasc) fprintf (output, "FONT_ASCENT %d\n", fs->ascent);
X    if (needfontdesc) fprintf (output, "FONT_DESCENT %d\n", fs->descent);
X    fprintf (output, "ENDPROPERTIES\n");
X    free ((char *) pd);
X    return True;
X}
X
END_OF_FILE
if test 5259 -ne `wc -c <'props.c'`; then
    echo shar: \"'props.c'\" unpacked with wrong size!
fi
# end of 'props.c'
fi
if test -f 'trailer.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'trailer.c'\"
else
echo shar: Extracting \"'trailer.c'\" \(1443 characters\)
sed "s/^X//" >'trailer.c' <<'END_OF_FILE'
X/*
X * $XConsortium: trailer.c,v 1.1 90/05/08 20:13:12 jim Exp $
X *
X * Copyright 1990 Massachusetts Institute of Technology
X *
X * Permission to use, copy, modify, distribute, and sell this software and its
X * documentation for any purpose is hereby granted without fee, provided that
X * the above copyright notice appear in all copies and that both that
X * copyright notice and this permission notice appear in supporting
X * documentation, and that the name of M.I.T. not be used in advertising or
X * publicity pertaining to distribution of the software without specific,
X * written prior permission.  M.I.T. makes no representations about the
X * suitability of this software for any purpose.  It is provided "as is"
X * without express or implied warranty.
X *
X * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
X * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
X * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
X * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
X * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
X *
X * Author:  Jim Fulton, MIT X Consortium
X */
X
X#include "defs.h"
X
X/* ARGSUSED */
XBool emit_trailer (output, dpy, fs)
X    FILE *output;
X    Display *dpy;
X    XFontStruct *fs;
X{
X    fprintf (output, "ENDFONT\n");
X    return True;
X}
END_OF_FILE
if test 1443 -ne `wc -c <'trailer.c'`; then
    echo shar: \"'trailer.c'\" unpacked with wrong size!
fi
# end of 'trailer.c'
fi
if test -f 'xtobdf.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'xtobdf.c'\"
else
echo shar: Extracting \"'xtobdf.c'\" \(7543 characters\)
sed "s/^X//" >'xtobdf.c' <<'END_OF_FILE'
X/*
X * $XConsortium: xtobdf.c,v 1.9 90/05/11 15:32:22 jim Exp $
X *
X * Copyright 1990 Massachusetts Institute of Technology
X *
X * Permission to use, copy, modify, distribute, and sell this software and its
X * documentation for any purpose is hereby granted without fee, provided that
X * the above copyright notice appear in all copies and that both that
X * copyright notice and this permission notice appear in supporting
X * documentation, and that the name of M.I.T. not be used in advertising or
X * publicity pertaining to distribution of the software without specific,
X * written prior permission.  M.I.T. makes no representations about the
X * suitability of this software for any purpose.  It is provided "as is"
X * without express or implied warranty.
X *
X * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
X * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
X * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
X * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
X * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
X *
X * Author:  Jim Fulton, MIT X Consortium
X */
X
X#include <X11/Intrinsic.h>
X#include <X11/StringDefs.h>
X#include <X11/Xaw/Cardinals.h>
X#include <X11/Xmu/Converters.h>
X#include "defs.h"
X
Xchar *ProgramName;
X
Xstatic Widget toplevel;
X
Xstatic char *fallbacks[] = {
X    "*Prop.ADD_STYLE_NAME:	string",
X    "*Prop.AUTHOR:		string",
X    "*Prop.AVERAGE_WIDTH:	card",
X    "*Prop.AVG_CAPITAL_WIDTH:	int",
X    "*Prop.AVG_LOWERCASE_WIDTH:	int",
X    "*Prop.CAP_HEIGHT:		card",
X    "*Prop.CHARSET_COLLECTIONS:	string",
X    "*Prop.CHARSET_ENCODING:	string",
X    "*Prop.CHARSET_REGISTRY:	string",
X    "*Prop.COPYRIGHT:		string",
X    "*Prop.DATE:		string",
X    "*Prop.DEFAULT_CHAR:	card",
X    "*Prop.DEVICE_FONT_NAME:	string",
X    "*Prop.DESTINATION:		card",
X    "*Prop.END_SPACE:		card",
X    "*Prop.FACE_NAME:		string",
X    "*Prop.FAMILY_NAME:		string",
X    "*Prop.FIGURE_WIDTH:	int",
X    "*Prop.FONT:		string",
X    "*Prop.FONTNAME_REGISTRY:	string",
X    "*Prop.FONT_ASCENT:		int",
X    "*Prop.FONT_DESCENT:	int",
X    "*Prop.FOUNDRY:		string",
X    "*Prop.FULL_NAME:		string",
X    "*Prop.ITALIC_ANGLE:	int",
X    "*Prop.MAX_SPACE:		card",
X    "*Prop.MIN_SPACE:		card",
X    "*Prop.NAME:		string",
X    "*Prop.NORM_SPACE:		card",
X    "*Prop.NOTICE:		string",
X    "*Prop.PIXEL_SIZE:		card",
X    "*Prop.POINT_SIZE:		card",
X    "*Prop.QUAD_WIDTH:		int",
X    "*Prop.RELATIVE_SETWIDTH:	card",
X    "*Prop.RELATIVE_WEIGHT:	card",
X    "*Prop.RESOLUTION:		card",
X    "*Prop.RESOLUTION_X:	card",
X    "*Prop.RESOLUTION_Y:	card",
X    "*Prop.SETWIDTH_NAME:	string",
X    "*Prop.SLANT:		string",
X    "*Prop.SMALL_CAP_SIZE:	card",
X    "*Prop.SPACING:		string",
X    "*Prop.STRIKEOUT_ASCENT:	int",
X    "*Prop.STRIKEOUT_DESCENT:	int",
X    "*Prop.SUBSCRIPT_SIZE:	card",
X    "*Prop.SUBSCRIPT_X:		int",
X    "*Prop.SUBSCRIPT_Y:		int",
X    "*Prop.SUPERSCRIPT_SIZE:	card",
X    "*Prop.SUPERSCRIPT_X:	int",
X    "*Prop.SUPERSCRIPT_Y:	int",
X    "*Prop.UNDERLINE_POSITION:	int",
X    "*Prop.UNDERLINE_THICKNESS:	card",
X    "*Prop.WEIGHT:		card",
X    "*Prop.WEIGHT_NAME:		string",
X    "*Prop.X_HEIGHT:		card",
X    NULL,
X};
X
X#define done(address, type) \
X        { (*toVal).size = sizeof(type); (*toVal).addr = (caddr_t) address; }
X
Xstatic struct _namepair {
X    XrmQuark quark;
X    char *name;
X    int proptype;
X} names[] = {
X    { NULLQUARK, "string", PROPTYPE_STRING },
X    { NULLQUARK, "s", PROPTYPE_STRING },
X    { NULLQUARK, "atom", PROPTYPE_STRING },
X    { NULLQUARK, "int", PROPTYPE_INT },
X    { NULLQUARK, "integer", PROPTYPE_INT },
X    { NULLQUARK, "int32", PROPTYPE_INT },
X    { NULLQUARK, "card", PROPTYPE_CARD },
X    { NULLQUARK, "cardinal", PROPTYPE_CARD },
X    { NULLQUARK, "card32", PROPTYPE_CARD },
X    { NULLQUARK, NULL, 0 }
X};
X
X/*****************************************************************************
X * 
X * internal routines
X * 
X *****************************************************************************/
X
X/* ARGSUSED */
Xstatic void cvt_string_proptype (args, num_args, fromVal, toVal)
X    XrmValuePtr args;
X    Cardinal    *num_args;
X    XrmValuePtr fromVal;
X    XrmValuePtr toVal;
X{
X    static Boolean haveQuarks = FALSE;
X    char lowerName[40];
X    XrmQuark q;
X    char *s;
X    struct _namepair *np;
X
X    if (*num_args != 0)
X        XtWarningMsg("wrongParameters","cvt_data_format","XtToolkitError",
X                  "String to DataFormat conversion needs no extra arguments",
X                  (String *) NULL, (Cardinal *)NULL);
X
X    if (!haveQuarks) {
X	for (np = names; np->name; np++) {
X	    np->quark = XrmStringToQuark (np->name);
X	}
X	haveQuarks = TRUE;
X    }
X
X    s = (char *) fromVal->addr;
X    if (strlen(s) < sizeof lowerName) {
X	XmuCopyISOLatin1Lowered (lowerName, s);
X	q = XrmStringToQuark (lowerName);
X
X	for (np = names; np->name; np++) {
X	    if (np->quark == q) {
X		done (&np->proptype, int);
X		return;
X	    }
X	}
X    }
X    XtStringConversionWarning((char *) fromVal->addr, XtRFontPropType);
X#undef done
X}
X
X
Xstatic void usage ()
X{
X    fprintf (stderr, "usage:  %s -fn font [-display dpy] [-bold]\n",
X	     ProgramName);
X    exit (1);
X}
X
X/*****************************************************************************
X * 
X * external routines
X * 
X *****************************************************************************/
X 
Xmain (argc, argv)
X    int argc;
X    char **argv;
X{
X    Display *dpy;
X    XtAppContext app_con;
X    struct _appdata {
X	XFontStruct *fs;
X    } appdata;
X    static XtResource resources[] = {
X#define offset(field) XtOffset(struct _appdata *, field)
X	{ XtNfont, XtCFont, XtRFontStruct, sizeof(XFontStruct *),
X	    offset(fs), XtRImmediate, (XtPointer) NULL },
X#undef offset
X    };
X    Bool boldit = False;
X
X    ProgramName = argv[0];
X
X    toplevel = XtAppInitialize (&app_con, "XTobdf", (XrmOptionDescRec *) NULL,
X				ZERO, (Cardinal *) &argc, argv, fallbacks,
X				(ArgList) NULL, ZERO);
X
X    if (argc > 1) {
X	if (strcmp (argv[1], "-bold") == 0 && argc == 2)
X	    boldit = True;
X	else
X	    usage();
X    }
X
X    XtAddConverter (XtRString, XtRFontPropType, cvt_string_proptype,
X		    (XtConvertArgList) NULL, ZERO);
X/*    XmuSetStringToFontStructConverter (FALSE);  */
X
X    dpy = XtDisplay(toplevel);
X    XtGetApplicationResources (toplevel, (XtPointer) &appdata,
X			       resources, XtNumber(resources), NULL, ZERO);
X    if (!appdata.fs) exit (1);
X
X    setup_atoms (dpy);
X
X    /*
X     * emit the font
X     */
X    if (!emit_header (stdout, dpy, appdata.fs)) goto abort;
X    if (!emit_properties (stdout, dpy, appdata.fs)) goto abort;
X    if (!emit_characters (stdout, dpy, appdata.fs, boldit)) goto abort;
X    if (!emit_trailer (stdout, dpy, appdata.fs)) {
X      abort:
X	fprintf (stderr, "%s:  unable to dump font\n", ProgramName);
X    }
X
X    exit (0);
X}
X
Xint find_atom_type (atom, propname)
X    Atom atom;
X    char **propname;
X{
X    struct _propdata {
X	int type;
X    } data;
X
X    data.type = PROPTYPE_NONE;
X    if (*propname = XGetAtomName (XtDisplay(toplevel), atom)) {
X	XtResource res;			/* must build dynamically */
X	res.resource_name = res.resource_class = *propname;
X	res.resource_type = XtRFontPropType;
X	res.resource_size = sizeof(int),
X	res.resource_offset = XtOffset(struct _propdata *, type);
X	res.default_type = XtRImmediate;
X	res.default_addr = (XtPointer) PROPTYPE_NONE;
X	XtGetSubresources (toplevel, (XtPointer) &data, "prop",
X			   "Prop", &res, ONE, (ArgList) NULL, ZERO);
X    }
X    return data.type;
X}
X
END_OF_FILE
if test 7543 -ne `wc -c <'xtobdf.c'`; then
    echo shar: \"'xtobdf.c'\" unpacked with wrong size!
fi
# end of 'xtobdf.c'
fi
if test -f 'xtobdf.man' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'xtobdf.man'\"
else
echo shar: Extracting \"'xtobdf.man'\" \(3391 characters\)
sed "s/^X//" >'xtobdf.man' <<'END_OF_FILE'
X.TH XTOBDF 1 "Release 5" "X Version 11"
X.SH NAME
Xxtobdf - X font BDF generator
X.SH SYNOPSIS
X.B "xtobdf"
X-fn \fIfontname\fP [-option ...]
X.SH DESCRIPTION
XThe \fIxtobdf\fP program reads a font from an X display and prints a BDF
Xfile on the standard output that may be used to recreate the font.
XThis is useful in testing servers, debugging font metrics, and reproducing 
Xlost BDF files.
X.PP
XFont properties types (i.e. \fBstring\fP, \fBint\fP, or \fBcard\fP) are
Xstored as resources, allowing arbitrary properties to be properly interpretted.
X.SH OPTIONS
XThis program accepts all of the standard X Toolkit command line options,
Xalthough on the following are useful:
X.TP 8
X.B \-display \fIdisplayname\fP
XThis option specifies the display from which the font should be read.
X.TP 8
X.B \-fn \fIfontname\fP
XThis option specifies the font for which a BDF file should be generated.
X.TP 8
X.B \-xrm ``*Prop.\fIPROPERTY_NAME\fP: \fItype\fP''
XOptions of this form may be used to specify the types of font properties as
Xdescribed in the following section.
X.SH "FONT PROPERTY TYPES"
XX does not provide type information about font properties, requiring
Xapplications to have \fIa priori\fP knowledge of how the properties are
Xencoded.  \fIXtobdf\fP uses the resource database to store property types:
X.TP 8
X.B string
XThis type is for quoted strings (e.g. COPYRIGHT).
X.TP 8
X.B int
XThis type is for signed, 32 bit numbers (e.g. FONT_ASCENT).
X.TP 8
X.B card
XThis type is for unsigned, 32 bit numbers (e.g. RESOLUTION_X).
X.PP
XProperty types are stored according to their property name as subresources of 
Xthe object named \fIprop\fP (class \fIProp\fP).  The following properties are
Xprovided by default:
X.sp
X.nf
X.ta 1i 4i
X	*Prop.ADD_STYLE_NAME:	string
X	*Prop.AUTHOR:	string
X	*Prop.AVERAGE_WIDTH:	card
X	*Prop.AVG_CAPITAL_WIDTH:	int
X	*Prop.AVG_LOWERCASE_WIDTH:	int
X	*Prop.CAP_HEIGHT:	card
X	*Prop.CHARSET_COLLECTIONS:	string
X	*Prop.CHARSET_ENCODING:	string
X	*Prop.CHARSET_REGISTRY:	string
X	*Prop.COPYRIGHT:	string
X	*Prop.DATE:	string
X	*Prop.DEFAULT_CHAR:	card
X	*Prop.DESTINATION:	card
X	*Prop.DEVICE_FONT_NAME:	string
X	*Prop.END_SPACE:	card
X	*Prop.FACE_NAME:	string
X	*Prop.FAMILY_NAME:	string
X	*Prop.FIGURE_WIDTH:	int
X	*Prop.FONT:	string
X	*Prop.FONTNAME_REGISTRY:	string
X	*Prop.FONT_ASCENT:	int
X	*Prop.FONT_DESCENT:	int
X	*Prop.FOUNDRY:	string
X	*Prop.FULL_NAME:	string
X	*Prop.ITALIC_ANGLE:	int
X	*Prop.MAX_SPACE:	card
X	*Prop.MIN_SPACE:	card
X	*Prop.NAME:	string
X	*Prop.NORM_SPACE:	card
X	*Prop.NOTICE:	string
X	*Prop.PIXEL_SIZE:	card
X	*Prop.POINT_SIZE:	card
X	*Prop.QUAD_WIDTH:	int
X	*Prop.RELATIVE_SETWIDTH:	card
X	*Prop.RELATIVE_WEIGHT:	card
X	*Prop.RESOLUTION:	card
X	*Prop.RESOLUTION_X:	card
X	*Prop.RESOLUTION_Y:	card
X	*Prop.SETWIDTH_NAME:	string
X	*Prop.SLANT:	string
X	*Prop.SMALL_CAP_SIZE:	card
X	*Prop.SPACING:	string
X	*Prop.STRIKEOUT_ASCENT:	int
X	*Prop.STRIKEOUT_DESCENT:	int
X	*Prop.SUBSCRIPT_SIZE:	card
X	*Prop.SUBSCRIPT_X:	int
X	*Prop.SUBSCRIPT_Y:	int
X	*Prop.SUPERSCRIPT_SIZE:	card
X	*Prop.SUPERSCRIPT_X:	int
X	*Prop.SUPERSCRIPT_Y:	int
X	*Prop.UNDERLINE_POSITION:	int
X	*Prop.UNDERLINE_THICKNESS:	card
X	*Prop.WEIGHT:	card
X	*Prop.WEIGHT_NAME:	string
X	*Prop.X_HEIGHT:	card
X.fi
X.SH "SEE ALSO"
XX(1), bdftosnf(1), xlsfonts(1), xfd(1), mkfontdir(1)
X.SH COPYRIGHT
XCopyright 1990, Massachusetts Institute of Technology.
X.br
XSee \fIX(1)\fP for a full statement of rights and permissions.
X.SH AUTHOR
XJim Fulton, MIT X Consortium
X
X
X
X
X
X
END_OF_FILE
if test 3391 -ne `wc -c <'xtobdf.man'`; then
    echo shar: \"'xtobdf.man'\" unpacked with wrong size!
fi
# end of 'xtobdf.man'
fi
echo shar: End of shell archive.
exit 0
