7

I'd like to use gedit or some similar program just as a page formatter and pipe some text through it and onto the printer. | lpr just doesn't cut it in the presentation department. The printed output is subpar, even if I try to tinker with the margin and font size options. But I like the way text looks like when printed from gedit. Is there a way to have the best of both worlds and use a command line pipeline to print a text file with gedit-quality formatting?

9

There is a2ps utility for pagination and pretty printing of plain text.

7

I use OpenOffice. The command runs like this openoffice -p file.txt. This will print file.txt to your default printer. openoffice -pt printername file.txt will print to other than default printer. It will work with other document formats support by openoffice. Check man openoffice for more options.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.