Re: dia svg export: how do adjust size?



On 02.10.2007 13:20, Zhang Weiwu wrote:
Dear all

After made a graph in dia 0.96.1, I export it to svg by "File -> Export
-> change extension name to .svg and click save".

Result file cannot be opened in firefox 2.0.0.6. Error:
        This XML file does not appear to have any style information
associated with it. The document tree is shown below.

http://bugzilla.gnome.org/show_bug.cgi?id=327037

Then I export by repeating above operation while select "SVG Plain" as
export format, this time it works and created an SVG file open-able in
Firefox, but the graph is too big, and text is relatively bigger than
shapes, making many text in rectangles ends outside the rectangle.

Probably related to:
http://bugzilla.gnome.org/show_bug.cgi?id=475978

I got 3 problem here:

   1. Why simply export by changing extension name doesn't work
      (resulted svg that doesn't work in Fx)? If it's not open-able in
      Fx people assume it's broken, then dia should by default use
      "Plain SVG" or whatever option that produce more compatible svg.
There is more than one SVG exporter, the one choosen for "By extension" is
more or less random. But you can disable two of three fia File/Plugins

   2. Why text is relatively bigger?
http://bugzilla.gnome.org/show_bug.cgi?id=316590

   3. How can I reduce the size of exported svg? I have tried to find
      option for dpi (no such option) and I try to find option for
      exported svg size (no such option) and then I try to make the
      graph smaller (not possible, because after grouped all objects,
      the group is not resizeable).

File/Page Setup/Scale is your friend.

Thanks! Note all of my 3 questions are probably bugs, let me know if I
should file them as bug please. Seriously, I consider proper export of
correct SVG is very important, DIA should have high quality control over
this particular part.

This is an interesting point. As noted elsewhere
[ http://mail.gnome.org/archives/dia-list/2007-September/msg00023.html ]
Firefox is not yet capable to do "Quality Control" on SVG. But sure Dia's
SVG exporters could use some improvements. Patches accepted.

For sizing: user can reasonably expect exported svg image opens in
firefox the same size as in dia when zoom is 100%. While this might not
be easy as screen dpi may vary, at least it shouldn't be too far away
from user expectation. 
There is some default scaling in SVN which should lead to almost same
screen size in Dia with 100% zoom and Firefox.

On a higher level of usability requirement, a
user might expect the diagram not exceeding the width of the screen
prints within the A4 page width (especially on XGA) unless a shape of A4
page is clearly placed as background, and even expect the same for svg
exported. This might not have to be satisfied but should be considered
at least.

The cairo based SVG exporter is the one the way geared to give you the best
rendering results, currently to the price of lost editability. Note: as
with other cairo backends the page size is not yet passed through the file.
I don't even know from the top of my had if this is already possible with
cairo.

For printing: just noticed user cannot select printer when printing in
dia. I hope this can be improved too:)

Works fine on win32 for a while, should become better if we use the cross
platform GtkPrint recently introduced with gtk+.

But as always: it is not going to happen if nobody volunteers to do the work.

        Hans

-------- Hans "at" Breuer "dot" Org -----------
Tell me what you need, and I'll tell you how to
get along without it.                -- Dilbert



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