[XeTeX] subfig, TikZ, XeLatex and Left-To-Right

Vafa Khalighi vafakh84 at gmail.com
Thu May 6 11:12:00 CEST 2010


put this before \begin{document}:

\makeatletter
\long\def\sf@@@subfloat#1[#2][#3]#4{%
    \@ifundefined{FBsc at max}{}%
        {\FB at readaux{\let\FBsuboheight\relax}}%
    \@tempcnta=\@ne
    \if at minipage
      \@tempcnta=\z@
    \else\ifdim \lastskip=\z@ \else
      \@tempcnta=\tw@
    \fi\fi
    \ifmaincaptiontop
      \sf at top=\sf at nearskip
      \sf at bottom=\sf at farskip
    \else
      \sf at top=\sf at farskip
      \sf at bottom=\sf at nearskip
    \fi
    \leavevmode
    \setbox\@tempboxa \hbox{\beginL#4\endL}%
    \@tempdima=\wd\@tempboxa
    \@ifundefined{FBsc at max}{}%
        {\global\advance\Xhsize-\wd\@tempboxa
         \dimen@=\ht\@tempboxa
         \advance\dimen@\dp\@tempboxa
         \ifdim\dimen@>\FBso at max
           \global\FBso at max\dimen@
         \fi}%
    \vtop\bgroup
      \vbox\bgroup
        \ifcase\@tempcnta
          \@minipagefalse
        \or
          \vskip\sf at top
        \or
          \ifdim \lastskip=\z@ \else
            \@tempskipb\sf at top\relax\@xaddvskip
          \fi
        \fi
        \sf at ifpositiontop{%
          \ifx \@empty#3\relax \else
            \sf at subcaption{#1}{#2}{#3}%
            \vskip\sf at capskip
            \vskip\sf at captopadj
          \fi\egroup
          \hrule width0pt height0pt depth0pt
          \box\@tempboxa
        }{%
        \@ifundefined{FBsc at max}%
            {\box\@tempboxa}%
            {\ifx\FBsuboheight\relax
               \box\@tempboxa
             \else
               \vbox to \FBsuboheight{\FBafil\box\@tempboxa\FBbfil}%
             \fi}%
          \egroup
          \ifx \@empty#3\relax \else
            \vskip\sf at capskip
            \hrule width0pt height0pt depth0pt
            \sf at subcaption{#1}{#2}{#3}%
         \fi
        }%
      \vskip\sf at bottom
    \egroup
    \@ifundefined{FBsc at max}{}%
        {\addtocounter{FRobj}{-1}%
         \ifnum\c at FRobj=0\else
           \subfloatrowsep
         \fi}%
    \ifmaincaptiontop\else
      \global\advance\@nameuse{c@\@captype}\m at ne
    \fi
  \endgroup\ignorespaces}
\makeatother


-- 
Best wishes,
Vafa Khalighi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/xetex/attachments/20100506/7c7291eb/attachment.html>


More information about the XeTeX mailing list