On 2009-02-03 20:30:57 +0100, Niti Hantaweepant <[email protected]> said:
>
> Hi everyone,
>
> I've built Qt 4.5 on Mac Leopard with -arch cocoa flag. With the built Qt f=
> ramework using the Cocoa framework, without changing any code I got the sig=
> nal "EXEC_BAD_ACCESS" at QPaintEngine::setSystemClip when running my applic=
> ation.
>
> The call stack is attached below. Basically the following line is the code =
> in main.cpp.
>
>
> result =3D app->exec(); // app is QApplication object
>
>
> Before running into this EXEC_BAD_ACCESS, the program tried to create a new=
> QScrollArea/QWidget as a child to QMainWindow, the following are the code =
> executed before:
>
>
>
> DocWindow *AppWindow::createDocWindow() // AppWindow is a class inherited=
> from QMainWindow
>
> {
>
> DocWindow *child =3D new DocWindow(this); // DocWindow is an object of cl=
> ass inherited from QScrollArea
>
>
>
> workspace->addWindow(child); // workspace is a pointer to QWor=
> kspace object
>
> connect(child, SIGNAL( aboutToClose( DocWindow* ) ), this, SLOT( docWindowC=
> losing( DocWindow* ) ));
>
> }
>
> DocWindow::DocWindow( AppWindow* appWin ):
> fAGMArea( new AGMArea( this ) )
> {
>
> setAttribute(Qt::WA_DeleteOnClose);
>
> setAttribute(Qt::WA_InputMethodEnabled );
>
> setWidget( &(*fAGMArea) ); // fAGMArea is an object of class inher=
> ited from QWidget
> }
>
> Can you please advise what could go wrong here and if I need to change my c=
> ode to use the new Qt with Cocoa framework? Note that this code works fine =
> with Qt 4.4.3 using Carbon framework. Qt support suggested the code should =
> work in the same way with Qt 4.4 and I should send this query to this list.
Hi Niti,
I believe this was fixed late last week. Basically, you have a widget
that returns a null paint engine and we weren't taking care of that
situation in the Cocoa port. I'd advise trying the lastest snapshot and
seeing if that solves your problem.
-- Trenton
_______________________________________________
Qt4-preview-feedback mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt4-preview-feedback