Omikhleia / resilient.sile

Advanced book classes and packages for the SILE typesetting system
MIT License
21 stars 4 forks source link

Consecutive styling and skips #27

Closed Omikhleia closed 1 year ago

Omikhleia commented 1 year ago

The following experiment uses SILE's standard book class (0.14.8), showing

debuging-vskips

The reason for using the standard book class is shows a few things we also have in resilient.book, but in a simpler way (without the styling stuff on top of that).

See exp. the 2 skips between a chapter and a section = bottom skip from chapter + top skip from section.

In resilient moreover, another similar case occurs with nested blockquotes, e.g.

image

Here with 2 skips at the bottom of the nested quotes (= bottom skip from inner quote + bottom skip from outer quote).

It doesn't really meet my expectations in terms of proper styling -- It would be quite doable to mark skips and detect consecutive top/bottom skips of a certain type to only use one of those where needed...

The idea is a bit similar (but not completely) to the following possibility in LibreOffice

image

If we don't do anything (as currently), besides the 2 skips when a chapter is immediately followed by a section header (vs. 1 skip when a chapter is immediately followed by a text paragraph - notwithstanding a potential parskip), then it seems to me there might also be an additional issue: before a section header, there's usually a "goodbreak", which may lower the penalty of page breaking here! This is obviously ok when text precedes the section header, but if the previous content was another section header (= typically, a section title immediately followed by a subsection header), this might contradict the "novbreak" expected there = resulting in a potential page break between the two headers, which wouldn't look good IMHO (I am not fully sure how the pagebuilder honors consecutive penalties, but it seems to me it will occur this way!)

There's some head-scratching topic here, how to both meet user expectations in terms of skips, and to be safe with page breaks.

Omikhleia commented 1 year ago

It doesn't really meet my expectations in terms of proper styling

And now that I noticed it, I can't help seeing all the cases where indeed this is not meeting my expectations.

It kind of change indeed in behavior, which could be considered (slightly) breaking, but honestly the current behavior is typographically bad. Re-assert as a bug.

It's soon enough after 2.0.0 to assume it can be done now.