summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2021-01-11 22:44:39 +0000
committerKarl Berry <karl@freefriends.org>2021-01-11 22:44:39 +0000
commit44f6214748806e7d082ab5dc18c2de04e393e536 (patch)
treec52281a875435a69f0350f1cd8627c4ea80b9cfa
parent1516b5dcbb347d2c41c1322b43b0e2ad35284431 (diff)
orientation (11jan21)
git-svn-id: svn://tug.org/texlive/trunk@57390 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/orientation/README33
-rw-r--r--Master/texmf-dist/tex/latex/orientation/orientation.sty15
-rwxr-xr-xMaster/tlpkg/bin/tlpkg-ctan-check3
-rw-r--r--Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc1
-rw-r--r--Master/tlpkg/tlpsrc/orientation.tlpsrc0
5 files changed, 51 insertions, 1 deletions
diff --git a/Master/texmf-dist/doc/latex/orientation/README b/Master/texmf-dist/doc/latex/orientation/README
new file mode 100644
index 00000000000..c9652c9cb4d
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/orientation/README
@@ -0,0 +1,33 @@
+orientation 1.0 (January 10, 2021)
+Set page orientation for dvips/Ghostscript
+Daniel Benjamin Miller <dbmiller@dbmiller.org>
+
+When using dvips with Ghostscript, the various PDF auto-rotation modes may
+sometimes need some tweaking. Using the auto-rotation feature of Ghostscript
+may suffice in most cases: it sets the orientation of the pages of the PDF
+according to text direction (either per-page or for the whole document).
+
+But sometimes we don't want this. For instance, Ghostscript may not obey
+the orientation set by geometry or other packages.
+
+We have eight commands available, in two categories.
+
+These commands orient the current page and all following pages:
+
+* \setportrait
+* \setlandscape
+* \setupsidedown
+* \setcounterlandscape
+
+These commands orient the current page only:
+
+* \thispageportrait
+* \thispagelandscape
+* \thispageupsidedown
+* \thispagecounterlandscape
+
+If you don't process your file with dvips and Ghostscript/ps2pdf, then don't
+expect any of these commands to do anything.
+
+Made available under the CC-Zero Dedication, 2021
+For more info: https://creativecommons.org/publicdomain/zero/1.0/
diff --git a/Master/texmf-dist/tex/latex/orientation/orientation.sty b/Master/texmf-dist/tex/latex/orientation/orientation.sty
new file mode 100644
index 00000000000..e5f47922ba6
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/orientation/orientation.sty
@@ -0,0 +1,15 @@
+\ProvidesPackage{orientation}[orientation 1.0]
+% orientation package by Daniel Benjamin Miller <dbmiller@dbmiller.org>
+% Made available under the CC-Zero Dedication, 2021
+% For more info: https://creativecommons.org/publicdomain/zero/1.0/
+\RequirePackage{everypage}
+\makeatletter
+\newcommand{\thispagelandscape}{\special{ps:[{ThisPage} <</Rotate 90>> /PUT pdfmark true}}
+\newcommand{\thispageupsidedown}{\special{ps:[{ThisPage} <</Rotate 180>> /PUT pdfmark true}}
+\newcommand{\thispagecounterlandscape}{\special{ps:[{ThisPage} <</Rotate 270>> /PUT pdfmark true}}
+\newcommand{\thispageportrait}{\special{ps:[{ThisPage} <</Rotate 0>> /PUT pdfmark true}}
+\newcommand{\setlandscape}{\AddEverypageHook{\special{ps:[{ThisPage} <</Rotate 90>> /PUT pdfmark true}}}
+\newcommand{\setcounterlandscape}{\AddEverypageHook{\special{ps:[{ThisPage} <</Rotate 270>> /PUT pdfmark true}}}
+\newcommand{\setupsidedown}{\AddEverypageHook{\special{ps:[{ThisPage} <</Rotate 180>> /PUT pdfmark true}}}
+\newcommand{\setportrait}{\AddEverypageHook{\special{ps:[{ThisPage} <</Rotate 0>> /PUT pdfmark true}}}
+\endinput \ No newline at end of file
diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check
index 2e2474bcd03..115ab00548a 100755
--- a/Master/tlpkg/bin/tlpkg-ctan-check
+++ b/Master/tlpkg/bin/tlpkg-ctan-check
@@ -551,7 +551,8 @@ my @TLP_working = qw(
oldstyle olsak-misc
onedown onlyamsmath onrannual opcit opensans oplotsymbl
opteng optex optidef optional options
- orcidlink ordinalpt orkhun oscola oswald ot-tableau othello othelloboard
+ orcidlink ordinalpt orientation orkhun
+ oscola oswald ot-tableau othello othelloboard
oubraces oup-authoring-template
outerhbox outline outliner outlines outlining
overlays overlock overpic
diff --git a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc
index 5551f8a304b..c913e69105d 100644
--- a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc
+++ b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc
@@ -884,6 +884,7 @@ depend optidef
depend optional
depend options
depend orcidlink
+depend orientation
depend outline
depend outliner
depend outlines
diff --git a/Master/tlpkg/tlpsrc/orientation.tlpsrc b/Master/tlpkg/tlpsrc/orientation.tlpsrc
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/Master/tlpkg/tlpsrc/orientation.tlpsrc