Re: Aspect ratio of newly put objects



John B. Pormann wrote:

I would like to ask whether there is a way to put
a new object onto the canvas keeping its dimensions
as defined in the .svg file. Currently the aspect ratio
is always changed to 1:1, ignoring the .svg. Thus I always
have to resize the object to the desired (=original) dimensions.
It is best visible with the Circuit sheet.
(I'm using Dia v0.91 on win32.)


Pavel,

I haven't tried this, but the custom-shapes file at:

      http://www.lysator.liu.se/~alla/dia/custom-shapes

has some notes about an entry in the svg file:
"The aspectratio element allows you to specify how the shape can be
distorted.  The three possibilities are:
 <aspectratio type="free"/>    Any aspect ratio is OK (the default)
 <aspectratio type="fixed"/>   Fix the aspect ratio for this shape.
 <aspectratio type="range" min="n" max="m"/>  Give a range of values."

Thanks for these suggestions. First, I had tried "fixed". This
worked as expeted. But then I removed the line from the
shape file so that it was as it was before and restarted dia again.
I was quite surprised when I realized that things now worked
as I would like them to: the aspect ratio was correct,
as defined in the shape file, and the shape was freely scalable.
I found out that the reason was that when I ran Dia with the
shape changed to fixed aspect ratio, Dia altered the default
settings for this shape, so that following appeared in the
defaults.dia file:
      <dia:attribute name="elem_width">
        <dia:real val="7"/>
      </dia:attribute>
      <dia:attribute name="elem_height">
        <dia:real val="1.16667"/>
      </dia:attribute>
instead of
      <dia:attribute name="elem_width">
        <dia:real val="2"/>
      </dia:attribute>
      <dia:attribute name="elem_height">
        <dia:real val="2"/>
      </dia:attribute>
for all other non-fixed asp. rat. shapes in this sheet.
After removing the aspect ratio line from the shape file,
Dia just kept applying these new default settings.

Pavel Kvasnicka



--------------------
Centrum.cz Auto: Přinášíme Vám kompletní přehled kabrioletů na českém trhu! 34 aut, ve kterých si léto 
opravdu užijete!<http://user.centrum.cz/redir.php?url=http://auto.centrum.cz/clanek.phtml?id=3870>






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