summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/algpseudocodex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-04-17 19:56:14 +0000
committerKarl Berry <karl@freefriends.org>2023-04-17 19:56:14 +0000
commit8fe5055d95cdf4749ce6010ab87f031d5bf685d4 (patch)
treecd1a11697b512dc41bb3e08369f7c33b21e02e4a /Master/texmf-dist/tex/latex/algpseudocodex
parentba06b563f2152d04cd878dd177b787fbd560848a (diff)
algpseudocodex (17apr23)
git-svn-id: svn://tug.org/texlive/trunk@66869 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/algpseudocodex')
-rw-r--r--Master/texmf-dist/tex/latex/algpseudocodex/algpseudocodex.sty7
1 files changed, 6 insertions, 1 deletions
diff --git a/Master/texmf-dist/tex/latex/algpseudocodex/algpseudocodex.sty b/Master/texmf-dist/tex/latex/algpseudocodex/algpseudocodex.sty
index fc0b8d8aeff..1489d7ad85c 100644
--- a/Master/texmf-dist/tex/latex/algpseudocodex/algpseudocodex.sty
+++ b/Master/texmf-dist/tex/latex/algpseudocodex/algpseudocodex.sty
@@ -20,7 +20,7 @@
% Based on Szasz Janos' algpseudocode.sty
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{algpseudocodex}[2023-02-17 v1.1.0 pseudocode typesetting]
+\ProvidesPackage{algpseudocodex}[2023-04-16 v1.1.1 pseudocode typesetting]
\RequirePackage{kvoptions}
\RequirePackage{algorithmicx}
\RequirePackage{etoolbox}
@@ -88,6 +88,7 @@
\newlength{\algpx@oldPos}
\newlength{\algpx@newPos}
\newlength{\algpx@tmpLen}% length to be used for various things
+\newlength{\algpx@currentLineskip}% used to restore lineskip in varwidth
\newlength{\algpx@indStartY}
\newlength{\algpx@indEndY}
\newlength{\algpx@indStartX}% x coordinate of indent line
@@ -178,7 +179,9 @@
% create box from here to end of line, leaving space for #3
\settowidth{\algpx@extraShiftX}{#2}% remember that line actually starts further right than last box
\settowidth{\algpx@tmpLen}{#3}%
+ \setlength{\algpx@currentLineskip}{\lineskip}% remember value of lineskip
\begin{varwidth}[t]{\dimexpr \linewidth - \algpx@extraShiftX - \algpx@tmpLen - \algorithmicindent * \numexpr \value{ALG@nested} - 1 \relax \relax}%
+ \setlength{\lineskip}{\algpx@currentLineskip}% rstore lineskip value
}
% executed before \State, \If etc., i.e., at end of previous line
@@ -798,7 +801,9 @@
\algpx@setCodeBoxWest[\dimexpr \labelsep + \algpx@tmpLen \relax]%
\setbool{algpx@firstLine}{false}%
\setbool{algpx@executeEndVarwidth}{true}%
+ \setlength{\algpx@currentLineskip}{\lineskip}% remember value of lineskip
\begin{varwidth}[t]{\dimexpr \linewidth - \labelsep - \algpx@tmpLen + \leftmargin \relax}%
+ \setlength{\lineskip}{\algpx@currentLineskip}% rstore lineskip value
\settoheight{\algpx@tmpLen}{#1}%
\rule{0pt}{\algpx@tmpLen}%
}