diff options
Diffstat (limited to 'Master')
-rw-r--r-- | Master/texmf-dist/doc/latex/sidenotesplus/README.txt | 7 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/sidenotesplus/sidenotesplus.pdf | bin | 212629 -> 213799 bytes | |||
-rw-r--r-- | Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.dtx | 51 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.ins | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/sidenotesplus/sidenotesplus.sty | 38 |
5 files changed, 57 insertions, 41 deletions
diff --git a/Master/texmf-dist/doc/latex/sidenotesplus/README.txt b/Master/texmf-dist/doc/latex/sidenotesplus/README.txt index da9f6a4532c..e602b7cd34e 100644 --- a/Master/texmf-dist/doc/latex/sidenotesplus/README.txt +++ b/Master/texmf-dist/doc/latex/sidenotesplus/README.txt @@ -2,7 +2,7 @@ LaTeX package sidenotesplus Copyright (c) Anton Vrba, 2022 ------------------------------------------------------------------- Version: - 2022/05/20 1.00 Initial release + 2022/05/31 1.01 Licence: This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, version 1.3c of the license. @@ -15,4 +15,7 @@ Abstract: Also body text can be extended into the margin for wide figures, tables and equation. Twoside symmetry is preserved. For biblatex users, routines for side references are provided. --------------------------------------------------------------------
\ No newline at end of file +------------------------------------------------------------------- + +Previous Versions: + 2022/05/15 1.00 Initial release diff --git a/Master/texmf-dist/doc/latex/sidenotesplus/sidenotesplus.pdf b/Master/texmf-dist/doc/latex/sidenotesplus/sidenotesplus.pdf Binary files differindex b51643d66ee..5237810fea0 100644 --- a/Master/texmf-dist/doc/latex/sidenotesplus/sidenotesplus.pdf +++ b/Master/texmf-dist/doc/latex/sidenotesplus/sidenotesplus.pdf diff --git a/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.dtx b/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.dtx index bc84aa424f2..b6c51d20d25 100644 --- a/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.dtx +++ b/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.dtx @@ -36,7 +36,7 @@ %<package>\NeedsTeXFormat{LaTeX2e}[2020/10/01] %<package>\ProvidesPackage{sidenotesplus} %<*package> - [2022/05/20 1.00 rich text marginal notes, tables and figures ] + [2022/05/31 v1.01 rich text marginal notes, tables and figures ] %</package> %<package>\RequirePackage{marginnote} % provides an offset option for the marginals instead of a float %<package>\RequirePackage{caption} % handles the captions (in the margin) @@ -94,7 +94,8 @@ % % \maketitle % -% \changes{1.0}{2022/05/15}{Initial Release} +% \changes{v1.0}{2022/05/15}{Initial Release} +% \changes{v1.01}{2022/05/31}{Environment text* improved} % % \begin{abstract} % \noindent A package to manage the margin notes, figures, tables and captions. @@ -1146,10 +1147,15 @@ } % \end{macrocode} % +% +% % \begin{environment}{text*} % -- % +% \changes{v1.01}{2022/5/31}{added newsavebox and minipage} +% % \begin{macrocode} +\newsavebox{\b@snp@textbox} \NewDocumentEnvironment{text*}{ o }% { % begin part \begin{adjustwidth}{0pt}{0pt} @@ -1157,25 +1163,30 @@ { \if@twoside \snp@isoddpage{\begin{adjustwidth}{0pt}{-\d@snp@extrawidth}}% - {\begin{adjustwidth}{-\d@snp@extrawidth*}{0pt}} + {\begin{adjustwidth}{-\d@snp@extrawidth}{0pt}} \else - \begin{adjustwidth}{0pt}{-\d@snp@extrawidth*} + \begin{adjustwidth}{0pt}{-\d@snp@extrawidth} \fi } { \if@twoside - \snp@isoddpage{\begin{adjustwidth}{0pt}{-\d@snp@extrawidth*#1}}% - {\begin{adjustwidth}{-\d@snp@extrawidth*#1}{0pt}} + \snp@isoddpage{\begin{adjustwidth}{0pt}{-#1\d@snp@extrawidth}}% + {\begin{adjustwidth}{-#1\d@snp@extrawidth}{0pt}} \else - \begin{adjustwidth}{0pt}{-\d@snp@extrawidth*#1} + \begin{adjustwidth}{0pt}{-#1\d@snp@extrawidth} \fi } + \begin{lrbox}{\b@snp@textbox} + \begin{minipage}[]{\linewidth+1ex} } % \end{macrocode} % \end{environment} % % \begin{macrocode} { % end part +\end{minipage} +\end{lrbox} +\usebox{\b@snp@textbox} \end{adjustwidth}\end{adjustwidth} \snp@placemarginal{}{} } % \end{macrocode} @@ -1269,31 +1280,29 @@ % %% % \begin{macrocode} -\newlength\marginparsepodd -\newlength\marginparsepeven +\newlength\snp@marginparsepodd +\newlength\snp@marginparsepeven -\setlength{\marginparsepodd}{\marginparsep} -\setlength{\marginparsepeven}{\marginparsep-\snp@marginsepdiff} + +\setlength{\snp@marginparsepodd}{\marginparsep} +\setlength{\snp@marginparsepeven}{\marginparsep-\snp@marginsepdiff} \makeatletter -% First we patch \@addmarginpar -% The \patchcmd command does a search and replace. \patchcmd{\@addmarginpar} % In this command {\mph@orig@addmarginpar} % ... replace this... {\if@twoside\ifodd\c@page\relax % ... with this - \marginparsep=\marginparsepodd % Page is odd + \marginparsep=\snp@marginparsepodd % Page is odd \else - \marginparsep=\marginparsepeven % Page is even + \marginparsep=\snp@marginparsepeven % Page is even \fi \else - \marginparsep=\marginparsepodd + \marginparsep=\snp@marginparsepodd \fi \mph@orig@addmarginpar} {} % success {\message{Error! Couldn't hook into command % failure `\string\@addmarginpar'}} -% Now we patch \@mn@@@marginnote {%% Group to keep patching commands local % % Here we use a little trick to repeatedly patch the \@mn@@@marginnote @@ -1312,12 +1321,12 @@ {\kern\marginparsep} % ... replace this... {\ifx\@mn@currpage\relax\else % ... with this \if@twoside\ifodd\@mn@currpage\relax - \kern\marginparsepodd + \kern\snp@marginparsepodd \else - \kern\marginparsepeven + \kern\snp@marginparsepeven \fi \else - \kern\marginparsepodd + \kern\snp@marginparsepodd \fi \fi} {\message{Patched!}\patchok} % success (recurse) @@ -1330,8 +1339,6 @@ \makeatother \endinput % \end{macrocode} - - % % \iffalse %</package> diff --git a/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.ins b/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.ins index 33697cfce26..dbcf54724f6 100644 --- a/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.ins +++ b/Master/texmf-dist/source/latex/sidenotesplus/sidenotesplus.ins @@ -21,7 +21,7 @@ \input docstrip.tex \keepsilent - +\askforoverwritefalse \preamble diff --git a/Master/texmf-dist/tex/latex/sidenotesplus/sidenotesplus.sty b/Master/texmf-dist/tex/latex/sidenotesplus/sidenotesplus.sty index 7785fa98173..c2573aab68c 100644 --- a/Master/texmf-dist/tex/latex/sidenotesplus/sidenotesplus.sty +++ b/Master/texmf-dist/tex/latex/sidenotesplus/sidenotesplus.sty @@ -25,7 +25,7 @@ %% \NeedsTeXFormat{LaTeX2e}[2020/10/01] \ProvidesPackage{sidenotesplus} - [2022/05/20 1.00 rich text marginal notes, tables and figures ] + [2022/05/31 v1.01 rich text marginal notes, tables and figures ] \RequirePackage{marginnote} % provides an offset option for the marginals instead of a float \RequirePackage{caption} % handles the captions (in the margin) \RequirePackage{xparse} % new LaTeX3 syntax to define macros and environments @@ -578,6 +578,7 @@ { % end part \end{adjustwidth}\end{adjustwidth} } +\newsavebox{\b@snp@textbox} \NewDocumentEnvironment{text*}{ o }% { % begin part \begin{adjustwidth}{0pt}{0pt} @@ -585,21 +586,26 @@ { \if@twoside \snp@isoddpage{\begin{adjustwidth}{0pt}{-\d@snp@extrawidth}}% - {\begin{adjustwidth}{-\d@snp@extrawidth*}{0pt}} + {\begin{adjustwidth}{-\d@snp@extrawidth}{0pt}} \else - \begin{adjustwidth}{0pt}{-\d@snp@extrawidth*} + \begin{adjustwidth}{0pt}{-\d@snp@extrawidth} \fi } { \if@twoside - \snp@isoddpage{\begin{adjustwidth}{0pt}{-\d@snp@extrawidth*#1}}% - {\begin{adjustwidth}{-\d@snp@extrawidth*#1}{0pt}} + \snp@isoddpage{\begin{adjustwidth}{0pt}{-#1\d@snp@extrawidth}}% + {\begin{adjustwidth}{-#1\d@snp@extrawidth}{0pt}} \else - \begin{adjustwidth}{0pt}{-\d@snp@extrawidth*#1} + \begin{adjustwidth}{0pt}{-#1\d@snp@extrawidth} \fi } + \begin{lrbox}{\b@snp@textbox} + \begin{minipage}[]{\linewidth+1ex} } { % end part +\end{minipage} +\end{lrbox} +\usebox{\b@snp@textbox} \end{adjustwidth}\end{adjustwidth} \snp@placemarginal{}{} } \RenewDocumentEnvironment{figure*}{ O{htbp} } @@ -662,22 +668,22 @@ } \ExplSyntaxOff %% -\newlength\marginparsepodd -\newlength\marginparsepeven +\newlength\snp@marginparsepodd +\newlength\snp@marginparsepeven -\setlength{\marginparsepodd}{\marginparsep} -\setlength{\marginparsepeven}{\marginparsep-\snp@marginsepdiff} +\setlength{\snp@marginparsepodd}{\marginparsep} +\setlength{\snp@marginparsepeven}{\marginparsep-\snp@marginsepdiff} \makeatletter \patchcmd{\@addmarginpar} % In this command {\mph@orig@addmarginpar} % ... replace this... {\if@twoside\ifodd\c@page\relax % ... with this - \marginparsep=\marginparsepodd % Page is odd + \marginparsep=\snp@marginparsepodd % Page is odd \else - \marginparsep=\marginparsepeven % Page is even + \marginparsep=\snp@marginparsepeven % Page is even \fi \else - \marginparsep=\marginparsepodd + \marginparsep=\snp@marginparsepodd \fi \mph@orig@addmarginpar} {} % success @@ -702,12 +708,12 @@ {\kern\marginparsep} % ... replace this... {\ifx\@mn@currpage\relax\else % ... with this \if@twoside\ifodd\@mn@currpage\relax - \kern\marginparsepodd + \kern\snp@marginparsepodd \else - \kern\marginparsepeven + \kern\snp@marginparsepeven \fi \else - \kern\marginparsepodd + \kern\snp@marginparsepodd \fi \fi} {\message{Patched!}\patchok} % success (recurse) |