0

I have the following original pdf document (3 - pages are shown)

The pdf link is https://filebin.net/ovsvodpstlysglgw/testing2.pdf?t=xwdku113

enter image description here

I am trying to invert the color of the pdf using

\documentclass{article}
\usepackage{geometry}
\usepackage{pdfpages}
\usepackage{xcolor}
\pagecolor[rgb]{0,0,0}
\color[rgb]{1,1,1}

\begin{document} \includepdfmerge[fitpaper]{./testing2.pdf, 1} \includepdfmerge[fitpaper]{./testing2.pdf, 2} \includepdfmerge[fitpaper]{./testing2.pdf, 3} \end{document}

I get the following output. The text in black color is not getting inverted (eg page numbers and text in page 2). I am expecting it to become white. In Page 1 added two new white lines after inverting. But in page 3 black lines got inverted to white.

enter image description here

So how can i get it inverted it correctly like below (i got this using gimp->colors->value invert the first image)

enter image description here

Santhosh
  • 265
  • 2
    I'm impressed that you see anything at all -- normally \pagecolor overprints input from pdfpages. In any case you can't change the color of included graphics (and pdfpages does not more than \includegraphics) like this in a reliable way, it only works in special cases, see e.g. https://tex.stackexchange.com/a/65083/2388. – Ulrike Fischer Aug 06 '20 at 18:15
  • Ok. So it does not work for all cases. Here on page 3 the black lines got inverted to white could be a special case then, – Santhosh Aug 06 '20 at 18:24
  • as nobody here has the test files you are constantly using, nobody can test your examples. – Ulrike Fischer Aug 06 '20 at 18:26
  • the test file link is https://filebin.net/ovsvodpstlysglgw/testing2.pdf?t=xwdku113 – Santhosh Aug 06 '20 at 18:41
  • as expected everything is black when using pdflatex, with xelatex I get more or less your output, but there is no inversion involved. You see the colors of your document, which seem to have been glued together from some word documents converted to pdf. If you want an inverted version you will have to create a suitable source document. – Ulrike Fischer Aug 07 '20 at 07:57
  • Yes, this document is made from word. except that i have lated added extra margin and page number using pdflatex – Santhosh Aug 07 '20 at 14:10

0 Answers0