Make objects fixed and inalterable?

Post questions on how to use or achieve an effect in Inkscape.
Ailurus
Posts: 115
Joined: Fri Oct 22, 2010 9:53 am
Location: The Netherlands
Contact:

Make objects fixed and inalterable?

Postby Ailurus » Sat Oct 30, 2010 8:41 am

Hi all,

I wondered whether it is possible to fix an object (e.g. to a specific node), and make it inalterable, i.e. when the drawing is resized/warped, the object should remain as it is. Example:

Image

When resizing or warping the cube, the spheres should remain as they are in the undeformed state (but their centres still fixed to the nodes). How can I accomplish this?
By the way, you can download the file from the image here (Right Click -> Save As...).

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Make objects fixed and inalterable?

Postby ~suv » Sat Oct 30, 2010 2:04 pm

Ailurus wrote:the spheres should remain as they are in the undeformed state (but their centres still fixed to the nodes).
Why don't you just use (custom) markers?

Ailurus
Posts: 115
Joined: Fri Oct 22, 2010 9:53 am
Location: The Netherlands
Contact:

Re: Make objects fixed and inalterable?

Postby Ailurus » Sat Oct 30, 2010 7:15 pm

~suv wrote:Why don't you just use (custom) markers?


Hmm, I hadn't thought of that. When using it together with "not scaling the stroke when resizing" (is there a short name for that function? :D), it is a perfect solution. Thanks!

Ailurus
Posts: 115
Joined: Fri Oct 22, 2010 9:53 am
Location: The Netherlands
Contact:

Re: Make objects fixed and inalterable?

Postby Ailurus » Sun Oct 31, 2010 7:48 am

Ok, when disabling the option "scale strokes when resizing", the method works fine. However, if the paths are grouped, the markers do deform when warping the cube (oddly enough they remain the same when the cube is scaled). When the paths are not grouped, the markers remain as they are, whether you scale or warp the cube. Is this a bug?

File: Cube3.svg (Right Click -> Save As...).

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Make objects fixed and inalterable?

Postby ~suv » Sun Oct 31, 2010 10:37 am

Ailurus wrote:Is this a bug?
No -- afaiu this is corresponding to the SVG specification (stroke including markers is applied before transforms).

The bug in Inkscape's renderer is quite the opposite for the strokes themselves: their width should also be (non-)uniformly scaled, but Inkscape ignores this and renders the stroke after the transformation is applied (this of course when the transform attribute is present -- like on groups --, but not when the transform is applied and immediately stored in the path data (in Inkscape: preserved vs. optimized transforms, in the preferences).

Test it with a renderer like squiggle (batik), one of Inkscape's reference SVG implementation.
Attachments
stroke+markers-scaled-1.svg
(16.64 KiB) Downloaded 264 times


Return to “Help with using Inkscape”