diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-04-29 09:40:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-29 09:40:52 +0200 |
commit | 41af228b767b8657c51376be77e9a8f1601e05d0 (patch) | |
tree | 7b9f1af0bc5a32e1008d3349edc28897e9ca0dd5 /doc/tools | |
parent | 2ed231521b125b12fc604f021ee323c008c69c30 (diff) | |
parent | 1ea7295bd21748ac34755cdb96fcba385a206240 (diff) |
Merge pull request #36960 from pycbouh/docs-improve-shortcuts
Improve shortcut formatting in docs
Diffstat (limited to 'doc/tools')
-rwxr-xr-x | doc/tools/makerst.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/tools/makerst.py b/doc/tools/makerst.py index 5ceab52523..a14ef7c665 100755 --- a/doc/tools/makerst.py +++ b/doc/tools/makerst.py @@ -901,6 +901,12 @@ def rstize_text(text, state): # type: (str, State) -> str tag_text = "``" tag_depth += 1 inside_code = True + elif cmd == "kbd": + tag_text = ":kbd:`" + tag_depth += 1 + elif cmd == "/kbd": + tag_text = "`" + tag_depth -= 1 elif cmd.startswith("enum "): tag_text = make_enum(cmd[5:], state) escape_post = True |