Results 1 to 2 of 2
Hello, I use the cli a lot and print off documents that I have created in vim or a simple man page that I want a hard copy. However, the ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 04-13-2013 #1
- Join Date
- Nov 2010
Format print output of lp command
I use the cli a lot and print off documents that I have created in vim or a simple man page that I want a hard copy. However, the actual print out looks terrible: the lines are not left justified. I am not able to discern a pattern but I figure there is one. Are there any tricks on making man pages or vim docs print out more appealing?
Also, I am not sure what category "Printing problems" go into so if this is not the correct one, please let me know so I can move it to the appropriate one.
- 04-13-2013 #2
- Join Date
- Apr 2009
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
See the groff man page. The groff command is the successor to troff and nroff, unix text formatting programs. In any case, it allows you to embed formatting commands in your text file so that it produces the output you want. TEX is another option that has more professional output capabilities, but is more complex and difficult to learn.
As for man pages, use the --preformat option and pipe the output to lpr. IE: man --preformat subject | lpr ...
FWIW, man uses groff mostly for formatting. See the man config file /etc/man.config.Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!