#26021 closed Cleanup/optimization (fixed)
Standardize on hanging indent in documentation
Reported by: | Tim Graham | Owned by: | Ed Henderson |
---|---|---|---|
Component: | Documentation | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | yes | UI/UX: | no |
Description
Most of the documentation using 4 space hanging indent, but there are a few places where it needs to be cleaned up. I attached a patch to give some examples and get you started.
Rules to follow:
- The closing parenthesis goes on its own line, aligned with the line that contains the opening parenthesis.
- Include a trailing comma after the last kwarg or item in the dict or tuple so more items can be added later without modifying that line again.
Any questions, let me know.
Attachments (1)
Change History (12)
Changed 7 years ago by
Attachment: | indent.diff added |
---|
comment:1 Changed 7 years ago by
Summary: | Standardize on hanging indent in documentaion → Standardize on hanging indent in documentation |
---|
comment:2 Changed 7 years ago by
Owner: | changed from nobody to Anurag Sharma |
---|---|
Status: | new → assigned |
comment:3 Changed 7 years ago by
comment:4 Changed 7 years ago by
It's not critical either way, but I find it easiest to always add the comma so you don't have to think about it. You never know if a function might gain new arguments too.
comment:7 Changed 7 years ago by
Easy pickings: | set |
---|---|
Owner: | Anurag Sharma deleted |
Status: | assigned → new |
I'm sure there are other places to revise, but I committed my patch for now since no one has picked this up in a while and those weird indentations bother me when I see them.
comment:8 Changed 7 years ago by
Owner: | set to Ed Henderson |
---|---|
Status: | new → assigned |
In utils.txt, (new) line 670, there's no trailing comma. It kinda makes sense that there isn't one, since the function has exactly three arguments, but checking to see if that was intended.