diff options
author | Erik Faye-Lund <[email protected]> | 2020-06-30 12:09:31 +0200 |
---|---|---|
committer | Marge Bot <[email protected]> | 2020-07-01 07:29:21 +0000 |
commit | 1d7bb2dde0dd0751f48adedfc3ca8dcaa7f2a4fb (patch) | |
tree | 1d71bea0bd53bf0c92d109fb18aaf53b99a62c81 /src/gallium/docs/source/exts | |
parent | 47d3b80428cd251b48735cde91df2f217ea65235 (diff) |
gallium/docs: prefix exts dir with underscore
It's generally considered good practice to use underscore-prefixes for
directories that contains non-doumentation files, so let's do this for
our custom extensions as well.
Acked-by: Alyssa Rosenzweig <[email protected]>
Acked-by: Eric Engestrom <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5691>
Diffstat (limited to 'src/gallium/docs/source/exts')
-rw-r--r-- | src/gallium/docs/source/exts/formatting.py | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/src/gallium/docs/source/exts/formatting.py b/src/gallium/docs/source/exts/formatting.py deleted file mode 100644 index bc50c98051c..00000000000 --- a/src/gallium/docs/source/exts/formatting.py +++ /dev/null @@ -1,31 +0,0 @@ -# formatting.py -# Sphinx extension providing formatting for Gallium-specific data -# (c) Corbin Simpson 2010 -# Public domain to the extent permitted; contact author for special licensing - -import docutils.nodes -import sphinx.addnodes - -def parse_envvar(env, sig, signode): - envvar, t, default = sig.split(" ", 2) - envvar = envvar.strip().upper() - t = " Type: %s" % t.strip(" <>").lower() - default = " Default: %s" % default.strip(" ()") - signode += sphinx.addnodes.desc_name(envvar, envvar) - signode += sphinx.addnodes.desc_type(t, t) - signode += sphinx.addnodes.desc_annotation(default, default) - return envvar - -def parse_opcode(env, sig, signode): - opcode, desc = sig.split("-", 1) - opcode = opcode.strip().upper() - desc = " (%s)" % desc.strip() - signode += sphinx.addnodes.desc_name(opcode, opcode) - signode += sphinx.addnodes.desc_annotation(desc, desc) - return opcode - -def setup(app): - app.add_object_type("envvar", "envvar", "%s (environment variable)", - parse_envvar) - app.add_object_type("opcode", "opcode", "%s (TGSI opcode)", - parse_opcode) |