News:

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

Main Menu

INCOMPATIBILITIES between wx2.4 and wx2.6

Started by rickg22, May 27, 2005, 05:49:05 PM

Previous topic - Next topic

rickg22

Why not try adding a sizer to it? :) You don't lose anything.

DreadNot

The EditorManager's wxNotebook is for the editor--I don't think its related to the problem.

Manager holds a wxSplitPanel (a C::B class) which holds a wxSplitterWindow.
EditorManager and ProjectManager both call the global Manager for the wxSplitPanel which in turn provides the wxSplitterWindow.  Each adds their own wxTreeCtrl to the wxSplitterWindow.

I think the problem is specifically with the ProjectManager's wxTreeCtrl, but I am confused as to why?  They approach content differently--adding items, building, rebuilding, ext.--but they are similar.

DreadNot

I've recompiled with a current CVS update of HEAD.  Here are the wx2.6.1 incompatabilities so far.

I'm getting a compile error for wxHandleFatalExceptions():
Quotesrc\app.cpp: In member function `virtual bool CodeBlocksApp::OnInit()':
src\app.cpp:214: error: `wxHandleFatalExceptions' undeclared (first use this function)
src\app.cpp:214: error: (Each undeclared identifier is reported only once for each function it appears in.)
I seems that "wxHandleFatalExceptions()" is only defined when "wxUSE_ON_FATAL_EXCEPTION" is set to 1.  Its only supposed to be used when the compiler "supports Win32 structured exception handling (currently only VC++ does)" .  Its defined in wx/msw/chkconf.h as follows (due to the use of mingw):
#if !defined(_MSC_VER) && \
   (!defined(__BORLANDC__) || __BORLANDC__ < 0x0550)
   #undef wxUSE_ON_FATAL_EXCEPTION
   #define wxUSE_ON_FATAL_EXCEPTION 0
...

To check in app.cpp, I've changed/added the code as follows:
bool CodeBlocksApp::OnInit()
{
   m_pSplash = 0;
#if wxUSE_ON_FATAL_EXCEPTION // <-- added
   wxHandleFatalExceptions(true);
#endif // <-- added
   if(!LoadConfig())
       return false;

Also getting warnings in EditorManager:
Quotesdk\editormanager.cpp: In constructor `EditorManager::EditorManager(wxWindow*)':
sdk\editormanager.cpp:124: warning: `__comp_ctor' is deprecated (declared at ../../wxWidgets/wxWidgets-2.6.1/include/wx/sizer.h:788)
sdk\editormanager.cpp: In member function `void EditorManager::ActivateNext()':
sdk\editormanager.cpp:443: warning: comparison between signed and unsigned integer expressions
sdk\editormanager.cpp: In member function `int EditorManager::FindPageFromEditor(EditorBase*)':
sdk\editormanager.cpp:643: warning: comparison between signed and unsigned integer expressions

DreadNot

Due to the DLLIMPORT changes in editorbase.h, anytime editorbase.h is directly included (such as in wxSmith), the including file must also include settings.h before editorbase.h in order to properly define DLLIMPORT.

Having editorbase.h include settings.h directly may be a cleaner solution (maybe?)

mandrav

Quote from: DreadNotI seems that "wxHandleFatalExceptions()" is only defined when "wxUSE_ON_FATAL_EXCEPTION" is set to 1. Its only supposed to be used when the compiler "supports Win32 structured exception handling (currently only VC++ does)" . Its defined in wx/msw/chkconf.h as follows (due to the use of mingw):
I noticed it too. The funny thing is that under wx2.4 this function is defined and working as expected with MinGW. Under Linux (gcc) too. So it seems that gcc works with it. I don't know.

Quote from: DreadNotHaving editorbase.h include settings.h directly may be a cleaner solution (maybe?)
Yes, probably.

Yiannis.
Be patient!
This bug will be fixed soon...

DreadNot

Apparently, a patent exists for SEH.  Therefore, it may have been changed due to this:
http://www.builderau.com.au/program/work/0,39024650,39188400,00.htm

mandrav

Quote from: DreadNotHaving editorbase.h include settings.h directly may be a cleaner solution (maybe?)
Added it in CVS.

Yiannis.
Be patient!
This bug will be fixed soon...

DreadNot

Quote from: DreadNot on June 09, 2005, 09:14:29 AM
I've compiled with wx2.6.1.

Problem 1: In the Workspace area I see no workspace/project tree displayed.  Its there!  I just can't see it!  It is invisible!!!  I can right-click on items in the tree in their approximate location and a get the popup menus!  What a cruel trick to play on me!  Who set the color codes for this? :D The Symbol tree appears OK.  No Watches tree since I'm not debugging.  I'm also compiling wxSmith.  The Resources tree seems OK so far for what it is.

NOTE: I'll get memory exceptions out of nowhere if I let the application sit long enough after opening a project.  Maybe the thread to display the workspace/project tree is failing somehow!?

Problem 2: I'm assuming that with the notebook version, the Min/Restore/Close triplet buttons for the file are missing.  In the old system, I could "sometimes" get them after screwing around with the display (minimizing, then maximizing, etc).  Should the notebook have
  • buttons on the file tabs? I can right click in the file area to close.

    Problem 3: When I try to minimize the application from a maximized window, the application gives a memory exception and crashes.  When I minimize from a non-maximized (restored) window, there is no fault.

    Other: I still get the Run... problem (must debug before I can run--run without doing one initial debug causes a memory exception).

    So far, these are the only problems I've encountered.  Is there anything else specifically I should be looking for?
UPDATE:
I've compiled with wx2.6.1 with the patch.
Problem 1 seems to be gone!
Problem 2 still exists--I think I've read in another post that this is a wx design issue with wxNotebook and that we may need to create a workaround.  This seems like a missed or undocumented setting for the tab.
Problem 3 seems to be gone!
I'm guessing Other is gone as well.

rickg22

Dreadnot: On the VERSION_1_0 branch, I've added a "close button". It's in the environment settings, but it's very ugly. It was the only way I could do it, tho.

DreadNot

Yes.  I notice that in another thread.  I also responded with a possible solution following the track Yannis took in trying to put the button in the tab area.  See http://forums.next.codeblocks.org/index.php/topic,633.msg4646.html#msg4646 for more.

This seems to be a dead thread (at least for me) since all new development is currently using wx2.6+ and the major incompatability problems seems to have been resolved.  I still get the warnings for comparing signed and unsigned integers in editormanager.cpp