oreilly.comSafari Books Online.Conferences.


Outputting Text
Pages: 1, 2, 3


The chart below describes some of the more popular enscript options.

Common Options for GNU Enscript


Specify number of columns per page; e.g. for four columns/page, use "-4".


Specify number of copies; e.g. to print three copies, use "-#3".


Specify the page numbers to be printed. Give specific pages by their number, page ranges between hyphens (for pages 34-45 inclusive, use "-a34-45"); the special "odd" prints odd pages and "even" prints even pages.


Spool output to the printer named "printer".


"Pretty-print" the text written in a given language with context highlighting; to list the supported languages, run "enscript --help-pretty-print".


Specify height of highlight bars, in lines (without [number], the value of 2 is used).


Indent lines by [number] characters, or follow [number] with a letter denoting the unit to use:

  c   centimeters
  i   inches
  p   PostScript points


Pass input files through [filter]---can be a tool or quoted command.


Print borders around columns.


Specify number of lines per page.


Specify a quoted string "underlay" to print underneath every page.


Specify number of logical pages to print on each page of output.


Specify the level of gray color used in printing the highlight bars.


Adjust left, right, top and bottom page margins; numbers are in PostScript points, and when specifying, any can be omitted.


Rotates each even-numbered page 180 degrees.

Next week: how to process and use the TeX and LaTeX files you might encounter out there.

arrowMore Living Linux articles.

Michael Stutz spent the 1990s making open-source recordings of music and writing fiction and other text (including the open source etext novel Sunclipse). He also wrote a comprehensive, general-purpose copyleft license that anyone could use on any published data.

Michael Stutz was one of the first reporters to cover Linux and the free software movement in the mainstream press.

Read more Living Linux columns.

Discuss this article in the O'Reilly Network Linux Forum.

Return to the Linux DevCenter.


Linux Online Certification

Linux/Unix System Administration Certificate Series
Linux/Unix System Administration Certificate Series — This course series targets both beginning and intermediate Linux/Unix users who want to acquire advanced system administration skills, and to back those skills up with a Certificate from the University of Illinois Office of Continuing Education.

Enroll today!

Linux Resources
  • Linux Online
  • The Linux FAQ
  • Linux Kernel Archives
  • Kernel Traffic

  • Sponsored by: