Re: Output to matrix printer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Oct 14, 2008 at 6:23 PM, Dušan Novaković <ndusan@xxxxxxxxx> wrote:

> I have some request to sent text to matrix printer to print ticket for
> theater. Is it possible to do that whit some php functions? Main point
> is how to control length of paper that will be drawn inside and to
> print text on a specific place. It would be nice if somebody can write
> the code about this as example.
>
> Thnx, Dusan
>
> --
> made by Dusan
>

Decide on the font you will use - either 10 or 12 characters per inch.
A line is usually 1/8" high.

So you essentially have a matrix running at "n" characters per inch
horizontally, and "m" fractions of an inch vertically.

Fit your print into this matrix - some people do it with an array, others
just work the spaces.

Provide a "test" ticket so the operator can get the printer lined up. With
a  tractor feed, after that you are good for a whole box of tickets.

Oh - one more thing - you may have to advance a number of lines so the
ticket can be torn off after printing, then reverse feed the same number.

Another tip - set your page length just to the height of the ticket.

You really want to exploit the basic native font built into the printer.

Hope this helps - Miles

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux