home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 377b.lha / devices / printer / epsonq / data.c next >
Encoding:
Text File  |  1980-02-03  |  7.3 KB  |  231 lines

  1. /* Copyright (c) 1990 Commodore-Amiga, Inc.
  2.  *
  3.  * This example is provided in electronic form by Commodore-Amiga, Inc. for
  4.  * use with the 1.3 revisions of the Addison-Wesley Amiga reference manuals. 
  5.  * The 1.3 Addison-Wesley Amiga Reference Manual series contains additional
  6.  * information on the correct usage of the techniques and operating system
  7.  * functions presented in this example.  The source and executable code of
  8.  * this example may only be distributed in free electronic form, via bulletin
  9.  * board or as part of a fully non-commercial and freely redistributable
  10.  * diskette.  Both the source and executable code (including comments) must
  11.  * be included, without modification, in any copy.  This example may not be
  12.  * published in printed form or distributed with any commercial product.
  13.  * However, the programming techniques and support routines set forth in
  14.  * this example may be used in the development of original executable
  15.  * software products for Commodore Amiga computers.
  16.  * All other rights reserved.
  17.  * This example is provided "as-is" and is subject to change; no warranties
  18.  * are made.  All use is at your own risk.  No liability or responsibility
  19.  * is assumed.
  20.  */
  21.  
  22. char *CommandTable[] ={
  23.     "\375\033@\375",/* 00 aRIS reset            */
  24.     "\377",        /* 01 aRIN initialize            */
  25.     "\377",        /* 02 aIND linefeed            */
  26.     "\012\015",    /* 03 aNEL CRLF                */
  27.     "\377",        /* 04 aRI reverse LF            */
  28.  
  29.             /* 05 aSGR0 normal char set        */
  30.     "\0335\033-\376\033F",
  31.     "\0334",    /* 06 aSGR3 italics on            */
  32.     "\0335",    /* 07 aSGR23 italics off        */
  33.     "\033-\001",    /* 08 aSGR4 underline on        */
  34.     "\033-\376",    /* 09 aSGR24 underline off        */
  35.     "\033E",    /* 10 aSGR1 boldface on            */
  36.     "\033F",    /* 11 aSGR22 boldface off        */
  37.     "\377",        /* 12 aSFC set foreground color        */
  38.     "\377",        /* 13 aSBC set background color        */
  39.  
  40.             /* 14 aSHORP0 normal pitch        */
  41.     "\033P\022\033W\376",
  42.             /* 15 aSHORP2 elite on            */
  43.     "\033M\022\033W\376",
  44.     "\033P",    /* 16 aSHORP1 elite off            */
  45.             /* 17 aSHORP4 condensed fine on        */
  46.     "\017\033P\033W\376",
  47.     "\022",        /* 18 aSHORP3 condensed fine off    */
  48.     "\033W\001",    /* 19 aSHORP6 enlarge on        */
  49.     "\033W\376",    /* 20 aSHORP5 enlarge off        */
  50.  
  51.     "\377",        /* 21 aDEN6 shadow print on        */
  52.     "\377",        /* 22 aDEN5 shadow print off        */
  53.     "\033G",    /* 23 aDEN4 double strike on        */
  54.     "\033H",    /* 24 aDEN3 double strike off        */
  55.     "\033x\001",    /* 25 aDEN2 NLQ on            */
  56.     "\033x\376",    /* 26 aDEN1 NLQ off            */
  57.  
  58.     "\033S\376",    /* 27 aSUS2 superscript on        */
  59.     "\033T",    /* 28 aSUS1 superscript off        */
  60.     "\033S\001",    /* 29 aSUS4 subscript on        */
  61.     "\033T",    /* 30 aSUS3 subscript off        */
  62.     "\033T",    /* 31 aSUS0 normalize the line        */
  63.     "\377",        /* 32 aPLU partial line up        */
  64.     "\377",        /* 33 aPLD partial line down    */
  65.  
  66.     "\033R\376",    /* 34 aFNT0 Typeface 0            */
  67.     "\033R\001",    /* 35 aFNT1 Typeface 1            */
  68.     "\033R\002",    /* 36 aFNT2 Typeface 2            */
  69.     "\033R\003",    /* 37 aFNT3 Typeface 3            */
  70.     "\033R\004",    /* 38 aFNT4 Typeface 4            */
  71.     "\033R\005",    /* 39 aFNT5 Typeface 5            */
  72.     "\033R\006",    /* 40 aFNT6 Typeface 6            */
  73.     "\033R\007",    /* 41 aFNT7 Typeface 7            */
  74.     "\033R\010",    /* 42 aFNT8 Typeface 8            */
  75.     "\033R\011",    /* 43 aFNT9 Typeface 9            */
  76.     "\033R\012",    /* 44 aFNT10 Typeface 10        */
  77.  
  78.     "\033p1",    /* 45 aPROP2 proportional on        */
  79.     "\033p0",    /* 46 aPROP1 proportional off        */
  80.     "\377",        /* 47 aPROP0 proportional clear        */
  81.     "\377",        /* 48 aTSS set proportional offset    */
  82.             /* 49 aJFY5 auto left justify        */
  83.     "\033x\001\033a\376",
  84.             /* 50 aJFY7 auto right justify        */
  85.     "\033x\001\033a\002",
  86.             /* 51 aJFY6 auto full jusitfy        */
  87.     "\033x\001\033a\003",
  88.     "\033a\376",    /* 52 aJFY0 auto jusity off        */
  89.     "\377",        /* 53 aJFY3 letter space        */
  90.             /* 54 aJFY1 word fill            */
  91.     "\033x\001\033a\001",
  92.  
  93.     "\0330",    /* 55 aVERP0 1/8" line spacing        */
  94.     "\0332",    /* 56 aVERP1 1/6" line spacing        */
  95.     "\377",        /* 57 aSLPP set form length        */
  96.     "\377",        /* 58 aPERF perf skip n (n > 0)        */
  97.     "\033O",    /* 59 aPERF0 perf skip off        */
  98.  
  99.     "\377",        /* 60 aLMS set left margin        */
  100.     "\377",        /* 61 aRMS set right margin        */
  101.     "\377",        /* 62 aTMS set top margin        */
  102.     "\377",        /* 63 aBMS set bottom margin        */
  103.     "\377",        /* 64 aSTBM set T&B margins        */
  104.     "\377",        /* 65 aSLRM set L&R margins        */
  105.     "\377",        /* 66 aCAM clear margins        */
  106.  
  107.     "\377",        /* 67 aHTS set horiz tab        */
  108.     "\377",        /* 68 aVTS set vert tab            */
  109.     "\377",        /* 69 aTBC0 clear horiz tab        */
  110.     "\033D\376",    /* 70 aTBC3 clear all horiz tabs    */
  111.     "\377",        /* 71 aTBC1 clear vert tab        */
  112.     "\377",        /* 72 aTBC4 clear all vert tabs        */
  113.     "\033D\376",    /* 73 aTBCALL clear all h & v tabs    */
  114.             /* 74 aTBSALL set default tabs        */
  115. "\033D\010\020\030\040\050\060\070\100\110\120\130\140\150\160\170\200\376",
  116.  
  117.     "\377",        /* 75 aEXTEND extended commands        */
  118.     "\377",        /* 76 aRAW next 'n' chars are raw    */
  119. };
  120.  
  121. char *ExtendedCharTable[] = {
  122.     " ",                    /* NBSP*/
  123.     "\033R\007[\033R\\0",            /* i */
  124.     "c\010|",                /* c| */
  125.     "\033R\003#\033R\\0",            /* L- */
  126.     "\033R\005$\033R\\0",            /* o */
  127.     "\033R\010\\\\\033R\\0",        /* Y- */
  128.     "|",                    /* | */
  129.     "\033R\002@\033R\\0",            /* SS */
  130.  
  131.     "\033R\001~\033R\\0",            /* " */
  132.     "c",                     /* copyright */
  133.     "\033S\\0a\010_\033T",            /* a_ */
  134.     "<",                    /* << */
  135.     "~",                    /* - */
  136.     "-",                    /* SHY */
  137.     "r",                    /* registered trademark */
  138.     "-",                    /* - */
  139.  
  140.     "\033R\001[\033R\\0",            /* degrees */
  141.     "+\010_",                /* +_ */
  142.     "\033S\\0002\033T",            /* 2 */
  143.     "\033S\\0003\033T",            /* 3 */
  144.     "'",                    /* ' */
  145.     "u",                    /* u */
  146.     "P",                    /* reverse P */
  147.     "\033S\\000.\033T",            /* . */
  148.  
  149.     ",",                    /* , */
  150.     "\033S\\0001\033T",            /* 1 */
  151.     "\033R\001[\033R\\0\010-",        /* o_ */
  152.     ">",                    /* >> */
  153.     "\033S\\0001\033T\010-\010\033S\0014\033T",    /* 1/4 */
  154.     "\033S\\0001\033T\010-\010\033S\0012\033T",    /* 1/2 */
  155.     "\033S\\0003\033T\010-\010\033S\0014\033T",    /* 3/4 */
  156.     "\033R\007]\033R\\0",            /* upside down ? */
  157.  
  158.     "A\010`",                /* `A */
  159.     "A\010'",                /* 'A */
  160.     "A\010^",                /* ^A */
  161.     "A\010~",                /* ~A */
  162.     "\033R\002[\033R\\0",            /* "A */
  163.     "\033R\004]\033R\\0",            /* oA */
  164.     "\033R\004[\033R\\0",            /* AE */
  165.     "C\010,",                /* C, */
  166.  
  167.     "E\010`",                /* `E */
  168.     "\033R\011@\033R\\0",            /* 'E */
  169.     "E\010^",                /* ^E */
  170.     "E\010\033R\001~\033R\\0",        /* "E */
  171.     "I\010`",                /* `I */
  172.     "I\010`",                /* 'I */
  173.     "I\010^",                /* ^I */
  174.     "I\010\033R\001~\033R\\0",        /* "I */
  175.  
  176.     "D\010-",                /* -D */
  177.     "\033R\007\\\\\033R\\0",        /* ~N */
  178.     "O\010`",                /* `O */
  179.     "O\010'",                /* 'O */
  180.     "O\010^",                /* ^O */
  181.     "O\010~",                /* ~O */
  182.     "\033R\002\\\\\033R\\0",        /* "O */
  183.     "x",                    /* x */
  184.  
  185.     "\033R\004\\\\\033R\\0",        /* 0 */
  186.     "U\010`",                /* `U */
  187.     "U\010'",                /* 'U */
  188.     "U\010^",                /* ^U */
  189.     "\033R\002]\033R\\0",            /* "U */
  190.     "Y\010'",                /* 'Y */
  191.     "T",                    /* Thorn */
  192.     "\033R\002~\033R\\0",            /* B */
  193.  
  194.     "\033R\001@\033R\\0",            /* `a */
  195.     "a\010'",                /* 'a */
  196.     "a\010^",                /* ^a */
  197.     "a\010~",                /* ~a */
  198.     "\033R\002{\033R\\0",            /* "a */
  199.     "\033R\004}\033R\\0",            /* oa */
  200.     "\033R\004{\033R\\0",            /* ae */
  201.     "\033R\001\\\\\033R\\0",        /* c, */
  202.  
  203.     "\033R\001}\033R\\0",            /* `e */
  204.     "\033R\001{\033R\\0",            /* 'e */
  205.     "e\010^",                /* ^e */
  206.     "e\010\033R\001~\033R\\0",        /* "e */
  207.     "\033R\006~\033R\\0",            /* `i */
  208.     "i\010'",                /* 'i */
  209.     "i\010^",                /* ^i */
  210.     "i\010\033R\001~\033R\\0",        /* "i */
  211.  
  212.     "d",                    /* d */
  213.     "\033R\007|\033R\\0",            /* ~n */
  214.     "\033R\006|\033R\\0",            /* `o */
  215.     "o\010'",                /* 'o */
  216.     "o\010^",                /* ^o */
  217.     "o\010~",                /* ~o */
  218.     "\033R\002|\033R\\0",            /* "o */
  219.     ":\010-"                /* :- */
  220.  
  221.     "\033R\004|\033R\\0",            /* o/ */
  222.     "\033R\001|\033R\\0",            /* `u */
  223.     "u\010'",                /* 'u */
  224.     "u\010^",                /* ^u */
  225.     "\033R\002}\033R\\0",            /* "u */
  226.     "y\010'",                /* 'y */
  227.     "t",                    /* thorn */
  228.     "y\010\033R\001~\033R\\0"        /* "y */
  229. };
  230.  
  231.