C printer commands

Discussion in 'C Programming' started by KJ, Aug 26, 2003.

  1. KJ

    KJ Guest

    Would anyone have a list of printer commands to use within printf for
    a deskjet printer in C. I have worked out that bold is
    \x1B\x28\x73\x33\x42 but i would like to have a list to perform other
    commands like font size, etc...

    Any help would be appreciated.
     
    KJ, Aug 26, 2003
    #1
    1. Advertising

  2. KJ <> scribbled the following:
    > Would anyone have a list of printer commands to use within printf for
    > a deskjet printer in C. I have worked out that bold is
    > \x1B\x28\x73\x33\x42 but i would like to have a list to perform other
    > commands like font size, etc...


    > Any help would be appreciated.


    What gave you the impression this had anything to do with C? The printer
    is the one in charge of those commands. They work the same way no matter
    what language printed them. Please ask in a newsgroup dedicated to your
    own implementation instead.

    --
    /-- Joona Palaste () ---------------------------\
    | Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
    | http://www.helsinki.fi/~palaste W++ B OP+ |
    \----------------------------------------- Finland rules! ------------/
    "There's no business like slow business."
    - Tailgunner
     
    Joona I Palaste, Aug 26, 2003
    #2
    1. Advertising

  3. (KJ) wrote in
    news::

    > Would anyone have a list of printer commands to use within printf for
    > a deskjet printer in C. I have worked out that bold is
    > \x1B\x28\x73\x33\x42 but i would like to have a list to perform other
    > commands like font size, etc...


    The C language does not define such things. You happen to have found some
    character sequences that do "interesting" things for your printer but this
    has nothing to do with the C language. There must be a list of sequences
    in your printer's programming manual (my HP Laser Jet came with such a
    manual, if yours does not, try the company's website).

    --
    - Mark ->
    --
     
    Mark A. Odell, Aug 26, 2003
    #3
  4. KJ wrote:

    > Would anyone have a list of printer commands to use within printf for
    > a deskjet printer in C. I have worked out that bold is
    > \x1B\x28\x73\x33\x42 but i would like to have a list to perform other
    > commands like font size, etc...
    >
    > Any help would be appreciated.


    HP Printers use a language called PCL. It is based on escape sequences:
    an ESCAPE character followed by other bytes or characters. Search
    their website for more information. They do have a book about 2 inches
    thick describing the language.

    Some HP printers also use a language called Postscript. This is
    Page Description Language developed by Adobe, Inc. They too have a
    thick book available that describes the language. Check out their
    websidte at http://www.adobe.com.

    However, many platforms use a "driver" between the printer and your
    application. The driver converts operating system commands (function
    calls) into the printer's language. This is a lot more productive
    than sending the actual printer commands. In the Postscript class
    that I attended, they said that very, very few people write in
    Postscript; everybody else uses the drivers.

    --
    Thomas Matthews

    C++ newsgroup welcome message:
    http://www.slack.net/~shiva/welcome.txt
    C++ Faq: http://www.parashift.com/c -faq-lite
    C Faq: http://www.eskimo.com/~scs/c-faq/top.html
    alt.comp.lang.learn.c-c++ faq:
    http://www.raos.demon.uk/acllc-c /faq.html
    Other sites:
    http://www.josuttis.com -- C++ STL Library book
     
    Thomas Matthews, Aug 26, 2003
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Samuel Lee
    Replies:
    0
    Views:
    534
    Samuel Lee
    Nov 11, 2003
  2. Ben Pfaff

    Re: man pages for C commands (GCC commands)

    Ben Pfaff, Jun 24, 2003, in forum: C Programming
    Replies:
    4
    Views:
    3,995
    Thomas Stegen
    Jun 28, 2003
  3. hari
    Replies:
    2
    Views:
    295
    Gabriel Genellina
    Dec 5, 2007
  4. Krist
    Replies:
    8
    Views:
    7,060
    lightst4r
    Jul 23, 2012
  5. Replies:
    5
    Views:
    157
Loading...

Share This Page