Live effects dont show helper paths

Bug #1246550 reported by Jabiertxof on 2013-10-31
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

Live effects dont show helper paths like in 0.47

Jabiertxof (jabiertxof) on 2013-10-31
Changed in inkscape:
assignee: nobody → Jabiertxof (jabiertxof)
Jabiertxof (jabiertxof) wrote :

This fix

su_v (suv-lp) on 2013-10-31
tags: added: livepatheffects node-editing
su_v (suv-lp) wrote :

Patch tested successfully with r12753 and the Knot path effect: finally the switcher symbol is visible again :)

Two notes about the current patch:
1) LPE_ENABLE_TEST_EFFECTS should not be defined.
(users can add the define when running configure (via CPPFLAGS))
2) The helper paths only update once the mouse is moved again, not e.g. on mouse button release.
This delay is unexpected, and e.g. with the Knot effect makes it someone confusing when cycling through the options by repeatedly clicking on the path effect knot (handle?).

Changed in inkscape:
importance: Undecided → Medium
status: New → In Progress
Jabiertxof (jabiertxof) wrote :

~suv thanks for your test.

1.- Solved in this V2 patch

2.- Knots remove the control of the nodetool while clicking-dragging and need drag outside the knot to hook nodetool events, for that i made a function callable from live_effects and path parameters to update it on knot move. I put the refactor and a example of use in the branch lattice2, exactly in live_effects/paramenters/pointreseteable.cpp:

Lattice 2:

Example of code in a custom point pathparameter:

PointReseteableParam::param_setValue(Geom::Point newpoint)
    *dynamic_cast<Geom::Point *>( this ) = newpoint;
    SPDesktop* desktop = SP_ACTIVE_DESKTOP;
    if (tools_isactive( desktop, TOOLS_NODES)) {
        InkNodeTool *nt = static_cast<InkNodeTool*>( desktop->event_context);

su_v (suv-lp) wrote :

I have to partially revert my earlier review:
With both patches, it seems that the helper paths are sometimes duplicating paths already drawn with other methods:
- Path effects like Bend, Envelope have both the helper paths (blue here), and the parameter paths (green here) drawn on top of each other.
- Path effects like Hatch, Extrude paint helper paths along the result path of the effect, again doubling existing lines (0.47 did this too, for the Hatch LPE).

Both types of 'double-drawing' can be easily observed because of the delayed update of the (blue) helper paths.

Not sure whether this is intended, or a side-effect?

Jabiertxof (jabiertxof) wrote :

This is because this effects has "show_orig_path = true;"
I could remove it from helper paths or from LPEs?

Jabiertxof (jabiertxof) wrote :

It happens too in rotate copies

Jabiertxof (jabiertxof) wrote :

This patch remove extra line to the helper path showing original curve, not need since 0.48.

Jabiertxof (jabiertxof) wrote :

Patch updated to last trunk

su_v (suv-lp) wrote :

Jabiertxof wrote:
> Patch updated to last trunk

The latest version of the patch doesn't compile with current trunk (r12795) - there is still one occurrence of 'InkNodeTool' in 'src/ui/tools/node-tool.cpp'.

Jabiertxof (jabiertxof) wrote :

Thanks su_v i attach the new one!

Johan Engelen (johanengelen) wrote :

This is a difficult fix. Krzysztof can help out with this I hope. I had a look into it, but don't know enough about the PathManipulator code to make a good fix, without his input first.
Krzys: the problem is that "addCanvasIndicators" is not called for any LPE. The intent of addCanvasIndicators is to show any kind of helper indicators of what the LPE is doing (for example, the "switcher" thingie for LPE Knot, back in 0.47).
addCanvasIndicators is called (for the effect itself and for its parameters) by Effect::getCanvasIndicators.
But Effect::getCanvasIndicators is never called.
Somewhere, the pathmanipulator code should call getCanvasIndicators, and draw those indicators as well as the standard path helperpath. Best I can think of is hooking the code up somewhere into the call graph of PathManipulator::_updateOutline().


Liam P. White (liampwhite) wrote :

Fix committed in lp:inkscape r13487. Thanks jabiertxof!

Changed in inkscape:
status: In Progress → Fix Committed
su_v (suv-lp) on 2014-08-01
Changed in inkscape:
milestone: none → 0.91
su_v (suv-lp) on 2015-02-23
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers