home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Usenet 1994 January
/
usenetsourcesnewsgroupsinfomagicjanuary1994.iso
/
sources
/
misc
/
volume26
/
hp2pbm
/
part02
/
hptopbm.h
< prev
next >
Wrap
C/C++ Source or Header
|
1991-12-11
|
3KB
|
145 lines
/*
Copyright 1989, 1990, 1991 Chris Lewis
All Rights Reserved
Permission to copy and further distribute is freely given provided
this copyright notice remains intact, that this software is not
sold for profit, that credit is given, and that sources will be made
available on request.
This software is a subset of Psroff 3.0. See the LICENSE file
in Psroff 3.0 for more details, or contact:
Chris Lewis
Box 124
Dunrobin, Ontario
Canada K0A 1T0
(613) 832-0541
Function: Header file for hp2pbm. 1.1 91/12/03 00:34:41
*/
#define VERSION "hp2pbm V1.00"
#include <stdio.h>
#include <ctype.h>
#ifndef LIBDIR
#define LIBDIR ".."
#endif
#ifdef FAXPAK
#include "faxpak.h"
#endif
#ifdef BSD
#include <strings.h>
#define strchr index
#define strrchr rindex
#else
#include <string.h>
#endif
#include <varargs.h>
/* CONFIG: These aren't really used if hp2*'s sole purpose is a filter */
#define BINFILE "FONTS/f%d"
#define DESCFILE "FONTS/f%d.desc"
#ifndef FAXPAK
#define BUILTINDIR "%s/BITMAPS/%s"
#endif
#define TOP_MARGIN 3 /* half inch, 300/6lpi = 3 lines */
#define LEFT_MARGIN 0 /* char column pos, not dots */
/* CONFIG: if !A4, define your default paper size (A4/LETTER are best for fax) */
#if (!A4) && (!LETTER) && (!LEGAL) && (!B5)
#define A4 1
#endif
#if LETTER
#define PAGE_LEN 66
#define RITE_MARGIN 80
#endif
#if A4
#define PAGE_LEN 70
#define RITE_MARGIN 77
#endif
#if LEGAL
#define PAGE_LEN 84
#define RITE_MARGIN 80
#endif
#if B5
#define PAGE_LEN 60
#define RITE_MARGIN 66
#endif
#define PRIMARY 1
#define SECONDARY 2
#define PERMANENT 3
#define TEMPORARY 4
#define MAX_PUSHNPOP 256 /* I haven't got a clue what the hp limit is */
#define SAVE 1
#define RESTORE 2
#define MAX_BUILTIN 8
#define MAX_DOWNLOAD 32
#define LINEPRINTER 0
#define notyet1 1
#define notyet2 2
#define COURIER 3
#define notyet4 4
#define notyet5 5
#define notyet6 6
#define notyet7 7
#define uchar unsigned char
struct fontdesc
{
short f1;
uchar f2;
uchar fd_type;
short f3;
short fd_base;
short fd_cellwidth;
short fd_cellheight;
uchar fd_orientation;
uchar fd_fixedprop;
short fd_symset;
short fd_pitch;
short fd_height;
short f4;
uchar f5;
uchar fd_style;
uchar fd_weight;
uchar fd_typeface;
};
struct download {
uchar f1;
uchar f2;
uchar f3;
uchar f4;
uchar dl_orientation;
uchar f5;
short dl_leftoffset;
short dl_topoffset;
short dl_charwidth;
short dl_charheight;
short dl_deltax;
};
#ifndef FALSE
#define FALSE 0
#endif
#ifndef TRUE
#define TRUE 1
#endif