LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Printing PDF letterhead via CUPS (https://www.linuxquestions.org/questions/linux-software-2/printing-pdf-letterhead-via-cups-699960/)

chr00ted 05-18-2009 02:29 PM

The m4 file I'm using is (reports.m4):


\documentclass[letterpaper,10pt]{article}
\usepackage{graphicx}
\usepackage{eso-pic}
\setlength{\textwidth}{18.5cm}

\usepackage{fancyhdr}
\pagestyle{fancy}

\addtolength{\headheight}{\baselineskip}
\usepackage[hmargin=1cm,vmargin=2.1cm]{geometry}


\lhead{
\includegraphics[height=0.5in]{/etc/scripts/logo.png}
}
\chead{\leftmark {\bfseries ACME, Inc.}\\ \rightmark{666 Mockingbird Lane; Arlington, TX 76002}}
\rhead{\leftmark{TX Division}\\ \rightmark{(456) 123-1456}}


\begin{document}

\begin{verbatim}
include(reportfile)
\end{verbatim}

\end{document}



I run with a script that does:
m4 -D reportfile=/tmp/whatever.txt /etc/scripts/reports.m4 > /tmp/whatever.tex
pdflatex /tmp/whatever.tex

EricPH 06-16-2009 02:23 AM

hello,

I don't understand exactly what you did (because mainly, I am completly ignorant of m4 and tex).
Does this script allow to print without any manual operation to a CUPS print queue ?
In this case, where do you put it and how is it called in the CUPS process ?

With great gratitude of your future explanation. :-)

Gasmit 02-01-2014 10:21 AM

Postprinted letterhead
 
I did the trick by having letterhead in PDF-files, converting all input to PDF, put it together with pdftk, *and* I did some things to hide all this stuff inside CUPS configuration.

Eventually, the different letterheads are available as so called CUPS printer instances.

Explanation (in Dutch) here http://www.atcomputing.nl/blog/archi...3T14_43_06.txt


All times are GMT -5. The time now is 05:41 AM.