在从右到左的文本中,当使用暂停时,它会改变覆盖深度

在从右到左的文本中,当使用暂停时,它会改变覆盖深度

从右到左的文本,当使用暂停,它改变了覆盖深度

MWE 用于RTL 文本

% !TeX TS-program = xelatex
\documentclass{beamer}

\usefonttheme{serif}
\usepackage[RTLdocument=on]{bidi}
\raggedleft

\makeatletter
\def\ndepth{depth {\color{red}\the\beamer@coveringdepth} }
\makeatother

\begin{document}

\begin{frame}{slide \insertslidenumber }
one \ndepth 
\pause   
two \ndepth
\pause  
three \ndepth 
\end{frame}

\end{document}

输出:

在此处输入图片描述

MWE 用于长按识别文字

% !TeX TS-program = xelatex
\documentclass{beamer}
\usefonttheme{serif}

\makeatletter
\def\ndepth{depth {\color{red}\the\beamer@coveringdepth} }
\makeatother

\begin{document}

\begin{frame}{slide \insertslidenumber }
one \ndepth 
\pause   
two \ndepth
\pause  
three \ndepth 
\end{frame}

\end{document}

输出:

在此处输入图片描述

谢谢你的帮助

编辑:2021-11-05

我认为从右到左文本的问题在于以下命令:

\makeatletter

\def\beamer@startcovered{%
  \beamer@smuggle{%
  \global\advance\beamer@coveringdepth by 1\relax%
  \beamer@actions{\pgfsys@begininvisible\aftergroup\beamer@@spacingcover}{%
     \pgfsys@endinvisible\aftergroup\beamer@@spacingcover%
     }%
  \def\opaqueness<##1>##2{%
    \only<##1>{%
      \beamer@actions{%
        \expandafter\xdef\csname beamer@oldcolorhook%
        \the\beamer@coveringdepth\endcsname{\beamer@colorhook}%
        \expandafter\xdef\csname beamer@oldpgfextension%
        \the\beamer@coveringdepth\endcsname{\beamer@pgfextension}%
        {\globalcolorstrue\colorlet{beamer@freeze\the\beamer@coveringdepth}{bg}}%
        \xdef\beamer@colorhook{!##2!beamer@freeze%
          \the\beamer@coveringdepth\beamer@colorhook}%
        \gdef\beamer@pgfextension{!##2opaque}%
        \color{.}%
      }%
      {%
        \xdef\beamer@colorhook{\csname beamer@oldcolorhook%
          \the\beamer@coveringdepth\endcsname}%
        \xdef\beamer@pgfextension{\csname beamer@oldpgfextension%
          \the\beamer@coveringdepth\endcsname}%
        \color{.}%
      }}}%
  \ifnum\beamer@slideinframe<\beamer@minimum %ok, at beginning
    \begingroup
      \beamer@saveanother
      \advance\beamer@minimum by-\beamer@slideinframe
      \beamer@slideinframe=\beamer@minimum
      \beamer@uncoverbeforeactions
      \beamer@restoreanother
    \endgroup
  \else
    \begingroup
      \beamer@saveanother
      \advance\beamer@slideinframe by-\beamer@minimum
      \beamer@uncoverafteractions
      \beamer@restoreanother
    \endgroup
  \fi
  \beamer@do
  }%
}
\def\beamer@endcovered{%
  \beamer@smuggle{%
  \csname beamer@doafter\the\beamer@coveringdepth\endcsname
  \global\advance\beamer@coveringdepth by -1\relax
  }%
}%

\renewrobustcmd{\beamer@@pause}[1][]{%
  \ifblank{#1}%
    {\stepcounter{beamerpauses}}%
    {\setcounter{beamerpauses}{#1}}%
  \onslide<\value{beamerpauses}->\relax%
}

\makeatother

谢谢

答案1

客观的:解决从右到左文本的暂停问题

我知道以下临时解决方案确实有效:

方法 1\pause[0]:在帧结束前添加

% !TeX TS-program = xelatex
\documentclass{beamer}
\usefonttheme{serif}

\usepackage[RTLdocument=on]{bidi}
\raggedleft

\makeatletter
\def\ndepth{depth {\color{red}\the\beamer@coveringdepth} }
\makeatother

\begin{document}

\begin{frame}{slide \insertslidenumber }
one \ndepth 
\pause   % Equivalent => \onslide<2->
two \ndepth
\pause  % Equivalent => \onslide<3->
three \ndepth 
\pause[0] % <---- add for solve RTL text
\end{frame}

\end{document}

方法 2\onslide<\value{beamerpauses}->{text}

\begin{frame}{slide \insertslidenumber }
one \ndepth   
\onslide<2->{two \ndepth} 
\onslide<3->{three \ndepth}  
\end{frame}

方法 3: (谢谢@samcarter\only<+->{text}

\begin{frame}{slide \insertslidenumber }
\only<+->{one \ndepth} 
\only<+->{two \ndepth} 
\only<+->{three \ndepth} 
\end{frame}

输出:

在此处输入图片描述

相关内容