-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
包含浮动体和longtable的页面内容溢出 #22
Comments
因为 modules/boo/book.sh # 以下2行是干嘛的?
sed -i -E "/begin\{lstlisting.*label.*\]/ s/caption=(.*)?,\s*label=(.*)\]/caption=\1, label=\2, float=htbp\]/" $TEX_OUTPUT
sed -i -E "/begin\{lstlisting.*label.*\]/ s/\[label=(.*)?\]/\[label=\1, caption=\1, float=htbp\]/" |
删除 参见:https://tex.stackexchange.com/questions/88134/stop-listings-going-over-page-breaks |
可以加上 latex2e 项目里的相关 bug report: 虽然那个 issue 里提供的 MWE,无关信息也非常多。 |
非常感谢! |
多个 \documentclass{article}
\usepackage{longtable}
% helper pkg
\usepackage[pass, showframe]{geometry}
\usepackage{lipsum}
\usepackage{listings}
\begin{document}
\begin{lstlisting}[float=htbp]
hello
\end{lstlisting}
\begin{figure}[t]
a\\b\\c\\d
\end{figure}
\begin{lstlisting}[float=htbp]
hello2
\end{lstlisting}
\lipsum[1] % optional
\begin{lstlisting}[float=htbp]
hello3
\end{lstlisting}
\begin{longtable}{l}
cell
\end{longtable}
\begin{lstlisting}[float=htbp]
hello4
\end{lstlisting}
\lipsum
\end{document} |
Closed
https://www.latex-project.org/cgi-bin/ltxbugs2html.new?pr=tools/3512 的patch,对以下 MWE 不生效(longtable前后都有figure) \documentclass[a4paper,12pt]{article}
\usepackage{longtable}
\usepackage{caption}
\newcommand{\baz}{foo foo foo foo foo foo foo foo}
\newcommand{\qux}{\baz\baz\baz\baz\baz\baz\baz\baz}
\begin{document}
\begin{figure}
\caption{Test Figure}
\vspace{10cm}
\end{figure}
\begin{longtable}{llll}
bar & bar & bar & bar
\end{longtable}
\baz
\begin{figure}
\caption{Test Figure 2}
\vspace{10cm}
\end{figure}
\qux\qux\qux\qux\qux\qux\qux\qux
\end{document} |
annProg
added a commit
that referenced
this issue
Jul 18, 2019
annProg
added a commit
that referenced
this issue
Jul 18, 2019
annProg
added a commit
that referenced
this issue
Jul 18, 2019
annProg
added a commit
that referenced
this issue
Jul 18, 2019
annProg
added a commit
that referenced
this issue
Jul 18, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The text was updated successfully, but these errors were encountered: