Recent

Author Topic: Dot matrix Output  (Read 3398 times)

Zath

  • Sr. Member
  • ****
  • Posts: 391
Dot matrix Output
« on: June 21, 2013, 12:41:46 pm »
This might sound really dumb but how do you print to a dot matrix so it prints each line character by character rather than printing pixel line by pixel line as if its printing graphics ?
I tried before with Delphi many moons ago but struggled to get my head round all the bands etc.

Thanks

CM630

  • Hero Member
  • *****
  • Posts: 1356
  • Не съм сигурен, че те разбирам.
    • http://sourceforge.net/u/cm630/profile/
Re: Dot matrix Output
« Reply #1 on: June 21, 2013, 01:47:56 pm »
By default, that's just how it works- you send characters and it prints characters. When you sent to it abcd, it prints abcd.
If you want to print graphics, you have to use special character sequences, usually including nonprintable characters.
Did you try this: http://wiki.freepascal.org/Using_the_printer
Лазар 4,0 32 bit (sometimes 64 bit); FPC3,2,2

taazz

  • Hero Member
  • *****
  • Posts: 5368
Re: Dot matrix Output
« Reply #2 on: June 21, 2013, 02:45:43 pm »
Which OS? On windows all printer drivers use a graphics output by default in order to use character based output you need to use passthrough function which sends everything as raw bytes and you have full control about the escape codes and the final text through them. Please explain in detail what exactly you have tried the result and expected results.
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

CM630

  • Hero Member
  • *****
  • Posts: 1356
  • Не съм сигурен, че те разбирам.
    • http://sourceforge.net/u/cm630/profile/
Re: Dot matrix Output
« Reply #3 on: June 24, 2013, 07:57:21 am »
I am quite sure, that it is not that way, but:
  1. If you use notepad or something similar, it will simply send text codes.
  2. If you use something which supports formatting (Word, PDF*) it will embed the fonts in the printer, and then it will start printing.
 
Consider:
1. Text pages are printed much faster than graphic pages (or at least on older printers with small memory and LPT)
2. If you print a Word document to a PDF printer, after opening the printer, text is still presented as text- you can copy it as such.
Лазар 4,0 32 bit (sometimes 64 bit); FPC3,2,2

 

TinyPortal © 2005-2018