|
|
Im using QT 4.1.2. I have a fully working CanvasView
that contains a Canvas. Im adding a feature to save off
all my objects into an XML file and re-load that file
(or any other file Ive saved) and re-start the screen
with the file objects.
I delete the Canvas and CanvasView pointers and try to
restart the whole thing. What happens is that that
only the Q3CanvasText items I have within my main objects
(which are all Q3CanvasRectangles) show up, but the
rectangles themselves do not show up at all.
Ive verified that I have show() and the QBrush and
QPen's set properly. As I said it works properly when the
code is first brought up but I am missing something to
re-start the screen for my canvasrectangles (unless this
is a bug?).
Here's my QMainWindow subclass that restarts the view:
void
MainWindow::restart()
{
//cout << "Restart screen" << endl;
delete _canview;
delete _canvas;
_canvas = new Canvas(_parent);
_canview = new LayoutView(_group,_list,_canvas,_parent);
setCentralWidget(_canview);
setEnabled(true);
show();
repaint();
}
Thanks,
Jeff
--
To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
"unsubscribe" in the subject or the body.
List archive and information: http://lists.trolltech.com/qt-interest/
|
|