summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-10-05 20:49:26 +0000
committerKarl Berry <karl@freefriends.org>2019-10-05 20:49:26 +0000
commit0d7300d2d29beeb321cdfd89a3af6e605b5bdbcf (patch)
tree436ce069414dc856ca7a995e4e477a2167184aef /Master
parent7231d49bcafc5733408aa9592f44bfe5a35c10e2 (diff)
tikzmark
git-svn-id: svn://tug.org/texlive/trunk@52293 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/tikzmark/tikzmark.pdfbin461039 -> 419430 bytes
-rw-r--r--Master/texmf-dist/source/latex/tikzmark/tikzmark.dtx50
-rw-r--r--Master/texmf-dist/tex/latex/tikzmark/tikzlibrarytikzmark.code.tex21
3 files changed, 50 insertions, 21 deletions
diff --git a/Master/texmf-dist/doc/latex/tikzmark/tikzmark.pdf b/Master/texmf-dist/doc/latex/tikzmark/tikzmark.pdf
index c97ed9a71ba..0b8d460f3e5 100644
--- a/Master/texmf-dist/doc/latex/tikzmark/tikzmark.pdf
+++ b/Master/texmf-dist/doc/latex/tikzmark/tikzmark.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/tikzmark/tikzmark.dtx b/Master/texmf-dist/source/latex/tikzmark/tikzmark.dtx
index 2cdf663e410..4dfaeb6e78d 100644
--- a/Master/texmf-dist/source/latex/tikzmark/tikzmark.dtx
+++ b/Master/texmf-dist/source/latex/tikzmark/tikzmark.dtx
@@ -99,8 +99,15 @@ and the derived files tikzmark.ins,
\usepackage{listings}
\lstloadlanguages{[LaTeX]TeX}
-\lstset{gobble=2,breakatwhitespace=true,breaklines=true,language=TeX}
-
+ \lstset{
+ gobble=2,
+ breakatwhitespace=true,
+ breaklines=true,
+ language=[LaTeX]TeX,
+ basicstyle=\small\ttfamily,
+ keepspaces=true,
+ columns=fullflexible
+}
\usepackage{fancyvrb}
\usepackage[hyperindex=false]{hyperref}
@@ -112,8 +119,7 @@ and the derived files tikzmark.ins,
\begin{center}
% \setlength{\parindent}{0pt}
\fbox{\begin{minipage}{.9\linewidth}
- \lstset{breakatwhitespace=true,breaklines=true,language=TeX,basicstyle=\small}
- \lstinputlisting[]{example.out}
+ \lstinputlisting{example.out}
\end{minipage}}
\fbox{\begin{minipage}{.9\linewidth}
@@ -129,8 +135,7 @@ and the derived files tikzmark.ins,
\begin{center}
% \setlength{\parindent}{0pt}
\fbox{\begin{minipage}{.9\linewidth}
- \lstset{breakatwhitespace=true,breaklines=true,language=TeX,basicstyle=\small}
- \lstinputlisting[]{example.out}
+ \lstinputlisting{example.out}
\end{minipage}}
\end{center}
}
@@ -201,7 +206,7 @@ and the derived files tikzmark.ins,
%</driver>
% \fi
%
-% \CheckSum{1119}
+% \CheckSum{1138}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -228,13 +233,14 @@ and the derived files tikzmark.ins,
% \changes{1.5}{2018/09/09}{Reintroduced the original command (now as tikzmarknode) with a mathchoice hack for different math modes}
% \changes{1.6}{2018/10/18}{Added the ability to save node information between runs and between TeX documents}
% \changes{1.7}{2019/05/07}{Added conditions to test if a tikzmark is on a particular page}
+% \changes{1.8}{2019/10/04}{Fixed some bugs with subnode and tikzmarknode inside maths}
%
% \DoNotIndex{\newcommand,\newenvironment}
%
% \providecommand*{\url}{\texttt}
% \title{The \textsf{tikzmark} package}
% \author{Andrew Stacey \\ \url{loopspace@mathforge.org}}
-% \date{v1.7~from 2019/05/07}
+% \date{v1.8~from 2019/10/04}
%
%
% \maketitle
@@ -342,7 +348,7 @@ and the derived files tikzmark.ins,
%
% \begin{figure}
% \centering
-% \includegraphics{tikzmarkExample}
+% \IfFileExists{tikzmarkExample.pdf}{\includegraphics{tikzmarkExample}}{}
% \caption{First use of tikzmark}
% \label{fig:tikzmarkex}
% \end{figure}
@@ -467,6 +473,8 @@ and the derived files tikzmark.ins,
% Possible values are (by default) \Verb+above+, \Verb+below+, \Verb+left+, \Verb+right+, and \Verb+ignore+.
% (The last one sets the vector to the zero vector.)
%
+% Previous versions of \Verb+tikzmark+ tried to make this work correctly with the mark being on, say, \(5\) pages further on but this got too fiddly so this version just pretends that the mark is on the next or previous page and points to it as appropriate.
+%
% \item \Verb+/tikz/tikzmark prefix=<prefix>+ and \Verb+/tikz/tikzmark suffix=<suffix>+
%
% These keys allow for the automatic addition of a prefix and/or suffix to each \Verb+\tikzmark+ name.
@@ -690,7 +698,7 @@ and the derived files tikzmark.ins,
% This produces:
%
% \begin{center}
-% \fbox{\includegraphics{tikzrefextnodes}}
+% \fbox{\IfFileExists{tikzrefextnodes.pdf}{\includegraphics{tikzrefextnodes}}{}}
% \end{center}
%
% \subsection{Code Listings}
@@ -962,10 +970,14 @@ and the derived files tikzmark.ins,
\@ifundefined{save@pg@\pgfpictureid}{}{%
\pgfkeysvalueof{/tikz/next page vector}%
\edef\tmk@pg{\the\numexpr \csname save@pg@\csname save@pt@\tmk@label\endcsname\endcsname - \csname save@pg@\pgfpictureid\endcsname\relax}%
- \advance \pgf@xa by %
- \tmk@pg\pgf@x\relax
- \advance \pgf@ya by %
- \tmk@pg\pgf@y\relax
+ \ifnum \tmk@pg > 0 \relax
+ \advance \pgf@xa by \pgf@x\relax
+ \advance \pgf@ya by \pgf@y\relax
+ \fi
+ \ifnum \tmk@pg < 0 \relax
+ \advance \pgf@xa by -\pgf@x\relax
+ \advance \pgf@ya by -\pgf@y\relax
+ \fi
}%
}%
\pgf@x=\pgf@xa
@@ -1206,7 +1218,10 @@ and the derived files tikzmark.ins,
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
\edef\tzmk@pic{\tzmk@prfx\the\numexpr\the\pgf@picture@serial@count-3\relax}%
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
-% \pgfnodealias{#2}{#2-t}% %% Fallback
+ \pgfutil@ifundefined{pgf@sh@ns@#2}{%
+ \pgfnodealias{#2}{#2-t}%
+ \tikzmarkalias{#2}{#2-t}%
+ }{}%
\else
\pgfnodealias{#2}{#2-d}%
\tikzmarkalias{#2}{#2-d}%
@@ -1275,7 +1290,10 @@ and the derived files tikzmark.ins,
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
\edef\tzmk@pic{\tzmk@prfx\the\numexpr\the\pgf@picture@serial@count-3\relax}%
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
- % No fallback due to potential nested mathchoices
+ \pgfutil@ifundefined{pgf@sh@ns@#2}{%
+ \pgfnodealias{#2}{#2-t}%
+ \tikzmarkalias{#2}{#2-t}%
+ }{}%
\else
\pgfnodealias{#2}{#2-d}%
\tikzmarkalias{#2}{#2-d}%
diff --git a/Master/texmf-dist/tex/latex/tikzmark/tikzlibrarytikzmark.code.tex b/Master/texmf-dist/tex/latex/tikzmark/tikzlibrarytikzmark.code.tex
index c39d9a82746..725b58f571b 100644
--- a/Master/texmf-dist/tex/latex/tikzmark/tikzlibrarytikzmark.code.tex
+++ b/Master/texmf-dist/tex/latex/tikzmark/tikzlibrarytikzmark.code.tex
@@ -144,10 +144,14 @@
\@ifundefined{save@pg@\pgfpictureid}{}{%
\pgfkeysvalueof{/tikz/next page vector}%
\edef\tmk@pg{\the\numexpr \csname save@pg@\csname save@pt@\tmk@label\endcsname\endcsname - \csname save@pg@\pgfpictureid\endcsname\relax}%
- \advance \pgf@xa by %
- \tmk@pg\pgf@x\relax
- \advance \pgf@ya by %
- \tmk@pg\pgf@y\relax
+ \ifnum \tmk@pg > 0 \relax
+ \advance \pgf@xa by \pgf@x\relax
+ \advance \pgf@ya by \pgf@y\relax
+ \fi
+ \ifnum \tmk@pg < 0 \relax
+ \advance \pgf@xa by -\pgf@x\relax
+ \advance \pgf@ya by -\pgf@y\relax
+ \fi
}%
}%
\pgf@x=\pgf@xa
@@ -326,6 +330,10 @@
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
\edef\tzmk@pic{\tzmk@prfx\the\numexpr\the\pgf@picture@serial@count-3\relax}%
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
+ \pgfutil@ifundefined{pgf@sh@ns@#2}{%
+ \pgfnodealias{#2}{#2-t}%
+ \tikzmarkalias{#2}{#2-t}%
+ }{}%
\else
\pgfnodealias{#2}{#2-d}%
\tikzmarkalias{#2}{#2-d}%
@@ -386,7 +394,10 @@
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
\edef\tzmk@pic{\tzmk@prfx\the\numexpr\the\pgf@picture@serial@count-3\relax}%
\expandafter\ifx\csname\tzmk@pic\endcsname\relax
- % No fallback due to potential nested mathchoices
+ \pgfutil@ifundefined{pgf@sh@ns@#2}{%
+ \pgfnodealias{#2}{#2-t}%
+ \tikzmarkalias{#2}{#2-t}%
+ }{}%
\else
\pgfnodealias{#2}{#2-d}%
\tikzmarkalias{#2}{#2-d}%