Skip to content
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

Use more Sphinx directives. #282

Closed
modelmat opened this issue Oct 19, 2019 · 6 comments
Closed

Use more Sphinx directives. #282

modelmat opened this issue Oct 19, 2019 · 6 comments

Comments

@modelmat
Copy link
Contributor

modelmat commented Oct 19, 2019

This is a list of a few Sphinx directives that I think might be useful to add (if not just because Sphinx provides them), sorted in roughly "wantedness":

.. glossary / :term:

Allows to create a glossary of terms. This would be quite useful, especially in more complex sections.

.. sectionauthor

Specifies who wrote the majority of the current section. Useful for when clarification is needed.
Might be a pain if only one author is allowed.
Does not by default get rendered in output.

:file:

Used for naming files. Apparently this looks different?

:kbd:

Used to represent keyboard strokes. This uses the HTML tag <kbd> and hence draws a box around the key.

@AustinShalit
Copy link
Member

glossary and term seem interesting.

I do not think we need section author.

Not sure what file will do/how it changes what end users see.

When do you think we would use kbd over tick marks?

@modelmat
Copy link
Contributor Author

:kbd: will allow expressions such as ctrl + shift + t to represented as Ctrl + Shift + T.

:file: seems to be when you have a part of the filename that changes - see http://www.sphinx-doc.org/en/master/usage/restructuredtext/roles.html#role-file which italicises the section inside {x}
image
Maybe not that useful.

section author, I'm guessing no because we have git already?

@AustinShalit
Copy link
Member

Oh... I see now about kbd. Seems cool.

I am not sure where we would use file because hopefully the documents are becoming year agnostic.

Yup. Section authors are redundant with git.

@sciencewhiz
Copy link
Collaborator

@modelmat When I looked at the generated file from #295, there's very little distinction of the text in the :kbd: directive. It is not outlined like your example. Unless there's a way to make it more visually distinctive (like your example), I don't think it's worth it.

@sciencewhiz
Copy link
Collaborator

Looks like better formatting for the kbd directive will be in the next RTD theme release. readthedocs/sphinx_rtd_theme#677

@Daltz333
Copy link
Member

Closing as it's not really an issue, and we are using glossary. Something to keep in mind going forward

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants