Skip to content

Commit 683e64e

Browse files
committed
Fix #8838 by forcing horizontal mode before inserting the penalty
1 parent 61af7f4 commit 683e64e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sphinx/texinputs/sphinx.sty

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@
417417
\DisableKeyvalOption{sphinx}{mathnumfig}
418418
% To allow hyphenation of first word in narrow contexts; no option,
419419
% customization to be done via 'preamble' key
420-
\newcommand*\sphinxAtStartPar{\hskip\z@skip}
420+
\newcommand*\sphinxAtStartPar{\leavevmode\nobreak\hskip\z@skip}
421421
% No need for the \hspace{0pt} trick (\hskip\z@skip) with luatex
422422
\ifdefined\directlua\let\sphinxAtStartPar\@empty\fi
423423
% user interface: options can be changed midway in a document!

0 commit comments

Comments
 (0)