From a05ed9fd5f15fa7ce8565ff64ecaa08a7cba51ab Mon Sep 17 00:00:00 2001 From: Mark Hansen Date: Thu, 22 Oct 2020 21:11:58 +1100 Subject: [PATCH] attrs.html: Rename attr.uses to used_by Matches table header. Makes more sense when you're looking at an attribute definition --- doc/infosrc/mkattrs.py | 6 +++--- doc/infosrc/templates/attrs.html.j2 | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/infosrc/mkattrs.py b/doc/infosrc/mkattrs.py index 9c59968c9..fa4616124 100755 --- a/doc/infosrc/mkattrs.py +++ b/doc/infosrc/mkattrs.py @@ -19,7 +19,7 @@ import templates class Attribute: name: str # use string : this is a string formed of G,N,C,E - uses: str + used_by: str kinds: List[str] flags: List[str] html_description: str @@ -41,13 +41,13 @@ with open(sys.argv[1]) as attrs_in: if line.startswith(':'): # This is a header line. Grab out the values. - # :name:uses:kind[:dflt[:minv]]; [notes] + # :name:used_by:kind[:dflt[:minv]]; [notes] headers, _, flags = line.rpartition(';') parts = headers.split(':') attr = Attribute( name=parts[1], - uses=parts[2], + used_by=parts[2], kinds=parts[3].split('/'), flags=[flag for flag in flags.strip().split(',') if flag], # Set an empty string html description, ready to append to. diff --git a/doc/infosrc/templates/attrs.html.j2 b/doc/infosrc/templates/attrs.html.j2 index 7c24fa889..7e90421d5 100644 --- a/doc/infosrc/templates/attrs.html.j2 +++ b/doc/infosrc/templates/attrs.html.j2 @@ -92,7 +92,7 @@ of the layout programs. {% for attr in attrs %} {{ attr.name }} - {{ attr.uses }} + {{ attr.used_by }} {%- for kind in attr.kinds -%} {%- if not loop.first -%} -- 2.40.0