Last active
June 21, 2017 08:06
-
-
Save jfbu/87e5bcfcc64c4199a942be1d5d51c608 to your computer and use it in GitHub Desktop.
This is a cousin to https://gist.github.com/jfbu/2f3d04414359f716f98ea64dac91eb0e
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\documentclass{article} | |
\newenvironment{foo}{}{} | |
\begin{document} | |
\begin{foo} | |
\noindent\begin{minipage}{\linewidth} | |
bar! | |
\end{minipage} | |
\end{foo} | |
There is blank line above me. | |
\end{document} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@davidcarlisle, thanks. Indeed pinging does not work and I don't get pings from your comments here either.
I see now clearer: with the -1sp, the first space remains at end of line (creating an overfull hbox), which is not as bad as moving it to next line, as it would then create a way underfull last line. (an empty one actually as the space is removed, being at its start)
With the full width, there is a way underfull (empty) last line. As the
\unskip
removed only one space, the first one makes TeX start a new line even though it will be discarded next.Well this is very surprising nevertheless, because one could have thought that it was perfectly legitimate too to leave a trailing space at end of full last line, making it slightly overfull. This does look to me as a deficiency of TeX's handling of spaces at end of a paragraph, but I have not digged into tex.web