有没有一种方法可以在达到特定行长度后自动开始新行,以便在 vim-latex 中更轻松地浏览文档?
示例(文本来自http://en.wikipedia.org/wiki/长颈鹿):
而不是这样:
\documentclass[letter,12pt]{article}
\usepackage[pdftex]{graphicx}
\usepackage{sidecap}
\begin{document}
\begin{SCfigure}
\centering
\includegraphics[width=0.55\textwidth]{Giraffa_camelopardalis_angolensis}
\caption{The giraffe (\emph{Giraffa camelopardalis}) is an African even-toed ungulate mammal, the tallest of all land-living animal species. Males can be 4.8 to 5.5~metres tall and weigh up to 1,360~kilograms. The record-sized bull was 5.87~m tall and weighed approximately 2,000~kg. Females are generally slightly shorter and weigh less than the males do.}
\end{SCfigure}
\end{document}
打字时出现此信息:
\documentclass[letter,12pt]{article}
\usepackage[pdftex]{graphicx}
\usepackage{sidecap}
\begin{document}
\begin{SCfigure}
\centering
\includegraphics[width=0.55\textwidth]{Giraffa_camelopardalis_angolensis}
\caption{The giraffe (\emph{Giraffa camelopardalis}) is an African even-toed
ungulate mammal, the tallest of all land-living animal species. Males can be
4.8 to 5.5~metres tall and weigh up to 1,360~kilograms. The record-sized bull
was 5.87~m tall and weighed approximately 2,000~kg. Females are generally
slightly shorter and weigh less than the males do.}
\end{SCfigure}
\end{document}
答案1
如果您希望在输入时长行自动换行,请使用:
:set textwidth=72
或任何其他值。
在.vimrc
文件中:
autocmd FileType tex set textwidth=72