xml2rfc
xml2rfc copied to clipboard
one extraneous space in text output of figure name
Describe the issue
input:
<figure anchor="Reply_message">
<name>Reply Message Consisting of a Fixed Header, a Request Block TLV, Report
Block TLV(s), a Name TLV, a Reply Block TLV, and Reply Sub-Block TLV(s)</name>
Text output:
Figure 8: Reply Message Consisting of a Fixed Header, a Request
Block TLV, Report Block TLV(s), a Name TLV, a Reply Block TLV,
and Reply Sub- Block TLV(s)
Desired output (no space after the hyphen):
Figure 8: Reply Message Consisting of a Fixed Header, a Request
Block TLV, Report Block TLV(s), a Name TLV, a Reply Block TLV,
and Reply Sub-Block TLV(s)
files: https://www.rfc-editor.org/v3test/test9344.xml https://www.rfc-editor.org/v3test/test9344.txt (PDF and HTML are not affected.)
Code of Conduct
- [X] I agree to follow the IETF's Code of Conduct
I have two code change proposals for this:
- #965 Avoid breaking lines by hyphens. - This affects all text elements. I prefer this but this may have undesirable changes. See the text changes in the PR.
- #966 Include the figure prefix before rending the name text. - This only affects
figure > name
. Note this change will also change how Figure names are wrapped in the past. See the text changes in the PR.
Other work around is to use non-breaking hyphen (‑
). This doesn't need any code changes.
The part that I don't understand is why the figure name (apparently) is formatted to a width and then reflowed for a different width. NBHY indeed is a workaround until we figure that out.