PreTeXtBook / pretext

PreTeXt: an authoring and publishing system for scholarly documents
https://pretextbook.org
Other
266 stars 208 forks source link

Consolidate *-LIKE series via preprocessing #1768

Open rbeezer opened 2 years ago

rbeezer commented 2 years ago

Blocks in *-LIKE series usually differ in name only. Example: theorem and lemma in THEOREM-LIKE.

Idea: have the preprocessor convert these to one (lead) element in the series and use attributes to distinguish.

<theorem variant="theorem">
<theorem variant="corollary">

Pros:

Cons:

davidfarmer commented 2 years ago

Speaking of consolidation, will publishers have more flexibillity in grouping different elements to be on a common counter?

Maybe a bad publisher wants Figures and definition-like numbered together.

And theorem-like and exercises numbered together.

And everything else numbered together.

So, 3 separate counters through the document.

On Mon, 27 Jun 2022, Rob Beezer wrote:

Blocks in *-LIKE series usually differ in name only. Example: theorem and lemma in THEOREM-LIKE.

Idea: have the preprocessor convert these to one (lead) element in the series and use attributes to distinguish.

Pros: * Greatly simplify many select and match in the XSL. * Need only inspect @variant when producing a name? (And maybe old-style IDs, etc) * Transparent to authors, no deprecation. * Perhaps nearly trivial to add a new element to a series Cons: * Will disrupt LaTeX enviroment creation based on different elements, but this is internal. * Will disrupt styling for LaTeX based on using XSL matching, affects external style-writers. — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to thisthread.[AABTULF4H76ZWP7LPAUBWVTVRHV6LA5CNFSM5Z7KWPM2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4TFH7ALQ .gif] Message ID: ***@***.***>
rbeezer commented 2 years ago

A numbering overhaul is on hold from February. This issue would contribute to that, though mostly cosmetically.

When that is done, figure-like and project-like will be part of block numbering, or separate (individually), iirc.