Bug 343837

Summary: Assert error setting checking Pattern under Texture for brush setting
Product: [Applications] krita Reporter: williamK <johnklinkner>
Component: Brush enginesAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: halla
Priority: NOR    
Version: 2.9 Beta   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed In:

Description williamK 2015-02-05 23:15:32 UTC
brush 4d_fill, checked box Pattern.  result:
ASSERT(krita):'!m_d->isWritingSettings in file C:\dev\desktop\p\calligra\krita\ui\kis-paintop-option.cpp line 73

when you press Ignore the box is checked and it proceeds normally.  Doing the same thing on another brush works fine.  As long as you're in the session, can't reproduce.

However, close krita and start a new session, happens the first time.  Probably an unitialized variable somewhere along the line. 



Reproducible: Always

Steps to Reproduce:
1.  Open new session, create new document.
2.  Draw a line with a pixel brush.  Then open brush properties.
3.  Check Pattern under Texture.

Actual Results:  
Assert failure

Expected Results:  
Nothing other than checked box.  Looks like the box got checked, just a problem on the way out.

Windows 8.1 w/ all service. SP3.
Comment 1 Halla Rempt 2015-02-06 09:25:54 UTC
Hi WIlliam,

Thanks for the report, I can confirm the issue and I'll look into it.
Comment 2 Halla Rempt 2015-02-06 09:53:23 UTC
Git commit c6bc7391b41528f74b4d387da80c71689d660647 by Boudewijn Rempt.
Committed on 06/02/2015 at 09:49.
Pushed by rempt into branch 'calligra/2.9'.

The assert is meant to warn us that some option is emitting changes
to the settings while writing the settings. The texture option does
exactly that because if you check for the currently set pattern, and
no pattern is set (which can happen because of the background loading of
patterns), it will set a pattern. Which will cause the settings to
change as they are being written.

So block all pattern resource chooser signals while writing out the
option -- the written option will be correct anyway.

M  +2    -0    krita/plugins/paintops/libpaintop/kis_texture_option.cpp

http://commits.kde.org/calligra/c6bc7391b41528f74b4d387da80c71689d660647
Comment 3 Halla Rempt 2015-02-06 10:04:40 UTC
*** Bug 343797 has been marked as a duplicate of this bug. ***
Comment 4 Halla Rempt 2015-02-06 15:19:14 UTC
Git commit 81f286ef4caec3f536adb7fdfc122b347e0b9046 by Boudewijn Rempt.
Committed on 06/02/2015 at 09:49.
Pushed by rempt into branch 'master'.

The assert is meant to warn us that some option is emitting changes
to the settings while writing the settings. The texture option does
exactly that because if you check for the currently set pattern, and
no pattern is set (which can happen because of the background loading of
patterns), it will set a pattern. Which will cause the settings to
change as they are being written.

So block all pattern resource chooser signals while writing out the
option -- the written option will be correct anyway.

M  +2    -0    krita/plugins/paintops/libpaintop/kis_texture_option.cpp

http://commits.kde.org/calligra/81f286ef4caec3f536adb7fdfc122b347e0b9046