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

Misnamed plug in new output routine #1667

Open
user227621 opened this issue Feb 19, 2025 · 7 comments
Open

Misnamed plug in new output routine #1667

user227621 opened this issue Feb 19, 2025 · 7 comments
Assignees
Labels
bug category base (latex) enhancement fixed in dev Fixed in development branch, not in stable release

Comments

@user227621
Copy link
Contributor

In the new output routine there is a plug called floats-footnotes-space:

%  \begin{plugdecl}{floats-footnotes-space}
%     As before but the \cs{vfill} is at the bottom (page is ragged
%    bottom).
%    \begin{macrocode}
\NewSocketPlug {build/column/outputbox}{floats-footnotes-space} {%
  \@outputbox@attachfloats
  \@if@footnotes@TF
      {\@outputbox@append{\vfill}}%
      {\@outputbox@reinsertbskip}%
  \@outputbox@appendfootnotes
}
%    \end{macrocode}
%  \end{plugdecl}

However, the code seems to implement the sequence floats-space-footnotes. This seems to make sense: it corresponds to the bottom option of the footmisc package, and the other five plugs correspond to the five other combinations of options in the footmisc package.

The sequence floats-footnotes-space, on the other hand, does not correspond to any combination of options from the footmisc package and does not make sense from a typographical point of view either: Why should a page in a \flushbottom document suddenly be ragged bottom just because a footnote or a float occurs on the page? This is probably one of the two sequences meant in this footnote:

%         Here the footnotes come last.\footnote{There are two more
%         permutations, but neither of them has ever been requested so
%         they aren't set up by default --- doing that in a class
%         would be trivial though.}

On another note, I think it would be useful if there were variants of the floats-space-footnotes, footnotes-space-floats, space-floats-footnotes, and space-footnotes-floats plugs that only add the space if \raggedbottom is active. This is what the KOMA classes implement (with the sequence (space)-footnotes-floats). Perhaps the KOMA classes could then simply use a corresponding plug in future instead of redefining \footnoterule so that it inserts a fil glue.

@FrankMittelbach
Copy link
Member

The sequence floats-footnotes-space, on the other hand, does not correspond to any combination of options from the footmisc package and does not make sense from a typographical point of view either: Why should a page in a \flushbottom document suddenly be ragged bottom just because a footnote or a float occurs on the page?

yes, this is an oversight and it makes little sense as you say.

On another note, I think it would be useful if there were variants of the floats-space-footnotes, footnotes-space-floats, space-floats-footnotes, and space-footnotes-floats plugs that only add the space if \raggedbottom is active. This is what the KOMA classes implement (with the sequence (space)-footnotes-floats). Perhaps the KOMA classes could then simply use a corresponding plug in future instead of redefining \footnoterule so that it inserts a fil glue.

any suggestion for naming such variants?

@user227621
Copy link
Contributor Author

any suggestion for naming such variants?

Good question... Are parenthesis allowed characters in plug names? If so, how about:

  • floats-(space)-footnotes

If not, maybe one of the following:

  • floats-conditionalspace-footnotes
  • floats-maybespace-footnotes
  • floats-rspace-footnotes (the r referring to \raggedbottom)

@davidcarlisle
Copy link
Member

floats-raggedspace-footnotes ?

@FrankMittelbach
Copy link
Member

I must confess that floats-(space)-footnotes looks best to me. Technically there is nothing that prevents us from allowing (..) in such names, butit would be a novum. Thoughts by anybody else from the team?

If we don't want to do that then floats-raggedspace-footnotesas suggested by David might be best and it also has the advantage that it shows more clearly when the space is added.

@FrankMittelbach FrankMittelbach added the fixed in dev Fixed in development branch, not in stable release label Feb 21, 2025
@github-project-automation github-project-automation bot moved this to Pool (unscheduled issues) in upcoming LaTeX2e releases Feb 21, 2025
@FrankMittelbach FrankMittelbach moved this from Pool (unscheduled issues) to Done in dev in upcoming LaTeX2e releases Feb 21, 2025
@FrankMittelbach FrankMittelbach added this to the Release 2025 Q2 milestone Feb 21, 2025
@user227621
Copy link
Contributor Author

I must confess that floats-(space)-footnotes looks best to me. Technically there is nothing that prevents us from allowing (..) in such names, butit would be a novum. Thoughts by anybody else from the team?

If we don't want to do that then floats-raggedspace-footnotesas suggested by David might be best and it also has the advantage that it shows more clearly when the space is added.

In ltsockets-doc.pdf it says: "The name of a plug consists of ASCII letters [a-z], [A-Z], [0-9], [-/@] only." Then floats-(space)-footnotes would not be a valid plug name. Or you would have to adapt the description if there is no technical reason not to use other characters.

(By the way: Is it correct that this issue is labelled "fixed in dev", although the new plug variants are not yet implemented?)

@FrankMittelbach
Copy link
Member

In ltsockets-doc.pdf it says: "The name of a plug consists of ASCII letters [a-z], [A-Z], [0-9], [-/@] only." Then floats-(space)-footnotes would not be a valid plug name. Or you would have to adapt the description if there is no technical reason not to use other characters.

yes if we would officially support something like (space)-footnotes-floats then we would need to update that part of the documentation.

However, I'm getting second thoughts on adding anything at all. How is this KOMA setting differing from

\raggedbottom
\AssignSocketPlug{build/column/outputbox}{space-footnotes-floats}

I mean, why invent a lot of plugs that do not do nothing more than taking a test for ragged bottom into the plug? I mean in a class it doesn't really matter to have specify 2 lines and for a user it perhaps also better that \raggedbottom does just that and not just alter the footnote/float handling, i.e., that without \raggedbottom the footnotes are directly below the text but with it they suddenly get shifted downwards.

Am I missing something?

@user227621
Copy link
Contributor Author

However, I'm getting second thoughts on adding anything at all. How is this KOMA setting differing from

\raggedbottom
\AssignSocketPlug{build/column/outputbox}{space-footnotes-floats}

This is the KOMA setting when \raggedbottom is active. When \flushbottom is active, the KOMA setting is equivalent to:

\flushbottom
\AssignSocketPlug{build/column/outputbox}{footnotes-floats}

I mean, why invent a lot of plugs that do not do nothing more than taking a test for ragged bottom into the plug? I mean in a class it doesn't really matter to have specify 2 lines and for a user it perhaps also better that \raggedbottom does just that and not just alter the footnote/float handling, i.e., that without \raggedbottom the footnotes are directly below the text but with it they suddenly get shifted downwards.

No, this is not correct. In the KOMA classes, \raggedbottom does not alter the footnote/float handling, the footnotes are always at the bottom (if there are no floats), both for \flushbottom and \raggedbottom. The difference is that with \flushbottom, the excess space is distributed across all vertical glues on the page, while with \raggedbottom, the excess space is put between the text and the footnotes, and the other vertical glues keep their natural widths. This cannot be achieved by using a single plug of the six ones defined so far. You would have to switch to space-footnotes-floats whenever \raggedbottom is called and to footnotes-floats whenever \flushbottom is called.

From a typographical point of view, I think using e.g. the space-footnotes-floats plug with \flushbottom results in an inconsistent layout: On pages without footnotes and floats, the excess space is distributed across all vertical glues, while on pages with footnotes or floats, the excess space is suddenly put in one place. This actually applies to all four plugs that contain space, i.e. floats-space-footnotes, footnotes-space-floats, space-floats-footnotes, and space-footnotes-floats. The proposed (space) variants however produce a consistent layout with both \flushbottom and \raggedbottom: With \flushbottom, the excess space is distributed across all vertical glues on all pages (whether or not they contain footnotes or floats), and with \raggedbottom, the excess space is always put in one place (whether or not the page contains footnotes or floats).

I would even go so far as to say that if I had to choose one of the two variants of plugs, I would only implement the (space) plugs because they produce a consistent layout with both \flushbottom and \raggedbottom, whereas the space plugs only produce a consistent layout with \raggedbottom but not with \flushbottom.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug category base (latex) enhancement fixed in dev Fixed in development branch, not in stable release
Projects
Status: Done in dev
Development

No branches or pull requests

3 participants