home *** CD-ROM | disk | FTP | other *** search
/ Microsoft Programmer's Library 1.3 / Microsoft-Programers-Library-v1.3.iso / sampcode / prof_c / include / local / printer.h < prev    next >
Encoding:
C/C++ Source or Header  |  1988-08-11  |  1.5 KB  |  48 lines

  1. /*
  2.  *    printer.h -- header for printer control functions
  3.  */
  4.  
  5.  
  6. /* ASCII codes used for Epson MX/FX-series printer control */
  7. #define DC2    18    /* cancel condensed type mode */
  8. #define DC4    20    /* cancel expanded type mode */
  9. #define ESC    27    /* signal start of printer control sequences */
  10. #define FF    12    /* top of page next page */
  11. #define SO    14    /* start expanded type mode */
  12. #define SI    15    /* start condensed type mode */
  13.  
  14. /* font types */
  15. #define NORMAL        0x00
  16. #define CONDENSED    0x01
  17. #define DOUBLE        0x02
  18. #define    EMPHASIZED    0x04
  19. #define EXPANDED    0x08
  20. #define ITALICS        0x10
  21. #define UNDERLINE    0x20
  22.  
  23. /* miscellaneous constants */
  24. #define MAXPSTR    32    /* maximum printer control string length */
  25.  
  26. /* primary printer control data structure */
  27. typedef struct printer_st {
  28.     /* hardware initialize/reset */
  29.     char p_init[MAXPSTR];    
  30.  
  31.     /* set option strings and codes */
  32.     char p_bold[MAXPSTR];    /* bold (emphasized) on */
  33.     char p_cmp[MAXPSTR];    /* compressed on */
  34.     char p_ds[MAXPSTR];    /* double strike on */
  35.     char p_exp[MAXPSTR];    /* expanded (double width) on */
  36.     char p_ul[MAXPSTR];    /* underline on */
  37.     char p_ital[MAXPSTR];    /* italic on */
  38.  
  39.     /* reset option strings and codes */
  40.     char p_norm[MAXPSTR];    /* restore normal font */
  41.     char p_xbold[MAXPSTR];    /* bold (emphasized) off */
  42.     char p_xcmp[MAXPSTR];    /* compressed off */
  43.     char p_xds[MAXPSTR];    /* double strike off */
  44.     char p_xexp[MAXPSTR];    /* expanded (double width) off */
  45.     char p_xul[MAXPSTR];    /* underline off */
  46.     char p_xital[MAXPSTR];    /* italic off */
  47. } PRINTER;
  48.