News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

bug in wxSmith

Started by frithjofh, June 20, 2010, 07:30:32 PM

Previous topic - Next topic

frithjofh

hello everybody,

I think I just found a bug in wxSmith and a behavior which is not exactly a bug, but annoying. the bug is reproduceable on my machine:
a) open a dialog in the wxSmith editor
b) change a setting like a property ( for instance change from wxSUNKEN_BORDER to something else)
c) close the wxs file without saving
result: c::b crashes

the annoying behavior is that whenever you mark a new object in the wxSmith editor the properties dialog switches to the event tab. you switch back to the properties tab, select another item and it switches back to events tab. shouldn't be that way and wasn't before ...

I attach the crash report

regards

frithjof

[attachment deleted by admin]
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

oBFusCATed

Quote from: nausea on June 20, 2010, 07:30:32 PM
I think I just found a bug in wxSmith and a behavior which is not exactly a bug, but annoying. the bug is reproduceable on my machine:
a) open a dialog in the wxSmith editor
b) change a setting like a property ( for instance change from wxSUNKEN_BORDER to something else)
c) close the wxs file without saving
result: c::b crashes
Confirmed on gentoo linux 64bit, the debuggers branch

Quote from: nausea on June 20, 2010, 07:30:32 PM
the annoying behavior is that whenever you mark a new object in the wxSmith editor the properties dialog switches to the event tab. you switch back to the properties tab, select another item and it switches back to events tab. shouldn't be that way and wasn't before ...
Agreed, it is extremely annoying...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

MortenMacFly

Unconfirmed on Windows. For me it works like expected. Is this a Linux issue, probably? Please ALWAYS state the platform you are using...
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

Jenna

The first (crash) does not happen for all properties, but at least for style wxSunkenBorder in a wxDialog.

The second (always show event-tab) is there since the newer version of wxPropGrid in the debugger-branch and is now in trunk also.
Might also be related to the move of wxPropGrid into sdk, but I do not think, that that is the cause.

What's more if the properties tab gets opened the first time, the left part (with the properties names) is very small and has to be resized to be usable, but remembers the size until C::B is closed.

Happens for me on linux (debian 64-bit) and windows (xp sp3) in the exact same way.

The crash is in propgrid.cpp line 7441.
If I try to step into OnMeasureImage it crashes.
m_wndEditor is 0 (would lead to an assert in debug-mode), but p seems to be valid (at least not null or some other typical value.
A breakpoint in OnMeasureImage is not reached if the crash appears.

Crash report attached.

[attachment deleted by admin]

frithjofh

I kindly ALWAYS include all information about my working environment in my signiture.
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

oBFusCATed

Probably this is not a good practice, because signatures change over time, but the posts stay the same.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Jenna

A possible patch (against trunk) for the crash is attached, that hopefully does not break anything.
It's not well tested (not at all on windows), but seems to work.


[attachment deleted by admin]

stefanos_

Crashing regards to wxSUNKEN_BORDER is reproducible under Windows XP SP3 with the latest revision (6384).

I have also tested it on 6379 and the crashing remains the same. I have also applied the patch and nothing new is happening; the bug remains the same.

Specs:

OS:                  Windows XP Professional SP3
Compiler:           TDM's GCC 4.5.0
wxWidgets:        wxMSW-2.8.10