LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 05-17-2011, 08:06 PM   #1
rmknox
Member
 
Registered: May 2010
Posts: 354

Rep: Reputation: 34
printer and fonts


Maybe someone here can help me. The last time I got involved with printers and fonts, printers had tractors and ribbons and the only codes in use were ascii and ebcdic. So even if I could remember it would be out of date.

I've written a C program that writes a text file. I want to print it. I run it through expand and send it to lp, but it comes out in an undesirable primitive font.

Once upon a time, one sent a string of commands to the printer telling it what font to use and what size, etc. I dont think this is done anymore, and if it is I dont remember how to do it.

I assume programs embed in their output instructions in some common format which tell this stuff to the printer - in my case a HP1020. I've been looking on the search engines but I haven't found the magic words to find what I want.

Can someone point me to some info on how to get my output formatted. If it involves some escape sequences in the file, maybe a pointer to a description of which does what?

Thanks
Dick
 
Old 05-18-2011, 05:03 AM   #2
dwhitney67
Senior Member
 
Registered: Jun 2006
Location: Maryland
Distribution: Kubuntu, Fedora, RHEL
Posts: 1,541

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
Perhaps the utility "a2ps" may help you; it stands for "ASCII to PostScript". Also, their is GhostScript, which I believe can be used to generate output that can be sent to the printer. Another is LaTex, but that's a library that I have refused to ever bother with.
 
1 members found this post helpful.
Old 05-18-2011, 04:43 PM   #3
rmknox
Member
 
Registered: May 2010
Posts: 354

Original Poster
Rep: Reputation: 34
dw
thanks for the pointers - I'll see where they lead me

Dick
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
send all fonts on my computer to printer Dafydd Programming 5 06-01-2010 01:00 AM
Print to HP P4515 using PCL codes for built-in printer fonts from AIX 5.2 jc2it AIX 1 03-31-2010 05:32 AM
How to control printer fonts and margins? sirius56 Linux - Newbie 1 04-10-2007 03:13 PM
Adjust Printer Fonts and Margins sirius56 Linux - Hardware 1 12-03-2006 09:45 PM
keeping printer on at bootup keeps printer from printing (some printer modules loaded TheOneAndOnlySM Slackware 1 10-17-2003 07:39 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:58 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration