foo2zjs-wrapper(1)
π foo2zjs-wrapper β bestie edition π
okay so this is the foo2zjs-wrapper page from the General Commands Manual (that's the man section 1, the "you just type it in a shell" zone), and bestie, I'm about to make you obsessed with a printer wrapper. no cap. π
β¨ NAME β¨
foo2zjs-wrapper β the thing that turns Postscript into a ZJS printer stream. that's the whole job. it's giving translator, it's giving bridge, it's giving middle management for your laser printer. π
π SYNOPSIS π
foo2zjs-wrapper [options] [ps-file]
π¦ DESCRIPTION π¦
So. foo2zjs-wrapper is a Foomatic compatible printer wrapper for the foo2zjs printer driver. Foomatic is that whole printer database situation, and this script is the wrapper that plays nice with it.
What it actually does: it reads a Postscript ps-file β or standard input if you don't hand it a file β and converts it into Zenographics ZjStream printer format. And why would you want that? Because that's the language needed to drive the Minolta/QMS 2300 DL network color laser printer plus other Zenographics-based printers. iconic lineage honestly.
You can run this script standalone, all by itself, living its main character life. But the intended vibe is to be called from a printer spooler system that uses the Foomatic printer database. that's where it really shines. β¨
π COMMAND LINE OPTIONS π
πΈ Normal Options πΈ
These are the options for picking the parameters of a print job β the stuff you usually control on a per-job basis. lowkey the everyday essentials.
-cβ Print in color. (If you don't say this, you get monochrome. simple as that. π)-Ccolormode β Color correction mode, default is0.1β Photos (using m2300w CRDs)2β Photos and text (using m2300w CRDs)3β Graphics and text (using m2300w CRDs)10β ICM color profile (using-G *.icmfile)
-dduplex β Duplex code to send to the printer, default is1.1β off2β long edge3β short edge
-mmedia β Media code to send to the printer, default is1.
The codes depend on your model, so here's the whole menu, no skipping:
standardβ2300DL/HP 1005(-z0):1Β·2200DL(-z0):1Β·HP 1018/HP 1020(-z1):1Β·HP P1102/HP P1606(-z2):1Β·HP CP1025(-z3):1transparencyβ2300DL/HP 1005(-z0):2Β·2200DL(-z0):2Β·HP 1018/HP 1020(-z1):2Β·HP P1102/HP P1606(-z2):2Β·HP CP1025(-z3):2envelopeβ2300DL/HP 1005(-z0):257Β·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):267Β·HP P1102/HP P1606(-z2):267Β·HP CP1025(-z3):267letterheadβ2300DL/HP 1005(-z0):259Β·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):513Β·HP P1102/HP P1606(-z2):513Β·HP CP1025(-z3):513bondβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):260Β·HP P1102/HP P1606(-z2):260Β·HP CP1025(-z3):260thickβ2300DL/HP 1005(-z0):261Β·2200DL(-z0):4Β·HP 1018/HP 1020(-z1):261Β·HP P1102/HP P1606(-z2):naΒ·HP CP1025(-z3):napostcardβ2300DL/HP 1005(-z0):262Β·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):naΒ·HP CP1025(-z3):naroughβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):263Β·HP P1102/HP P1606(-z2):263Β·HP CP1025(-z3):263heavyβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):262Β·HP P1102/HP P1606(-z2):262Β·HP CP1025(-z3):262labelsβ2300DL/HP 1005(-z0):263Β·2200DL(-z0):3Β·HP 1018/HP 1020(-z1):263Β·HP P1102/HP P1606(-z2):265Β·HP CP1025(-z3):265vellumβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):273Β·HP P1102/HP P1606(-z2):273Β·HP CP1025(-z3):273mediumβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):282Β·HP CP1025(-z3):282extraheavyβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):283Β·HP CP1025(-z3):283colorβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):512Β·HP P1102/HP P1606(-z2):512Β·HP CP1025(-z3):512lightβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):258Β·HP P1102/HP P1606(-z2):258Β·HP CP1025(-z3):258preprintedβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):514Β·HP P1102/HP P1606(-z2):514Β·HP CP1025(-z3):514prepunchedβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):515Β·HP P1102/HP P1606(-z2):515Β·HP CP1025(-z3):515recycledβ2300DL/HP 1005(-z0):naΒ·2200DL(-z0):naΒ·HP 1018/HP 1020(-z1):516Β·HP P1102/HP P1606(-z2):516Β·HP CP1025(-z3):516
-ppaper β Paper size code to send to the printer, default is1. and here's the whole chart because we do not gatekeep:letterβMC 2300DL/HP 1005(-z0):1Β·HP 1018/HP 1020(-z1):1Β·HP P1102/HP P1606(-z2):1Β·HP CP1025(-z3):1legalβMC 2300DL/HP 1005(-z0):5Β·HP 1018/HP 1020(-z1):5Β·HP P1102/HP P1606(-z2):5Β·HP CP1025(-z3):5executiveβMC 2300DL/HP 1005(-z0):7Β·HP 1018/HP 1020(-z1):7Β·HP P1102/HP P1606(-z2):7Β·HP CP1025(-z3):7A4βMC 2300DL/HP 1005(-z0):9Β·HP 1018/HP 1020(-z1):9Β·HP P1102/HP P1606(-z2):9Β·HP CP1025(-z3):9A5βMC 2300DL/HP 1005(-z0):11Β·HP 1018/HP 1020(-z1):11Β·HP P1102/HP P1606(-z2):11Β·HP CP1025(-z3):11B5jisβMC 2300DL/HP 1005(-z0):13Β·HP 1018/HP 1020(-z1):13Β·HP P1102/HP P1606(-z2):13Β·HP CP1025(-z3):13env #10βMC 2300DL/HP 1005(-z0):20Β·HP 1018/HP 1020(-z1):20Β·HP P1102/HP P1606(-z2):20Β·HP CP1025(-z3):20env DLβMC 2300DL/HP 1005(-z0):27Β·HP 1018/HP 1020(-z1):27Β·HP P1102/HP P1606(-z2):27Β·HP CP1025(-z3):27env CLβMC 2300DL/HP 1005(-z0):28Β·HP 1018/HP 1020(-z1):28Β·HP P1102/HP P1606(-z2):28Β·HP CP1025(-z3):28env B5βMC 2300DL/HP 1005(-z0):34Β·HP 1018/HP 1020(-z1):34Β·HP P1102/HP P1606(-z2):34Β·HP CP1025(-z3):34env MonarchβMC 2300DL/HP 1005(-z0):37Β·HP 1018/HP 1020(-z1):37Β·HP P1102/HP P1606(-z2):37Β·HP CP1025(-z3):37postcard (japan)βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):260Β·HP P1102/HP P1606(-z2):43Β·HP CP1025(-z3):43B5isoβMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):259Β·HP P1102/HP P1606(-z2):naΒ·HP CP1025(-z3):naA6βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):262Β·HP P1102/HP P1606(-z2):70Β·HP CP1025(-z3):70double postcard rotatedβMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):261Β·HP P1102/HP P1606(-z2):82Β·HP CP1025(-z3):8216k 197x273βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):257Β·HP P1102/HP P1606(-z2):257Β·HP CP1025(-z3):257fanfold german legalβMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):258Β·HP P1102/HP P1606(-z2):258Β·HP CP1025(-z3):25816k 184x260βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):263Β·HP CP1025(-z3):26316k 195x270βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):264Β·HP CP1025(-z3):264photo 4x6βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):naΒ·HP CP1025(-z3):268photo 5x8βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):naΒ·HP CP1025(-z3):269photo 10x15βMC 2300DL/HP 1005(-z0):naΒ·HP 1018/HP 1020(-z1):naΒ·HP P1102/HP P1606(-z2):naΒ·HP CP1025(-z3):270
-ncopies β Number of copies, default is1. yes queen, print it twelve times, go off.-rxresxyres β Set device resolution in pixels/inch, default is1200x600.-ssource β Source (Input Slot) code to send to the printer, default is7.1β upper2β lower4β manual7β auto
-tβ Draft mode. Every other pixel is white. it's giving β¨sparseβ¨-Tdensity β Print density (1-5). The default is3(medium).-2-3-4-5-6-8-9-10-12-14-15-16-18β Print in N-up. Requires thepsutilspackage. (yeah, that's a lot of flags, and yeah, you need the package, no shortcuts π )-oorient β Orientation used for N-up.Portraitβ-op(normal)Landscapeβ-ol(rotated 90 degrees anticlockwise)Seascapeβ-os(rotated 90 degrees clockwise)
π§ Printer Tweaking Options π§
These are the options used to customize the operation of foo2zjs for a particular printer. it's giving bespoke, it's giving tailoring. πͺ‘
-uxoffxyoff β Set the offset of the start of the printable region from the upper left corner, in pixels (default varies with paper size). The defaults should work on the2200DLand2300DL, and have not been tested on any other printers. π-lxoffxyoff β Set the offset of the end of the printable region from the lower right corner, in pixels (default varies with paper size). Same deal: the defaults should work on the2200DLand2300DL, and have not been tested on any other printers.-Lmask β Send the logical clipping values from-u/-lin the ZjStream.
Okay so context, because this one is lowkey galaxy-brain: foo2zjs-wrapper always runs Ghostscript with the ideal page dimensions, so that the scale of the image is correct β regardless of whether or not the printer has unprintable regions. This option is used to move the position of the clipped image back to where it belongs on the page. The default is to send the amount which was clipped by -u and -l, and that should be good in most cases.
0β don't send any logical clipping amounts1β only send Y clipping amount2β only send X clipping amount3β send both X and Y clipping amounts
-Pβ Do not sendSTART_PLANEcodes on monochrome output. May be needed by some monochrome-only printers, such as theHP LaserJet 1000. so if your printer is strictly a black-and-white girly, this might be the one.-Xpadlen β Add extra zero padding to the end of BID segments. The default is16bytes. Padding16bytes of zeroes is needed for older ZjStream printers, such as theMinolta 2200DLandHP LaserJet 1000, and seems harmless to newer ones, such as theMinolta 2300DL. So the default should be good for all cases. slay, backwards compatibility. π«Ά-zmodel β Model. Default is0.0β KM 2300DL / HP 1000 / HP 10051β HP 1018 / HP 1020 / HP 10222β HP Pro P1102 / P1566 / P1606dn3β HP Pro CP1025
π Color Tweaking Options π
These are the options used to control the quality of color output.
β οΈ Color correction is currently a WORK IN PROGRESS. not me warning you, the manpage said it. π
-ggsopts β Additional options to pass to Ghostscript, such as-gβ-dDITHERPPI=nnnβ, etc. This option may appear more than once. stack them like stickers on a laptop. β¨-Gprofile.icm β Convertprofile.icmto a Postscript color rendering dictionary (CRD) usingfoo2zjs-icc2psand adjust the printer colors by using the Postscriptsetcolorrenderingoperator. (WORK IN PROGRESS). π-Ggamma-file.ps β Prependgamma-file.psto the Postscript input to perform color correction using thesetcolortransferPostscript operator. For example, the file might contain:
{0.333 exp} {0.333 exp} {0.333 exp} {0.333 exp} setcolortransfer
-Iintent β Select profile intent from the ICM file.0=Perceptual,1=Colorimetric,2=Saturation,3=Absolute. Default is0(perceptual).
π₯ Debugging Options π₯
These options are used for debugging foo2zjs and its wrapper. detective mode activated. π
-Splane β Output just a single color plane from a color print and print it on the black plane. The default is to output all color planes.1β Cyan2β Magenta3β Yellow4β Black
-Dlevel β Set Debug level, default is0.
π EXAMPLES π
Create a monochrome ZjStream from a Postscript document, examine it, and then print it using a RAW print queue:
foo2zjs-wrapper testpage.ps > testpage.zm
zjsdecode < testpage.zm
lpr -P raw testpage.zm
Create a color ZjStream stream from a Postscript document:
foo2zjs-wrapper -c testpage.ps > testpage.zc
π FILES π
/usr/bin/foo2zjs-wrapper
π SEE ALSO π
β AUTHOR β
- Rick Richardson
<rick.richardson@comcast.net> http://foo2zjs.rkkda.com/
okay bestie that's the whole page, every flag, every code, every table cell, all of it. no gatekeeping, no skimming, we ate and left no crumbs. π«Ά
This is the foo2zjs-wrapper(1) page from the General Commands Manual β shoutout to the standard manual setup that keeps our pages looking cute and consistent β and the author credit belongs to Rick Richardson, with the project living at http://foo2zjs.rkkda.com/. go forth and print. π
β¨
π¦ where this page comes from
- ubuntu noble: printer-driver-foo2zjs-common 20200505dfsg0-2ubuntu6 Β· GPL-2.0-or-later
- ubuntu questing: printer-driver-foo2zjs-common 20200505dfsg0-2ubuntu6
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms