[trunk] Custom markers only added to the list in 'Fill&Stroke > Style' after reloading the file

Bug #1030239 reported by su_v
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
Medium
John Smith

Bug Description

Custom markers are only added to the list as long as the 'Fill & Stroke' dialog has not been opened yet during the current session.

Steps to reproduce:
1) mv ~/.config/inkscape{,-bkp}
2) launch Inkscape (empty)
3) draw a small circle (stroke: black, fill: red)
4) duplicate the circle, move aside and change style (stroke: black, fill: blue)
5) draw a path with the pen tool
6) select red circle and apply 'Object > Objects to Marker'
7) open Fill&Stroke and use the new custom marker for start nodes
8) select blue circle and apply 'Object > Objects to Marker'
9) use the second, blue custom marker for end nodes

Expected result:
The second custom marker (blue fill) appears in the list after opening the popup list a second time (bug #490970)

Actual result:
The second custom marker (blue fill) is not added to the list, despite opening the popup menu repeatedly. Only after reloading the file it is available in the popup list to be applied as marker for the selected path.

Variation:
Executing step 7 (open 'Fill&Stroke') after step 8 (instead of before) will make both newly created custom markers appear in the popup list. Custom markers added later on (after 'Fill&Stroke' has been opened once) again won't be added until reloading the document.

Tested with Inkscape 0.48+devel on OS X 10.7.4:
- not reproduced with r11072
- reproduced with r11084 and later revisions (up to latest r11573)

Related earlier reports:
Bug #490970 'Inkscape does not show the first marker created with: "Object-> Object to markers"'
and likely this one:
Bug #943225 'Failure to build with GTKMM_DISABLE_DEPRECATED'

su_v (suv-lp)
summary: - Custom markers only added to the list in 'Fill&Stroke > Style' after
- reloading the file
+ [trunk] Custom markers only added to the list in 'Fill&Stroke > Style'
+ after reloading the file
Revision history for this message
jazzynico (jazzynico) wrote :

Confirmed on Ubuntu 11.04, Inkscape trunk revision 11573.

Changed in inkscape:
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
su_v (suv-lp) wrote :

Related:
Unreferenced markers which are purged with 'File > Clean up document' are not removed from the list either.

Revision history for this message
John Smith (john-smithi) wrote :

Patch to fix the following problems :

The markers combobox was not listening to changes in <defs>, so several changes to markers where not shown
1. Custom marker creation/deletion (Object to Marker)
2. Clean up document (that removes unused markers)
3. Extension ColorMarkers that creates new markers

Tested on Ubuntu 12.04, please test if you can.

A known issue is that after Extension Color Markers is run, something happens to the defs and the markers are no longer notified of any changes to the defs. Not sure of the cause or solution for this.

Revision history for this message
su_v (suv-lp) wrote :

Testing Inkscape 0.48+devel r11575+1030239.patch on OS X 10.7.4:
Seems to introduce a regression with 'File > Revert'

Steps to reproduce:
1) mv ~/.config/inkscape{,-bkp}
2) launch inkscape (empty)
3) open an existing file (e.g. 'tiger.svgz' from the 'examples' dir listed in Places)
4) open 'Fill & Stroke'
5) apply 'File > Revert'

-> crash (backtrace attached)

Crash only happens when reverting after having 'Fill & Stroke' opened in the current session, and doesn't happen without the patch.

Revision history for this message
jazzynico (jazzynico) wrote :

Crash confirmed on Windows XP, Inkscape revision 11575.

Also crashes when opening a document (with File>Open or File>Open>Recent) when the F&S dialog is active.

Revision history for this message
John Smith (john-smithi) wrote :

v2 patch attached should fix the crashers in comments #4 and #5.

Changed in inkscape:
assignee: nobody → John Smith (john-smithi)
status: Triaged → In Progress
Revision history for this message
jazzynico (jazzynico) wrote :

Patch tested successfully on Windows XP, Inkscape revision 11575.
Thanks John!

Revision history for this message
su_v (suv-lp) wrote :

Testing r11582/11583+1030239.v2.patch on OS X 10.7.4:

I notice a performance regression with paths which have custom markers applied:
1) launch inkscape
2) draw a rect, open Fill&Stroke
3) open (from within inkscape) a second file which has objects with custom markers
4) select a path with custom markers and drag it with the mouse

-> dragging is noticeably delayed, e.g. compared to dragging a path/objects without markers or with stock markers.

Not observed when working only with one document window, or when opening Fill&Stroke only in the second window (with the document which has custom markers).

Revision history for this message
John Smith (john-smithi) wrote :

> I notice a performance regression
@~suv, thanks for testing and good find.
The cause of this maybe an issue where all the (docked) Stroke style dialog(s) are updated in all windows when the selection is changed. I seem to recall seeing this bug listed somewhere, but i can't find it. I think this bug affected a few other dialogs as well. It also affects the "master" Blur and Opacity in the Fill/Stroke dialog. Do you recall the bug # ?

Revision history for this message
su_v (suv-lp) wrote :

John Smith wrote
> It also affects the "master" Blur and Opacity in the Fill/Stroke dialog.
> Do you recall the bug # ?

Maybe these?

Blur/opacity widget has been mentioned in comments 7 and 8 of
- Bug #427514 "two inkscape instances will mirror data in some dialogues"
 <https://bugs.launchpad.net/inkscape/+bug/427514>

Report which originally tracked the issue of mirrored data between Fill&Stroke docked in multiple document windows:
- Bug #270623 "Fill and Stroke" panel is mirrored between open windows
 <https://bugs.launchpad.net/inkscape/+bug/270623>

Revision history for this message
John Smith (john-smithi) wrote :

Yes those are the ones, thanks !
I created a new report (bug #1032880) for this, since bug #270623 was already closed.

Revision history for this message
John Smith (john-smithi) wrote :

Fix committed to trunk r11588.

Changed in inkscape:
status: In Progress → Fix Committed
Revision history for this message
su_v (suv-lp) wrote :

Changing bug status to 'Fix Released' in accordance with
<http://wiki.inkscape.org/wiki/index.php/Bug_management#Bug_status>:
reported issue only occurred in development snapshot builds and never in a released version.

Changed in inkscape:
status: Fix Committed → Fix Released
Revision history for this message
John Smith (john-smithi) wrote :

r11597 - Fix selection and performance regression (see bug #1032880 comment #6).

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.