Anybody have a script (maybe perl?) that you can pass a text file to, and it will determine the length of the longest line in the file, then pre-pend the file with PCL code that will size and orient the text so that it will best fit a letter sized page in a non-proportional font?
For example,
if $longestline < 80 print portrait, 10cpi
if $longestline < 96 print portrait, 12cpi
if $longestline < 120 print portrait, 16 cpi
...
if $longestline < x print landscape, 12cpi
if $longestline < y print landscape, 16cpi
...
Maybe even have a legal size page option if $longestline is very long.
I have something that works with 10, 12, & 16 cpi using "[esc]&_S" but am stuck understanding how to get a more precise fit with other spacings such as 11cpi, 13cpi, etc.
Thank you,
Rich Alexander
For example,
if $longestline < 80 print portrait, 10cpi
if $longestline < 96 print portrait, 12cpi
if $longestline < 120 print portrait, 16 cpi
...
if $longestline < x print landscape, 12cpi
if $longestline < y print landscape, 16cpi
...
Maybe even have a legal size page option if $longestline is very long.
I have something that works with 10, 12, & 16 cpi using "[esc]&_S" but am stuck understanding how to get a more precise fit with other spacings such as 11cpi, 13cpi, etc.
Thank you,
Rich Alexander