[rfc-i] No, constraining to a custom SVG profile is not trivial
phill at hallambaker.com
Wed Jan 22 20:24:04 PST 2020
(For some reason the last posts only just showed up or would have answered
them all in one.)
On Wed, Jan 22, 2020 at 9:29 PM Brian E Carpenter <
brian.e.carpenter at gmail.com> wrote:
> On 23-Jan-20 11:29, Donald Eastlake wrote:
> > There does exist a system form mapping some colors into cross
> > hatchings. See hatchings at
> > https://en.wikipedia.org/wiki/Tincture_(heraldry).
> However, I think that realistically we can't expect IETF tooling to
> perform that complex a remapping (colour to cross-hatching). It really
> would need to be done with the initial drawing tool.
It would certainly be horrible if you are trying to use perl scripting or
SLT. But I have what amounts to the SVG DOM. So it is actually not that
difficult to implement that type of processing or the processing or some of
the features suggested earlier.
The main part of the tool is only 700 lines of code:
The method Attribute at line 268 is currently substituting x/y attributes
for dx/dy which requires the font size etc to be tracked.
The same approach could easily be used to vet color values for contrast. My
original diagrams use color but in a very limited fashion. Most have two
colours plus black and white.
> gnuplot, for example, supports setting monochrome linetypes when plotting
> multiple variables on a single graph. LibreOffice Draw supports
> cross-hatching. Unfortunately the SVG that it generates includes a
> construct (<path style="fill:url(#pattern1)" .../>) that we apparently
> don't allow, even though it's an internal reference:
I don't currently support that transformation, what my tool would produce
<path fill="url(#pattern1)" .../>
I can easily write an FSM to resolve this, the reason I didn't is that the
features that use url() aren't in SVG-Tiny.
Anyone wanting to use SVG diagrams in an RFC is going to need a tool that
can do the deep parse if they are going to use more than one diagram
because they will both have an id="pattern1" element.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rfc-interest