octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #58429] SVG export could be better


From: anonymous
Subject: [Octave-bug-tracker] [bug #58429] SVG export could be better
Date: Fri, 22 May 2020 15:59:01 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:76.0) Gecko/20100101 Firefox/76.0

URL:
  <https://savannah.gnu.org/bugs/?58429>

                 Summary: SVG export could be better
                 Project: GNU Octave
            Submitted by: None
            Submitted on: Fri 22 May 2020 07:58:59 PM UTC
                Category: None
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Other
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
                 Release: 6.0.90
         Discussion Lock: Any
        Operating System: GNU/Linux

    _______________________________________________________

Details:

This may or may not be a bug, but it is non-intuitive behavior.

Input is any of these plot statements:

[xx,yy] = meshgrid(1:3,1:3);
plot(xx(:), yy(:), 'ko', "markersize",20); axis equal; axis off; saveas (gcf,
"foo1.svg"); close all
plot(xx(:), yy(:), 'k.', "markersize",20); axis equal; axis off; saveas (gcf,
"foo2.svg"); close all
plot(xx(:), yy(:), 'ks', "markersize",20); axis equal; axis off; saveas (gcf,
"foo3.svg"); close all


Output inside SVG is like this:

<polygon fill="#000000" shape-rendering="crispEdges" points="91.4142,281.458
89.7475,282.669 87.6874,282.669 86.0207,281.458 85.3841,279.499 86.0207,277.54
87.6874,276.329 89.7475,276.329 91.4142,277.54 92.0508,279.499"/>


Ideal SVG output would be something like (for solid circles):

<circle fill="#000000" r="3.33" cx="88.717" cy="279.5" />


with similar statements for the other shapes in the format arguments accepted
by plot.

This makes a difference in the quality of the resulting SVG, with the large
polygon statement looking "hairy" or "corroded" instead of smooth because of
the long list of vertices.

This has been worked around in code by directly writing SVG output to file
instead of invoking saveas(). Is this worth improving the SVG export for?




    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?58429>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]