0.92.x: Extensions use previous selection when nothing is selected

Bug #1777530 reported by Hachmann
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
Undecided
Unassigned

Bug Description

I was surprised to notice that self.selected.iteritems returns the previous selection that has been used with an extension, if nothing is selected.

To reproduce:

- draw a couple of paths with pencil tool
- select one of them
- run Visualize Path > Measure path
- deselect object
- run Visualize Path > Draw handles

Expected result:

 Extension tells me that there is no selection.

Actual result:

 The extension draws handles on the path I had selected for use with the previous extension.

Should a variable be unset somewhere in the C++ code after an extension has finished running?

This is with Inkscape 0.92.3 (b1b3369, 2018-06-06) on Linux Mint 18.3.
Same for master, 0.92+devel (e4a9aed, 2018-06-18).

Hachmann (marenhachmann)
description: updated
Revision history for this message
Alvin Penner (apenner) wrote :

interesting, must be recent:
- reproduced on Windows 10, Inkscape 0.92.3 (b1b3369, 2018-06-06)
- not reproduced on Windows 10, Inkscape 0.92.3 (2405546, 2018-03-11)

Changed in inkscape:
status: New → Confirmed
Revision history for this message
Hachmann (marenhachmann) wrote :

Thanks for testing, Alvin!

Revision history for this message
Alvin Penner (apenner) wrote :

narrowed it down a bit more:

- not reproduced on Windows 10, Inkscape 0.92.3 (10e8ae0, 2018-05-25)
- reproduced on Windows 10, Inkscape 0.92.3 (b1b3369, 2018-06-06)

possibly related to this commit:
https://gitlab.com/inkscape/inkscape/commit/b1b33698810bb8ae6e31e509697ff27d2732e7ac

Revision history for this message
Hachmann (marenhachmann) wrote :

Good work :) In case you hadn't pinged Jabier yet, I did (on the commit on gitlab).

Revision history for this message
Jabiertxof (jabiertxof) wrote : Re: [Bug 1777530] Re: 0.92.x: Extensions use previous selection when nothing is selected

Try to fix tomorrow, thanks for the ping Maren

⁣Enviado desde TypeApp ​

En 19 jun. 2018 23:01, en 23:01, Hachmann <email address hidden> escribió:
>Good work :) In case you hadn't pinged Jabier yet, I did (on the commit
>on gitlab).
>
>--
>You received this bug notification because you are subscribed to
>Inkscape.
>Matching subscriptions: Inkscape
>https://bugs.launchpad.net/bugs/1777530
>
>Title:
> 0.92.x: Extensions use previous selection when nothing is selected
>
>Status in Inkscape:
> Confirmed
>
>Bug description:
> I was surprised to notice that self.selected.iteritems returns the
> previous selection that has been used with an extension, if nothing is
> selected.
>
> To reproduce:
>
> - draw a couple of paths with pencil tool
> - select one of them
> - run Visualize Path > Measure path
> - deselect object
> - run Visualize Path > Draw handles
>
> Expected result:
>
>  Extension tells me that there is no selection.
>
> Actual result:
>
>  The extension draws handles on the path I had selected for use with
> the previous extension.
>
> Should a variable be unset somewhere in the C++ code after an
> extension has finished running?
>
> This is with Inkscape 0.92.3 (b1b3369, 2018-06-06) on Linux Mint 18.3.
> Same for master, 0.92+devel (e4a9aed, 2018-06-18).
>
>To manage notifications about this bug go to:
>https://bugs.launchpad.net/inkscape/+bug/1777530/+subscriptions

Revision history for this message
Hachmann (marenhachmann) wrote :

Jabier, that would be cool :)

Revision history for this message
Jabiertxof (jabiertxof) wrote :

Fixed in master in e33f40d66476a27daec0153ef764a01733935df9
and in 0.92.x in cdafc079a93b6d26750948bb324f1130433163a8

Thanks for fill the bug!

Changed in inkscape:
status: Confirmed → Fix Released
Revision history for this message
Hachmann (marenhachmann) wrote :

Supercool - thanks Jabier! I love that it no longer deselects the object after the extension has run! (which is probably the change that had caused the problem).

Can I add that info to the release notes for 0.92.4?

Revision history for this message
Jabiertxof (jabiertxof) wrote :

Great, you also can speak about performance on apply multiple filters or using a complex doc.
Regards.

Revision history for this message
Hachmann (marenhachmann) wrote :

@Jabiertxof Can you tell me a bit more about the performance improvements? Do they have anything to do with extensions? Or is this about rendering / the objects dialog /...?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.