auctex-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[AUCTeX-diffs] Changes to auctex/preview/latex/preview.dtx,v


From: Ralf Angeli
Subject: [AUCTeX-diffs] Changes to auctex/preview/latex/preview.dtx,v
Date: Sun, 14 Feb 2010 14:47:21 +0000

CVSROOT:        /cvsroot/auctex
Module name:    auctex
Changes by:     Ralf Angeli <angeli>    10/02/14 14:47:21

Index: preview.dtx
===================================================================
RCS file: /cvsroot/auctex/auctex/preview/latex/preview.dtx,v
retrieving revision 1.124
retrieving revision 1.125
diff -u -b -r1.124 -r1.125
--- preview.dtx 3 Feb 2008 14:53:31 -0000       1.124
+++ preview.dtx 14 Feb 2010 14:47:20 -0000      1.125
@@ -2,8 +2,8 @@
 %%    The preview style for extracting previews from LaTeX documents.
 %%    Developed as part of AUCTeX <URL:http://www.gnu.org/software/auctex>.
 %
-%     Copyright (C) 2001, 2002, 2003, 2004, 2005,
-%                   2006 Free Software Foundation
+%     Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006,
+%                   2010 Free Software Foundation
 %
 %     This program is free software; you can redistribute it and/or modify
 %     it under the terms of the GNU General Public License as published by
@@ -20,7 +20,7 @@
 %     Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
 %     Boston, MA 02110-1301  USA
 % \fi
-% \CheckSum{1664}
+% \CheckSum{1746}
 % \GetFileInfo{preview.sty}
 % \date{\filedate}
 % \author{David address@hidden
@@ -31,7 +31,7 @@
 % environments (most notably displayed formulas) from \LaTeX\ sources
 % as graphics.  This works with DVI files postprocessed by either
 % Dvips and Ghostscript or dvipng, but it also works when you are
-% using PDF\TeX for generating PDF files (usually also postprocessed
+% using PDF\TeX\ for generating PDF files (usually also postprocessed
 % by Ghostscript).
 %
 % Current uses of the package include the \previewlatex\ package for
@@ -124,6 +124,8 @@
 %   if possible.
 % \item[|pdftex|] If this option is set, PDF\TeX\ is assumed as the
 %   output driver.  This mainly affects the |tightpage| option.
+% \item[|xetex|] If this option is set, Xe\TeX\ is assumed as the
+%   output driver.  This mainly affects the |tightpage| option.
 % \item[|displaymath|] will make all displayed math environments
 %   subject to preview processing.  This will typically be the most
 %   desired option.
@@ -438,11 +440,11 @@
 address@hidden #2#4 $}} address@hidden #1 #2${#1}
 \begingroup \catcode`\_=12
 address@hidden@version $Name:  $ address@hidden@empty
address@hidden@version CVS-$Revision: 1.124 $ \endgroup \else
address@hidden@version CVS-$Revision: 1.125 $ \endgroup \else
   \def\next release_{} \lccode`\_=`.
   \edef\next{\lowercase{\endgroup
     address@hidden@version}}} \next \fi
address@hidden $Date: 2008/02/03 14:53:31 $
address@hidden $Date: 2010/02/14 14:47:20 $
 \edef\next{\noexpand\ProvidesPackage{preview}%
   [\next\space address@hidden (AUCTeX/preview-latex)]}
 \next
@@ -588,6 +590,11 @@
 %    \begin{macrocode}
 \DeclareOption{pdftex}{%
   address@hidden@}
+%    \end{macrocode}
+% And so does the |xetex| option.
+%    \begin{macrocode}
+\DeclareOption{xetex}{%
+  address@hidden@@}
 %</!active>
 %    \end{macrocode}
 % \end{macro}
@@ -722,7 +729,7 @@
 %   called.  You must not under any circumstances change |address@hidden|
 %   in any way that would add typeset material at the front of it,
 %   except for PostScript header specials, since the front of
-%   |address@hidden| may contains stuff from \cmd{\AtBeginDvi}.
+%   |address@hidden| may contain stuff from \cmd{\AtBeginDvi}.
 %   address@hidden@end} contains two types of code additions: stuff
 %   that adds to |address@hidden|, like the |labels| option does, and
 %   stuff that measures out things or otherwise takes a look at the
@@ -739,12 +746,15 @@
 %   be at the (1in,1in)~mark defined by \TeX.  That way we can
 %   properly take ascenders into account.  And the third reason is
 %   that \TeX\ treats a \cmd{\hbox} and a \cmd{\vbox} differently with
-%   regard to the treating of its depth.
+%   regard to the treating of its depth.  Shifting \cmd{\voffset} and
+%   \cmd{\hoffset} can be inhibited by setting |address@hidden@override|.
 %    \begin{macrocode}
    address@hidden@end
    {\let\protect\noexpand
+   address@hidden@address@hidden
    address@hidden
    \hoffset=\z@
+   \fi
    address@hidden@snippet
    address@hidden
    address@hidden
@@ -1276,7 +1286,13 @@
 %    \begin{macrocode}
 address@hidden: Fontsize address@hidden pt}%
   address@hidden: Magnification \number\mag}\fi
-  address@hidden \else
+  address@hidden
+    address@hidden \else
+      % FIXME: The message should not be emitted if XeTeX does not produce
+      % PDF.  There does not seem to be a primitive for that, though.
+      \typeout{Preview: PDFoutput 1}%
+    \fi
+  \else
     \ifx\pdfoutput\relax \else
       \ifnum\pdfoutput>\z@
         \typeout{Preview: PDFoutput 1}%
@@ -1527,11 +1543,15 @@
 % out to the console.
 %    \begin{macrocode}
 %<tightpage>address@hidden@
-%<tightpage>  \ifcase address@hidden address@hidden
+%<tightpage>  \ifcase
+%<tightpage>    address@hidden
+%<tightpage>      address@hidden address@hidden
 %<tightpage>    \ifx\pdfoutput\relax address@hidden
-%<tightpage>    \ifnum\pdfoutput>\z@ address@hidden address@hidden \or
-%<tightpage>    \ExecuteOptions{dvips}\relax \or
-%<tightpage>    \ExecuteOptions{pdftex}\relax\fi\fi
+%<tightpage>      \ifnum\pdfoutput>\z@ address@hidden address@hidden
+%<tightpage>    \else \thr@@\fi
+%<tightpage>  \or \ExecuteOptions{dvips}\relax
+%<tightpage>  \or \ExecuteOptions{pdftex}\relax
+%<tightpage>  \or \ExecuteOptions{xetex}\relax\fi\fi
 %<tightpage>address@hidden@empty
 %<tightpage>address@hidden@address@hidden@end{\begingroup
 %<tightpage>  address@hidden
@@ -1571,6 +1591,28 @@
 %<tightpage>    address@hidden@address@hidden
 %<tightpage>    \global\pdfpagewidth\dimen@
 %<tightpage>    address@hidden@i}}
+%<tightpage>\or
+%<tightpage>  address@hidden@address@hidden@address@hidden@box
+%<tightpage>    \ifdim\dimen@<\z@ address@hidden@\fi
+%<tightpage>    address@hidden@address@hidden
+%<tightpage>    address@hidden@
+%<tightpage>    \voffset=-1in
+%<tightpage>    \advance\voffset\dimen@
+%<tightpage>    address@hidden
+%<tightpage>    address@hidden@box
+%<tightpage>    \ifdim\dimen@<\z@ address@hidden@\fi
+%<tightpage>    address@hidden@address@hidden
+%<tightpage>    address@hidden@ii
+%<tightpage>    \global\pdfpageheight\dimen@
+%<tightpage>    \global\paperheight\dimen@
+%<tightpage>    address@hidden@box
+%<tightpage>    \ifdim\dimen@<\z@ address@hidden@\fi
+%<tightpage>    address@hidden@address@hidden
+%<tightpage>    address@hidden@address@hidden
+%<tightpage>    \global\pdfpagewidth\dimen@
+%<tightpage>    \hoffset=-1in
+%<tightpage>    address@hidden@i
+%<tightpage>    address@hidden@address@hidden
 %<tightpage>\fi
 %    \end{macrocode}
 % Ok, here comes the beef.  First we fish the 7~numbers from the file




reply via email to

[Prev in Thread] Current Thread [Next in Thread]