如何将横向页面中的表格添加为双列布局?

如何将横向页面中的表格添加为双列布局?

我正在尝试添加一个带有表格的横向页面,如图所示。表格应覆盖整个页面并容纳多行文本。

我看过以前的答案([1]1),但我不确定如何在双列布局中整合这些答案。

        % Contact: Holm Smidt, [email protected]
        %% Based on the style files for ACL 2015 by 
        %% [email protected], [email protected]

        \documentclass[10pt]{article}
        \usepackage{lipsum}
        \usepackage[letterpaper]{geometry}
\usepackage{hicss51}
\usepackage{times}
\usepackage[none]{hyphenat}
\usepackage{url}
\usepackage{latexsym}
\usepackage{minted}
\usepackage{indentfirst}
\usepackage{graphicx}
\graphicspath{{images/}}

        \newcommand{\sansserifformat}[1]{\fontfamily{cmss}{ #1}}

        \title{Please Read Carefully Detailed Formatting Guidelines for Preparing Your HICSS Final Paper with Author Names}

        \author{First Author \\
          Affiliation \\
          {\underline{ email@domain}} \\\And
          Second Author \\
          Affiliation \\
          {\underline{ email@domain} }\\}

        \begin{document}
        \maketitle
        \begin{abstract}
        \lipsum[1]

        \end{abstract}

    \section{table}

    \section{table}

    \afterpage{%
        \clearpage% Flush earlier floats (otherwise order might not be correct)
        \begin{landscape}% Landscape page
            \centering % Center table
            \begin{tabular}{llll}
                This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text \\
            \end{tabular}
            \captionof{table}{Table caption}% Add 'table' caption
        \end{landscape}
        \clearpage% Flush page
    }

        \section{Introduction}
        \lipsum[1-2]

        \bibliographystyle{ieeetr}
        \bibliography{sample}


        \end{document}

在此处输入图片描述

答案1

我不知道这是否适用于,hicss51因为我没有该文件,但您可以使用\onecolumn切换到单列模式,然后\twocolumn切换回来。两者都引入了\clearpage。我也sidewaystablerotating包中使用了。

\documentclass[10pt,twocolumn]{article}
\usepackage{afterpage}
\usepackage{rotating}
\usepackage{lipsum}
%\input{hicss51-packages.tex}
\newcommand{\sansserifformat}[1]{\fontfamily{cmss}{ #1}}

\title{Please Read Carefully Detailed Formatting Guidelines for Preparing Your HICSS Final Paper with Author Names}

\author{First Author \\
  Affiliation \\
  {\underline{ email@domain}} \\\and
  Second Author \\
  Affiliation \\
  {\underline{ email@domain} }\\}

\begin{document}
\maketitle
\begin{abstract}
\lipsum[1]

\end{abstract}

\section{table}

\section{table}

\afterpage{%
    \onecolumn% Flush earlier floats (otherwise order might not be correct)
    \begin{sidewaystable}% 
        \centering % Center table
        \begin{tabular}{*4{p{.2\linewidth}}}
            This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text \\
            This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text This table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text & This table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of textThis table has a lot of text \\
        \end{tabular}
        \caption{Table caption}% Add 'table' caption
    \end{sidewaystable}
    \twocolumn
}

    \section{Introduction}
    \lipsum[1-2]

    \bibliographystyle{ieeetr}
    \bibliography{sample}


    \end{document}

相关内容