Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How do I generate a pdf file with transparent background

215 views
Skip to first unread message

MMasroorAli

unread,
Mar 1, 2010, 5:33:34 AM3/1/10
to
Dear All,
I need to generate a pdf file wtih transparent background using LaTeX.

I am trying to generate a pdf file (say back.pdf) with a watermark at
the middle and (scanned) signature at the bottom. Then I will want to
put this back.pdf on another multipage pdf file using pdftk. The
problem is, when I use stamp option with pdftk, the watermark in the
middle covers the original text, when I use background option, the
watermark is not displayed.

Here is my back.tex

\documentclass{article}

\usepackage[a4paper,dvips,left=25.0mm,top=15.0mm,bottom=7.50mm,right=15.0mm]
{geometry}

\usepackage{times}

\raggedright

\usepackage{xwatermark}

\usepackage{pgf}

\usepackage{xcolor}

\begin{document}

\pagestyle{empty}

\watermarksetup{allpages=true,
angle=45,scale=0.375,
color=pink,
textmark=\makebox[0.75\textwidth][c]{\sffamily\mdseries Processed @
CSE, BUET},
align=center,
xcoord=0,ycoord=0
}

\vspace*{0.0mm}
\vfill

\pgfimage[width=0.2\textwidth]{mmamkinitial.png}\hfill

\end{document}

The png file at the end is a simple png file containing scanned
signatures.


I generate the back pdf using pdflatex.

Then for pdftk,

pdftk in.pdf background back.pdf output out.pdf

covers text in in.pdf

pdftk in.pdf stamp back.pdf output out.pdf

does not display the watermark at center, the signature at bottom is
correctly displayed.

The only solution will be to make back.pdf transparent. How do I do
that?

Any other suggestion will be appreciated.

Thanks in advance.

Joris

unread,
Mar 1, 2010, 8:04:19 AM3/1/10
to

I don't know the answer to your question, but you could achieve the
desired effect using the pdfpages package, albeit that you're then
compiling a latex document for each pdf file you'd like watermarked.

Diego Torquemada

unread,
Mar 2, 2010, 11:19:59 AM3/2/10
to

What about using the eso-pic package

I used in some document I have:

\newcommand\BackgroundPicture{%
\parbox[b][\paperheight]{\paperwidth}{%
\vfill
\centering
\includegraphics[width=0.6\paperwidth,height=0.6\paperheight,%
keepaspectratio]{unal_logo/unallogo} %Logo de
la universidad
\vfill
}}

% Just make a \fbox around the graphic and measure how much should you
put here
% Remember to calculate the correct bounding box "ps2eps unallogo.ps"
\AddToShipoutPicture{\put(14,0){\BackgroundPicture}}


HERE IS YOUR TEXT...

AND THEN..

\ClearShipoutPicture

0 new messages