我想创建如下所示的文档。我该怎么做?
答案1
使用paracol
. 这相当简单:
\documentclass{article}
\usepackage{paracol,lipsum}
\usepackage[margin=1in]{geometry}% Just for this example
\begin{document}
%\columnratio{0.5} 50/50 split between columns
\raggedright
\begin{paracol}{2}
\textbf{Study Name (Number):}
\switchcolumn
MarginProbe System US Post-Market Study
\switchcolumn*
\textbf{Product:}
\switchcolumn
MarginProbe System
\switchcolumn*
\textbf{Indication:}
\switchcolumn
\underline{Intended Use:} \par
\lipsum[2]
\end{paracol}
\columnratio{0.3}% First column takes up 30% of \textwidth
\begin{paracol}{2}
\textbf{Study Name (Number):}
\switchcolumn
MarginProbe System US Post-Market Study
\switchcolumn*
\textbf{Product:}
\switchcolumn
MarginProbe System
\switchcolumn*
\textbf{Indication:}
\switchcolumn
\underline{Intended Use:} \par
\lipsum[2]
\end{paracol}
\end{document}
答案2
您还可以使用description
或longtable
环境:
labelwidth=5.0cm
可以通过设置等或更改环境p{}
中的设置来调整列的大小longtable
以获得:
代码:description
:
\documentclass{article}
\usepackage{lipsum}
\usepackage{calc}
\usepackage{enumitem}
\begin{document}
\begin{description}[labelwidth=\widthof{\bfseries Study Name (Number):}, leftmargin=!, noitemsep]
\item [Study Name (Number):]
MarginProbe System US Post-Market Study
\item [Product:]
MarginProbe System
\item [Indication:]
\underline{Intended Use:} \par
\lipsum[2]
\end{description}
\end{document}
代码:description
带有列大小控制:
\documentclass{article}
\usepackage{lipsum}
\usepackage{calc}
\usepackage{enumitem}
\begin{document}
\begin{description}[labelwidth=5.0cm, leftmargin=!, noitemsep]
\item [Study Name (Number):]
MarginProbe System US Post-Market Study
\item [Product:]
MarginProbe System
\item [Indication:]
\underline{Intended Use:} \par
\lipsum[2]
\end{description}
\end{document}
代码:longtable
:
\documentclass{article}
\usepackage{lipsum}
\usepackage{longtable}
\begin{document}
\raggedright
\begin{longtable}{@{}p{4.5cm} p{\dimexpr\linewidth-4.5cm-2\tabcolsep\relax}@{}}
\textbf{Study Name (Number):} &
MarginProbe System US Post-Market Study \\
\textbf{Product:} &
MarginProbe System \\
\textbf{Indication:} &
\underline{Intended Use:} \par
\lipsum[2]
\end{longtable}
\end{document}