PDA

View Full Version : A strange set of characters appearing



bruccutler
3rd April 2007, 18:50
Hello,
I have attached a copy of a layout that is showing the description of a group box on the screen.

I've also attached the .cpp file that is causing this.

Why is the string "Garbage Settin" appearing on this dialog. The string comes from line #83 of the attached suplicantsettings.cpp file.

- Bruce

bruccutler
3rd April 2007, 18:58
It appears that something is getting painted onto the screen, and this is the portion that gets left over.

Still not sure why or what is getting painted.

I am using QStackedWidgets on this page. Maybe it has something to do with that.
- BRC

marcel
3rd April 2007, 19:01
Where do you want to place pMainGroupBox?

Do you want it to appear right under the existing widgets?
If so, you should try adding the pMainGroupBox to the existing layout.

bruccutler
3rd April 2007, 19:31
The group box is appearing just fine exactly where I want it. This just appears out of no where.

marcel
3rd April 2007, 19:45
Well, something is going wrong.

Make sure there are no layout connections or parent/child relations between the two group boxes/QStackWidget pages( assuming you want the second group box appearing as a separate page in the stack widget ).

BTW, how do you add the widgets in the stack widget?

bruccutler
18th April 2007, 20:09
I've finally had time to get back to this. For some reason, now I'm seeing two stacked widgets on top of one another. I've set a breakpoint and the setCurrentIndex(x) for that page never gets called, but until it does, that page appears with all of the other pages.

Any ideas what might be causing this?

I'm doing a m_pStackedWidget = new StackedWidgetConfig();
m_pStackedWidget->addWidget()
...
m_pStackedWidget->addWidget()

The one that is giving me the first is the second to last widget. The last one works just fine.

Is there a max number of widgets? Any other ideas would be appreciated.
- BRC

marcel
18th April 2007, 21:37
Could you post the code where you add the pages to the stacked widget?
Have you modified in any way your QStackedWidget subclass?

bruccutler
19th April 2007, 16:21
Found the problem. In my problem class, I was subclassing QDialog instead of QWidget.

Thanks for your help.
- Bruce