Skip to content
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

页眉与正文重合的问题 #735

Closed
zepinglee opened this issue Mar 4, 2022 · 5 comments
Closed

页眉与正文重合的问题 #735

zepinglee opened this issue Mar 4, 2022 · 5 comments
Assignees
Labels

Comments

@zepinglee
Copy link
Contributor

编译环境

编译的系统:macOS 12.2.1
TeX 发行版:TeX Live 2021
模板版本:v7.2.3
模板类型:doctor / master / bachelor

描述问题

#733 指出,章标题过长时,页眉内容与页眉线会向下挤甚至与正文内容重叠。

根据研究生院的姚飞老师建议,应改为页眉线位置不变,多行页眉的文字内容向上移动。

截图:
Screen Shot 2022-03-04 at 18 43 01

Screen Shot 2022-03-04 at 18 43 28

复现上述问题的代码:

\documentclass[degree=master,language=english]{thuthesis}
\usepackage{lipsum}
\begin{document}
\chapter{Short heading}
\chapter{%
  Long \\
  long \\
  long \\
  heading%
}
\lipsum
\chapter{Short heading}
\end{document}
@zepinglee zepinglee added the bug label Mar 4, 2022
@zepinglee zepinglee self-assigned this Mar 4, 2022
@zepinglee
Copy link
Contributor Author

zepinglee commented Mar 4, 2022

其实这个是 fancyhdr 的问题:

\documentclass{article}
\usepackage{fancyhdr}
\usepackage{lipsum}
\pagestyle{fancy}
\fancyhf{}
\fancyhead[C]{\leftmark}

\begin{document}
\section{Short heading}
\clearpage
\section{%
  Long \\
  long \\
  long \\
  heading%
}
\lipsum
\clearpage
\section{Short heading}
\end{document}

Screen Shot 2022-03-04 at 18 57 16

Screen Shot 2022-03-04 at 18 57 22

@zepinglee
Copy link
Contributor Author

@moSODOPE 试一下 issue#735 分支的 e6c4a70 有没有解决问题。

@moSODOPE
Copy link

moSODOPE commented Mar 9, 2022

好的。非常感谢🙏
是用开发版生成最新.cls文件覆盖旧的吗?这样试了,没有用。
删了.cls文件之后,仍然可以编译,并且还是之前的样子。这是系统缓存了之前的.cls文件导致的吗

@zepinglee
Copy link
Contributor Author

是用开发版生成最新.cls文件覆盖旧的吗?这样试了,没有用。

对,用 issue#735 分支的 .dtx.ins 文件覆盖掉原来的,然后用 xetex 编译 thuthesis.ins 生成新的 .cls

下面代码在 issue#735 分支的效果是:
Screen Shot 2022-03-09 at 10 59 33
Screen Shot 2022-03-09 at 10 59 58

\documentclass[degree=master,language=english]{thuthesis}
\usepackage{lipsum}
\begin{document}
\chapter{Short heading}
\clearpage
\chapter{%
  Long \\
  long \\
  long \\
  heading%
}
\lipsum
\clearpage
\chapter{Short heading}
\end{document}

@moSODOPE
Copy link

moSODOPE commented Mar 9, 2022

牛的,重合问题解决了,非常感谢!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants