Visit the LQ Articles and Editorials section
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 08-27-2010, 12:55 PM   #1
LQ Newbie
Registered: Aug 2010
Posts: 3

Rep: Reputation: 0
a2ps - How to get 80 rows by 130 columns

I have been messing with a2ps in order to print a text file I have that has 130 columns by 80 rows per page. It appears that a2ps automatically scales the number of rows based upon the number of columns I try to print.

For example,
a2ps --columns=1 --rows=1 --portrait --lines-per-page=80 --chars-per-line=130 file.txt -o - | ps2pdf - file.pdf

The file prints properly for the columns but a2ps scales the rows to be 97 rows per page. So the 80 rows print but the next 17 rows are blank. It is not scaling the font for for 80 rows.

I hope this makes sense.

Old 08-28-2010, 12:06 PM   #2
Registered: Aug 2006
Location: Saint Paul, MN, USA
Distribution: {Free,Open}BSD, CentOS, Debian, Fedora, Solaris, SuSE
Posts: 722

Rep: Reputation: 73

I did not look exhaustively into this, but I got marginally-OK results from:
a2ps -1 --landscape --lines-per-page=80 --chars-per-line=200
although the cpl could have been slightly smaller for this run.

You may have noticed that there is a relationship between the lpp and the cpl: if the cpl is about right (say 130), then the lpp are too few. Using portrait as opposed to landscape is way too small -- for my eyes as well as for my oldish laser printer.

You may need to do some trial and error, although perhaps someone may stop by with some words of wisdom.

I assume that, like me, you have a kind of template file set up, 130 X 80, on which to test your experiments.

Best wishes ... cheers, makyo


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Convert columns of data into rows jaufer Linux - Software 3 06-29-2010 06:19 PM
How to print data in rows and columns suran Linux - General 3 03-15-2009 03:53 PM
text data conversion: rows into columns frankie_DJ Programming 6 06-03-2006 07:43 AM
columns & rows Ammad Linux - General 1 08-08-2005 05:02 AM
rows and columns digitalgravy Linux - General 2 03-16-2004 07:47 PM

All times are GMT -5. The time now is 12:20 PM.

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