Skip to content

Commit d1b4a75

Browse files
committed
LaTeX: fix another incompatibility with old pict2e LaTeX
We need to make sure the \put command arguments will expand to a (fractional) number, so \strip@pt is added, and the \dimexpr properly closed with \relax
1 parent faccc21 commit d1b4a75

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

sphinx/texinputs/sphinxpackageboxes.sty

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -362,16 +362,16 @@
362362
\dimexpr\dp\spx@tempboxa+\spx@boxes@padding@bottom+\spx@boxes@border\relax
363363
\hbox{%
364364
\begin{picture}%
365-
% \strip@pt\dimexpr fot work around "old" LaTeX picture limitation
365+
% \strip@pt\dimexpr to work around "old" LaTeX picture limitation
366366
% (we could use the "picture" package, this would add another dependency)
367-
(\strip@pt\wd\spx@tempboxa,\strip@pt\dimexpr\ht\spx@tempboxa+\dp\spx@tempboxa)%
368-
(\strip@pt\dimexpr-.5\spx@boxes@border,\strip@pt\dimexpr-.5\spx@boxes@border)%
367+
(\strip@pt\wd\spx@tempboxa,\strip@pt\dimexpr\ht\spx@tempboxa+\dp\spx@tempboxa\relax)%
368+
(\strip@pt\dimexpr-.5\spx@boxes@border\relax,\strip@pt\dimexpr-.5\spx@boxes@border\relax)%
369369
\ifspx@boxes@withshadow
370370
\color{spx@boxes@shadowcolor}%
371-
\put(\dimexpr\ifdim\spx@boxes@shadow@xoffset<\z@-\fi
372-
0.5\spx@boxes@border+\spx@boxes@shadow@xoffset,%
373-
\dimexpr\ifdim\spx@boxes@shadow@yoffset<\z@\else-\fi
374-
0.5\spx@boxes@border-\spx@boxes@shadow@yoffset)
371+
\put(\strip@pt\dimexpr\ifdim\spx@boxes@shadow@xoffset<\z@-\fi
372+
0.5\spx@boxes@border+\spx@boxes@shadow@xoffset\relax,%
373+
\strip@pt\dimexpr\ifdim\spx@boxes@shadow@yoffset<\z@\else-\fi
374+
0.5\spx@boxes@border-\spx@boxes@shadow@yoffset\relax)
375375
{\spx@boxes@borderpath\fillpath}%
376376
{\ifspx@boxes@withbackgroundcolor\else
377377
\color{white}% or rather try to use page color?

0 commit comments

Comments
 (0)