[Qt-interest] Screen Getting White
Srdjan Todorovic
todorovic.s at googlemail.com
Tue Apr 21 14:54:36 CEST 2009
Hi,
2009/4/21 Sujan Dasmahapatra <sdh at lmglasfiber.com>:
> I am into the development of an engineering software where I am loading
> multiple geometries from the QFileDialog and displaying them on the main
> window and at the same time the file names are being uploaded onto the
> QTableWdiget one by one. I am using a QGraphicsScene and QGraphicsView which
> is used for display, the default Scene color is black..Everything is going
Why is the default colour black? Where is that in the code?
> fine but sometimes when I load a geometry the screen is getting white and no
> geometries are found.But actually the geometries are there and filename is
> nicely uploaded in my QTableWidget. If I continue the operation and if I
> load another geometry next then all the geometries are coming back on the
> screen and all are visible.I am facing this problem severely.
>
> I thought that I am not refreshing the screen during and
> after loading the geometry so I am calling “qApp->processEvents()” before
> and after loading the geometry as one of our friends suggested but it’s
> still happening and I am fade up with this bug.Please help me somebody.
Wouldn't you need to call update() to make sure the widget is painted?
>
> Some codes I am writing here for understanding.
Most of the code deals with loading the points, and creating your
geometry objects.
I'd guess the code posted is mostly irrelevant.
Can you reduce the code to a small self-contained program that we can
all compile and test?
> geometry.append(new Geometry(numberOfPoints,dataPoints));
>
> file.close();
>
> delete x;
> delete y;
Not delete y[] ?
Regards,
Srdjan
More information about the Qt-interest-old
mailing list