summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/hvextern/doc/hvextern.tex
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/hvextern/doc/hvextern.tex')
-rw-r--r--macros/latex/contrib/hvextern/doc/hvextern.tex39
1 files changed, 31 insertions, 8 deletions
diff --git a/macros/latex/contrib/hvextern/doc/hvextern.tex b/macros/latex/contrib/hvextern/doc/hvextern.tex
index d691aa3bed..ac218c986d 100644
--- a/macros/latex/contrib/hvextern/doc/hvextern.tex
+++ b/macros/latex/contrib/hvextern/doc/hvextern.tex
@@ -1,11 +1,14 @@
+%% $Id: hvextern.tex 559 2022-05-27 06:59:29Z herbert $
\RequirePackage{pdfmanagement-testphase}
\DeclareDocumentMetadata{}
-\documentclass[ngerman,a4paper]{article}
+\documentclass[ngerman,a4paper,twoside]{article}
\usepackage{babel}
\usepackage{libertinus}
\setmonofont[Scale=MatchLowercase,FakeStretch=0.88]{AnonymousPro}
\usepackage{iftex}
+\usepackage{fancyhdr}
+\pagestyle{fancy}
\usepackage{hvlogos}
\usepackage{hvextern}
\usepackage{hvindex}
@@ -41,7 +44,8 @@ from within a main\newline \LaTeX\ document~--v. \hvexternFileversion}
\begin{sloppypar}
-This package allows to write external \MP, \TeX, \ConTeXt, \LaTeX, \LuaTeX, \LuaLaTeX, \XeTeX, \XeLaTeX, Lua, Perl, Java and/or Python
+This package allows to write external \MP, \TeX, \ConTeXt, \LaTeX, \LuaTeX, \LuaLaTeX, \XeTeX, \XeLaTeX,
+\Index{Lua}, \Index{Perl}, \Index{Java} and/or \Index{Python}
source code, which will then be run via \texttt{shell escape} to create a PDF oder text output to include
it into the main \LaTeX\ document.
\end{sloppypar}
@@ -56,7 +60,9 @@ source code
...
\end{externalDocument}
-\runExtCmd[<options>]{<command with arguments>}{<external filename without extension>}
+\runExtCmd[<options>]
+ {<command with arguments>}
+ {<external filename without extension>}
\end{verbatim}
The main document \emph{must} be run with the \Loption{-shell-escape} option, otherwise it won't work, e.g.:
@@ -85,10 +91,21 @@ with \texttt{lualatex} with the \texttt{-\kern1pt-shell-escape} option.
\subsection{Without showing the code}
This document was run with \LuaLaTeX. Suppose you want to insert the output of a document
-which needs for several reasons a \pdfLaTeX\ run. Instead of created and running a document
+which needs for several reasons a \XeLaTeX\ run. Instead of created and running a document
outside of the main document and then to insert the output
we can do this from within this \LuaLaTeX\ document itself. The external document is compiled
-with \pdfLaTeX\ and the output is insert as pdf image. The \Index{source} code itself is not
+with \XeLaTeX\ and the output is insert as pdf image:
+\begin{externalDocument}[%
+ compiler=xelatex, inline, force, runs=2, grfOptions={height=8pt},%
+ crop, cropmargin=0, cleanup, docType=latex]{voss}
+\documentclass{ctexart}
+\pagestyle{empty}
+\begin{document}
+美好的一天.
+\end{document}
+\end{externalDocument}
+
+Another example which needs a \pdfLaTeX\ run. The \Index{source} code itself is also not
shown by the environment \Lenv{externalDocument}.
@@ -119,7 +136,7 @@ shown by the environment \Lenv{externalDocument}.
\end{minipage}
\begin{minipage}{.39\linewidth}
\begin{externalDocument}[
- compiler=pdflatex,force=false,cleanup={log,aux},verbose]{voss}
+ compiler=pdflatex,force=false,cleanup={log,aux},showFilename=false]{voss}
\documentclass{standalone}
%StartVisiblePreamble
\usepackage{fontenc}
@@ -1583,10 +1600,11 @@ This is the start of the introduction.
\begin{externalDocument}[
- grfOptions={width=0.3\linewidth},
- pages={1,2,3},
+ grfOptions={width=0.31\linewidth},
+ pages={1,2,3,4,5,6},
pagesep=2pt,
frame,
+ framesep=0pt,
verbose=false,
compiler=context,
showFilename,
@@ -1616,16 +1634,20 @@ This is the start of the introduction.
\chapter{Introduction}
\input knuth \input knuth
\chapter[rensselaer]{The Rensselaer family}
+\input knuth
\section{The first born}
\input knuth
\section{The early years}
... in those days Hasselt was ...
+\input knuth
\section{Living and workin in America}
\input knuth
\chapter[lansing]{The Lansing family}
... the Lansing family was also ...
+\input knuth
\chapter[cuyler]{The Cuyler family}
... much later Tydeman Cuyler ...
+\input knuth
\myhead[headlines]{And the end}
foo
\stoptext
@@ -1665,6 +1687,7 @@ already exists, there is no need to create it with the next run again and again.
\item[\Lkeyword{framesep}] Value for \Lcs{fbox} if keyword \texttt{frame} is used.
\item[\Lkeyword{mpsep}] Distance between code and output (default 1\,em).
\item[\Lkeyword{pagesep}] Distance between pages for multipage output (default 1\,em).
+\item[\Lkeyword{verbose}] Print control messages into the terminal and logfile.
\item[\Lkeyword{eps}] create an eps from the pdf (historical).
\end{description}