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
Multiple global style improvements #1079
Conversation
8d3f158
to
decc869
Compare
\indextext{\idxcode{\#elif}}% | ||
\terminal{\# elif}\>\>constant-expression new-line group\opt |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does > do, and does it only have special meaning in grammars?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a tab stop in a tabular setting. But I figured that that was completely unnecessary here (and I have also changed the tab stops to fit better with the main grammars, so this wasn't quite working anymore.)
@@ -424,32 +424,30 @@ | |||
\newcommand{\nonterminal}[1]{{\BnfNontermshape #1}} | |||
|
|||
\newenvironment{bnfbase} | |||
{ | |||
{% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does % do anything here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it was just left over from an earlier experiment. This block is already introducing whitespace, so this doesn't make a difference.
… indent. Each item is now separated from other items and from ambient paragraphs by the same amount as paragraphs are separated from one another. This is also true for paragraphs within an item, and for nested lists. This was achieved by modifying the 'itemize' and 'enumerate' environments to set the relevant lengths appropriately, and by resetting the depth counter to 0 for every list, regardless of actual nesting level, to overcome hardcoded scaling logic in the fundamental 'list' environment. Lists are now spaced independently of whether they are preceded by a paragraph break (because partopsep is now zero). Also changes the 'itemdecl' environment to not use lists for indentation, but 'adjustwidth' instead, and decreased the indentation to the same as for code listings.
I'm currently looking through the standard with this applied. Mostly it looks really good. A raw stream of consciousness of some thoughts:
|
Thanks a lot for the review! I'm going to close this and start extracting smaller parts, keeping the things we like and discarding the ones we don't. |
IMHO... The reduced whitespace after codeblocks is nice. While the denser itemize envs are certainly more consistent with paragraph spacing I don't always find them easier to read. In complex cases like [dcl.init] I think it is an improvement, so overall I like it. Making the grammar use the same indentation as codeblocks looks nice, although I'm less keen on the second level for indentation for the grammar expressions also reducing. Not a big deal though. Postscript: the more I look at the denser itemize lists the more I like them, so maybe it was over-familiarity in my case too. |
@jwakely: Thanks! I will be sending individual PRs to implement each of the things we like. |
simplebnf
environment. "Simple" grammar now uses less space and generally flows better with its surrounding paragraph.