Footnote rule in r2l alignment

Wolfgang Schuster <[email protected]> Wed, 1 Jul 2026 19:37:37 +0200
Newsgroups gmane.comp.tex.context
Message-ID <[email protected]>
Hi,

the "rule=paragraph" option for footnotes is broken, adding \noindent 
before the box placement fixes the alignment for r2l paragraphs.


The problem was noted on stackexchange: 
https://tex.stackexchange.com/questions/764325/footnote-rule-in-r2l-document


\unprotect

% strc-not.mklx

\permanent\protected\def\placenoterule
   {\begingroup
    \currentnoterulealign
  % \begingroup
  % \resetgridsnapping
  % \gridsnappingfalse
  % \strc_notes_set_bodyfont
    \setbox\scratchbox\hpack\bgroup
      \currentnoterulecommand
    \egroup
    \ifzeropt\htdp\scratchbox\else
-    \box\scratchbox\par
+    \noindent\box\scratchbox\par
      \ifvmode
        \vkern{\noteparameter\c!ruledistance}%
      \fi
      \par
    \fi
  % \endgroup
    \endgroup}

\protect

\setupfootnotes[rule=paragraph]

\showmakeup

\starttext

\righttoleft

\input knuth\footnote{\input ward}

\stoptext


Wolfgang

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : [email protected] / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________