![](https://secure.gravatar.com/avatar/7325514c8a7b377b86d86ad29d35e8ef.jpg?s=120&d=mm&r=g)
On Mon, Aug 08, 2011 at 04:57:19PM +0200, Wolfgang Schuster wrote:
Am 06.08.2011 um 22:05 schrieb Khaled Hosny:
There are two issues with right-to-left fontnotes, 1) the footnote number gets somewhere in the middle of the footnote text instead of being in the right margin 2) the footnote rule is left aligned:
\setupalign[r2l] \starttext Text\footnote{Note} \stoptext
strc-not.mkiv:
\def\letcurrentnoterulecommand{\expandafter\let\csname\??vn\c!rule:c:\currentnote\endcsname} +\def\letcurrentnoterulealign {\expandafter\let\csname\??vn\c!rule:a:\currentnote\endcsname}
\appendtoks \letvalue{\??vn\c!rule:c:\currentnote}\currentnoterulecommandnormal \letvalue{\??vn\c!rule:a:\currentnote}\lefttoright \to \everysetupnote
\appendtoks - \processallactionsinset[\noteparameter\c!rule] + \normalexpanded{\noexpand\processallactionsinset[\noteparameter\c!rule]} [ \v!on=>\letcurrentnoterulecommand\currentnoterulecommandnormal, \v!normal=>\letcurrentnoterulecommand\currentnoterulecommandnormal, - \v!left=>\letcurrentnoterulecommand\lefttoright, - \v!right=>\letcurrentnoterulecommand\righttoleft, + \v!left=>\letcurrentnoterulealign \lefttoright, + \v!right=>\letcurrentnoterulealign \righttoleft, \v!off=>\letcurrentnoterulecommand\relax, \s!default=>\letcurrentnoterulecommand\relax, \s!unknown=>\letcurrentnoterulecommand\currentnoterulecommandunknown]% \to \everysetupnote
Example:
\setupalign[r2l] \setupnote[footnote][rule={on,right}] \setupnotedefinition[footnote][location=left,command={\smash[w]}] % !!! \starttext \showframe Text\footnote{Note} \stoptext
Thanks Wolfgang! I understand that the patch fixes rule=right (that I tried earlier and didn't work), but I don't understand what \setupnotedefinition is doing (I'm trying to incorporate this in my bidi module so I need to have some understanding of what is happening) To Hans, besides applying this patch, shouldn't "rule=right" be the default in r2l mode? Regards, Khaled -- Khaled Hosny Egyptian Arab