특정 슬라이드를 Beamer 프레임의 특정 부분으로 건너뛰는 논리를 어떻게 확장합니까?

특정 슬라이드를 Beamer 프레임의 특정 부분으로 건너뛰는 논리를 어떻게 확장합니까?

강의 기사 형식에서 특정 강의 슬라이드를 제외하기 위한 작업 구조는 다음과 같습니다.

\documentclass[11pt,handout]{beamer}

\newif\iflecture

\lecturetrue

% Next three lines for article form of presentation

\lecturefalse 

\documentclass[11pt]{article}

\usepackage{beamerarticle}

\iflecture

...frames for just the lecture and not the article form

\fi

둘 다에 남은 프레임.

이 논리를 단일 프레임 내로 확장할 수 있습니까?

\begin{frame}

...content for both lecture and article, a problem for example

end article content here

...remaining content just for lecture

\end{frame}

답변1

파일이 강의로 조판된 경우에만 특정 자료가 나타나도록 하려면 \lectureture로 둘러싸기만 하면 됩니다.

\iflecture <lecture only material>...\fi 

마찬가지로, 강의용이 아닌 자료의 경우:

\iflecture\else <article only material>...\fi 

물론 다음을 결합할 수도 있습니다.

\iflecture <lecture only material>
\else <article only material>\fi 

또 다른 유용한 구성은 \PassOptionsToClass. 전체 MWE는 다음과 같습니다.

\newif\iflecture
\lecturefalse   % uncomment if typesetting as an article
%\lecturetrue   % uncomment if typesetting as a lecture

\iflecture\else
  \PassOptionsToClass{11pt,handout}{beamer}
\fi

\documentclass{beamer}

\begin{document}

  \iflecture
    \begin{frame}{Lecture only frame}
    A framed lecture
    \end{frame}
  \fi

  \begin{frame}
    ...content for both lecture and article, a problem for example
    \iflecture\else article content here\fi

    \iflecture ...remaining content just for lecture\fi
  \end{frame}

\end{document}

관련 정보