I use
h2 {
string-set: section content();
}
and
@top-center {
content: counter(chapter) "." counter(h2) " ▪ " string(section);
text-align: right;
...
}
to produce the running head in the attached screen capture. When a page has two headings, it's not clear which of the two should be used. My editor thinks it should be the last one. I think it should be "whichever one string-set picks " But I don't understand the string-set behavior. Obviously it must do its thing before the header is computed. Otherwise it would pick the preceding section, which would surely be bad when the page starts with a new section, such as this one. But then why doesn't the second section's string-set kick in and replace the first one?
h2 {
string-set: section content();
}
and
@top-center {
content: counter(chapter) "." counter(h2) " ▪ " string(section);
text-align: right;
...
}
to produce the running head in the attached screen capture. When a page has two headings, it's not clear which of the two should be used. My editor thinks it should be the last one. I think it should be "whichever one string-set picks " But I don't understand the string-set behavior. Obviously it must do its thing before the header is computed. Otherwise it would pick the preceding section, which would surely be bad when the page starts with a new section, such as this one. But then why doesn't the second section's string-set kick in and replace the first one?