페이지를 회전하지 않고 입력 테이블 회전

페이지를 회전하지 않고 입력 테이블 회전

table1.tex테이블이 포함된 입력 파일을 얻습니다 (예: table1.tex로 시작 \begin{table} ... \{table}).

이 테이블을 가로 모드로 인쇄하고 싶지만 페이지를 회전하지 않고 인쇄하고 싶습니다.

나는 시도했다:

\begin{landscape}
\input{table1.tex}
\end{landscape}

하지만 이렇게 하면 전체 페이지가 회전됩니다.

답변1

테이블만 회전해야 한다면 를 사용해 보세요 adjustbox. 그런데 입력 파일에는 tabular(가 아닌 table) 환경이 포함되어야 합니다.

\documentclass{article}
\usepackage{adjustbox}
\begin{document}
\begin{adjustbox}{rotate=270}
\input{table1.tex} 
%table1.tex contains a tabular environment
%Input example:
%\begin{tabular}{l|l}
%This is & a table \\
%\end{tabular}
\end{adjustbox}
\end{document}

캡션 및 참조가 포함된 환경 을 꼭 사용해야 하는 경우 table아래 코드를 시도해 볼 수 있습니다(다시 table입력 파일 내에 표시되는 것을 피함).

\documentclass{article}
\usepackage{adjustbox}
\begin{document}
\begin{adjustbox}{addcode={\begin{minipage}{\width}}{\caption{yourcaptions}\end{minipage}},rotate=270,center,float=table}
\input{table1.tex}
%Input example:
%\begin{tabular}{l|l}
%This is & a table \\
%\end{tabular}
\end{adjustbox}
\end{document}

관련 정보