
패키지 를 사용하면 poetry
섹션 제목 주위에 일관된 공간을 확보하는 데 문제가 있습니다. 내 시는 모두 제목으로 시작합니다 \section
. 때로는 두 개의 시가 같은 페이지에 설정되어 있습니다. 때로는 시가 한 페이지 이상을 넘을 때도 있습니다(현재 poem
환경은 으로 일시 중지되고 그림이 포함된 PDF가 포함되며 시는 첫 번째 줄의 시작 부분에서 \\*
으로 다시 시작됩니다 ). \*
그러나 이로 인해 제목 앞의 공간이 변경됩니다. 즉, "오버플로 텍스트"와 제목과의 거리가 같은 페이지에서 시작하고 끝나는 시와 아래 섹션 제목 사이의 거리보다 작습니다.
일반 텍스트로는 이 문제가 발생하지 않습니다. 즉, 페이지가 일반 텍스트로 시작되고 새 섹션이 시작되면 섹션 제목 앞의 공백은 페이지가 새 섹션으로 시작된 것과 동일합니다.
우주~ 후에섹션 제목은 제목 뒤에 시가 오느냐 일반 텍스트가 오느냐에 따라 바뀌지만, 적어도 일관성은 있고 오버플로 여부에 따라 바뀌지 않습니다. 하지만 poem
환경이 한 페이지에 포함될 때와 비교하여 두 페이지로 분할되면 다음 타이틀 앞에 작지만 눈에 띄는 공간을 차지하게 됩니다.
다양한 조합을 모두 보여주고 싶었기 때문에 MWE가 좀 깁니다. 섹션 2와 3 주변의 공간 차이가 주요 문제입니다. 다른 섹션은 대조를 위해 존재합니다. 참고하시기 바랍니다poetry
다른 패키지와 충돌하는 것처럼 보이므로 로컬에서 실행하면 컴파일되지 않을 수 있습니다. 여기에서 볼 수 있는 Overleaf 예:https://www.overleaf.com/read/qggmxspxsxms
MWE:
\documentclass{article}
\usepackage{poetry}\poemlinenumsfalse
\setlength{\parindent}{0pt}
\begin{document}
\section{The very first, -/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\*
\newpage
\* Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{First, P/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{Following, P/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\newpage
Type-setting is a nightmare
This is plain text
\section{First, T/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{Following, P/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\newpage
Type-setting is a nightmare
This is plain text
\section{First, T/T}
Text Text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\section{Following, T/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\section{Following, T/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\newpage
\section{Top of page, T/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\*
\newpage
\* Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{First, P/T}
Type-setting is a nightmare
This is plain text
\section{Following, T/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{Following, P/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is a poem
\end{document}
답변1
나는 당신의 간격 문제가 무엇인지 파악하지 못했습니다. 저는 poetry
패키지를 사용해본 적이 없습니다. 이것이 도움이 될지 모르겠습니다. verse
패키지 대신 패키지(내가 개발했다는 경고)를 사용하도록 코드를 변경 하고 시 제목에 대신 poetry
을 사용했습니다 .verse
\poemtitle{...}
\section{...}
% poemprob.tex SE 640836
\documentclass{article}
\usepackage{verse}
%\usepackage{poetry}\poemlinenumsfalse
\setlength{\parindent}{0pt}
\begin{document}
\tableofcontents
\poemtitle{The very first, -/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\*
\newpage
\* Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\poemtitle{First, P/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\poemtitle{Following, P/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\newpage
Type-setting is a nightmare
This is plain text
\poemtitle{First, T/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\poemtitle{Following, P/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\newpage
Type-setting is a nightmare
This is plain text
\section{First, T/T}
Text Text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\section{Following, T/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\section{Following, T/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\newpage
\poemtitle{Top of page, T/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\*
\newpage
\* Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\section{First, P/T}
Type-setting is a nightmare
This is plain text
\poemtitle{Following, T/P}
\begin{verse}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{verse}
\section{Following, P/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is a poem
\end{document}
%%%%%% ORIGINAL MWE FOLLOWS %%%%%%%%%%%%%%
\documentclass{article}
{poetry}\poemlinenumsfalse
\setlength{\parindent}{0pt}
\begin{document}
\section{The very first, -/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\*
\newpage
\* Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{First, P/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{Following, P/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\newpage
Type-setting is a nightmare
This is plain text
\section{First, T/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{Following, P/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\newpage
Type-setting is a nightmare
This is plain text
\section{First, T/T}
Text Text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\section{Following, T/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\section{Following, T/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is plain text
\newpage
\section{Top of page, T/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\*
\newpage
\* Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{First, P/T}
Type-setting is a nightmare
This is plain text
\section{Following, T/P}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\section{Following, P/T}
Text text, please behave
So my peace of mind you save
Type-setting is a nightmare
This is a poem
\end{document}
답변2
문제를 이해하고 있는지 잘 모르겠습니다. 시의 기록에는 환경 전후의 공간을 관리하는 \poemtopskip과 \poembotskip이 있다.
\documentclass{article}
%https://tex.stackexchange.com/questions/640836/poetry-package-changes-vertical-space-around-section-headings-in-strange-ways/640918#640918
\usepackage{poetry}\poemlinenumsfalse
\setlength{\parindent}{0pt}
\usepackage{paracol}
\usepackage[margin=2cm]{geometry}
\begin{document}
Default
\begin{paracol}{2}
\section{With the environment poem}
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\textbf{Some text}
\switchcolumn
\section{Without the environment poem}
Poem poem, please behave
So my peace of mind you save
Type-setting is a nightmare
This is a poem
\textbf{Some text}
\end{paracol}
\rule{\linewidth}{0.4pt}
Modified
\begin{paracol}{2}
\section{With the environment poem}
\poemtopskip=0pt%<---- modif 1em by default
\poembotskip=0pt%<---- modif 1em by default
%\setlength{\poemindent}{1in}%<---- for the indent 0pt by default
\begin{poem}
Poem poem, please behave\\
So my peace of mind you save\\
Type-setting is a nightmare\\
This is a poem\\-
\end{poem}
\textbf{Some text}
\switchcolumn
\section{Without the environment poem}
Poem poem, please behave
So my peace of mind you save
Type-setting is a nightmare
This is a poem
\textbf{Some text}
\end{paracol}
\end{document}