From 699497fbcb6cd7a3b9762268401bb69e1b0664df Mon Sep 17 00:00:00 2001 From: Hironori Kitagawa Date: Sun, 26 Feb 2023 06:25:07 +0900 Subject: [PATCH] platex/#95 --- src/patches/lltjcore.sty | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/patches/lltjcore.sty b/src/patches/lltjcore.sty index af49aef..470a8f9 100644 --- a/src/patches/lltjcore.sty +++ b/src/patches/lltjcore.sty @@ -201,6 +201,20 @@ \patchcmd\@outputpage{\reset@font}{\@tombowreset@@paper\reset@font}{}{} \patchcmd\@outputpage{\@begindvi}{\@begindvi\@outputtombow}{}{} +% +\pretocmd\@floatboxreset{\pltx@save@float@dir}{}{} +\patchcmd\@endfloatbox{\outer@nobreak}{\outer@nobreak\pltx@check@float@dir}{}{} +\def\pltx@save@float@dir{% + \edef\pltx@float@dir@first{\ltjgetparameter{direction}}} +\def\pltx@check@float@dir{% + \ifx\pltx@float@dir@first\@undefined\else + \ifnum\ltjgetparameter{direction}=\pltx@float@dir@first\else + \pltx@err@float@dir + \fi + \fi} +\def\pltx@err@float@dir{% + \@latex@error{Direction change inside float!?\MessageBreak + Use \noexpand\layoutcaption provided in \string\usepackage{lltjext}}\@ehc} %%% Remove extra xkanjiskip \renewcommand\@makefnmark{% \unless\ifnum\ltjgetparameter{direction}=3 -- 2.11.0