You can set a pagecolor with the background package and the page color using the color command. You will need to pass the values onto setlistings as well. Color inversion of images is perhaps not possible although you can manipulate them as well. What do you exactly want the images to look like?

\documentclass{article}
\usepackage{graphicx}
\usepackage{listings}
\lstnewenvironment{teX}[1][]
{\lstset{language=[LaTeX]TeX}\lstset{escapeinside={(*@}{@*)},
numbers=left,numberstyle=\normalsize,stepnumber=1,numbersep=5pt,
breaklines=true,
%firstnumber=last,
%frame=tblr,
framesep=5pt,
basicstyle=\normalsize\ttfamily,
showstringspaces=false,
keywordstyle=\ttfamily\color{orange},
%identifierstyle=\ttfamily,
stringstyle=\color{maroon},
commentstyle=\color{black},
rulecolor=\color{gray!10},
xleftmargin=0pt,
xrightmargin=0pt,
aboveskip=\medskipamount,
belowskip=\medskipamount,
backgroundcolor=\color{black}, #1
}}
{}
\usepackage{hyperref}
\usepackage{background}
\SetBgContents{}
\begin{document}
\pagecolor{black}
\color{green}
\begin{teX}
\documentclass{article}
\usepackage{graphicx}
\usepackage{listings}
\lstnewenvironment{teX}[1][]
\end{teX}
\end{document}
xpdf -rvor invert entire screen withxcalib -i -a. – Grzegorz Wierzowiecki Feb 26 '12 at 20:08