[XeTeX] bidi problem?

Vafa Khalighi vafakh84 at gmail.com
Tue Apr 13 05:55:37 CEST 2010


This response goes back to this post:
http://tug.org/mailman/htdig/xetex/2010-February/015985.html

The solution I provided, only works for normal text and does not work for
list (i.e. itemize). The following code seems to fix both:

 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\def\@iiiminipage#1#2[#3]#4{%

\leavevmode

\@pboxswfalse

\setlength\@tempdima{#4}%

\def\@mpargs{{#1}{#2}[#3]{#4}}%

\setbox\@tempboxa\hbox\bgroup\if at RTL\beginL\fi\vbox\bgroup

\color at begingroup

\hsize\@tempdima

\textwidth\hsize \columnwidth\hsize

\@parboxrestore

\def\@mpfn{mpfootnote}\def\thempfn{\thempfootnote}\c at mpfootnote\z@

\let\@footnotetext\@mpfootnotetext

\let\@listdepth\@mplistdepth \@mplistdepth\z@

\@minipagerestore

\@setminipage}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\def\endminipage{%

\par

\unskip

\ifvoid\@mpfootins\else

\vskip\skip\@mpfootins

\normalcolor

\footnoterule

\unvbox\@mpfootins

\fi

\@minipagefalse %% added 24 May 89

\color at endgroup

\egroup

\if at RTL\endL\fi

\egroup

\expandafter\@iiiparbox\@mpargs{\unhbox\@tempbox

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


Only one issue remains and that is if you have


\documentclass{article}

\usepackage{bidi}

\begin{document} \setRTL

\fbox{\begin{minipage}[b]{0.6\textwidth}

\begin{itemize}

\item This is a test.

\end{itemize}

\end{minipage}}

\end{document}


The indentation of list does not work here. The simplest solution is to have
\leavevmode after \begin{minipage} but that produces a blank like which you
could fix that by \vspace{-\baselineskip}.

The actual question is, what is the best place for that \leavevmode?
-- 
Best wishes,
Vafa Khalighi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/xetex/attachments/20100413/f591f42f/attachment.html>


More information about the XeTeX mailing list