Skip to content

Instantly share code, notes, and snippets.

@zr-tex8r
Created May 15, 2012 16:13
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zr-tex8r/2702969 to your computer and use it in GitHub Desktop.
Save zr-tex8r/2702969 to your computer and use it in GitHub Desktop.
A package to make everyshi compatible with tate-mode of pTeX.
% pxeveryshi.sty
\NeedsTeXFormat{pLaTeX2e}
\ProvidesPackage{pxeveryshi}
\RequirePackageWithOptions{everyshi}
%
\def\@EveryShipout@Output{%
\setbox8\vbox{%
\yoko
\@EveryShipout@Hook
\@EveryShipout@AtNextHook
\global\setbox\@cclv=\box\@cclv
}%
\gdef\@EveryShipout@AtNextHook{}%
\@EveryShipout@Org@Shipout\box\@cclv
}
%% EOF
% Example: use TikZ in tate-mode
% http://oku.edu.mie-u.ac.jp/~okumura/texfaq/qa/56760.html
\documentclass{tarticle}
\usepackage[dvipdfmx]{graphicx}
\usepackage{tikz}
\usepackage{pxeveryshi}
\begin{document}
\begin{tikzpicture}
\draw (0,0) -- (1,2);
\end{tikzpicture}
\end{document}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment