diff options
author | Clément Pit-Claudel <clement.pitclaudel@live.com> | 2018-04-30 00:32:00 -0400 |
---|---|---|
committer | Clément Pit-Claudel <clement.pitclaudel@live.com> | 2018-05-15 12:05:44 -0400 |
commit | dc5b6e15a2db658fb36754608683b10f847b3e94 (patch) | |
tree | da11af42a9af1dfddc200d1dd1dacc7fb3f30545 /doc/sphinx/README.template.rst | |
parent | 6f3a8a90514669c84be4de5726fe65f15141ca4d (diff) |
[doc] Add an ELisp snippet to insert Sphinx roles and quotes
Diffstat (limited to 'doc/sphinx/README.template.rst')
-rw-r--r-- | doc/sphinx/README.template.rst | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/doc/sphinx/README.template.rst b/doc/sphinx/README.template.rst index a387247e5..2f7ba028a 100644 --- a/doc/sphinx/README.template.rst +++ b/doc/sphinx/README.template.rst @@ -81,3 +81,13 @@ Coq roles In addition to the objects and directives above, the ``coqrst`` Sphinx plugin defines the following roles: [ROLES] + +Tips and tricks +=============== + +The ``dev/tools/coqdev.el`` folder contains a convenient Emacs function to quickly insert Sphinx roles and quotes. It takes a single character (one of ``gntm:```), and inserts one of `:g:`, `:n:`, `:t:`, or an arbitrary role, or double quotes. You can also select a region of text, and wrap it in single or double backticks using that function. + +Use the following snippet to bind it to :kbd:`F12` in ``rst-mode``:: + + (with-eval-after-load 'rst + (define-key rst-mode-map (kbd "<f12>") #'coqdev-sphinx-rst-coq-action)) |