I have designed a QWidget
based QtDesigner ui form. Lets call it Form1. I added few pushbuttons and labels in it. Now I designed another QWidget based qt ui designer form.Lets call it Form2. I have a QFrame in Form 2 in which I would like to load Form1.
I did some reading and I found that I could right click on QFrame and choose promote to. I put the base class as QFrame. Promoted class name as Form1. Header file as form1.h.
I get errors now saying:
Form1 has no member named 'setFrameShape'
Form1 has no member named 'setFrameShadow'
I changed the base class as QWidget
. And it still did not load the Form1 in the QFrame of Form2
Any help is appreciated.
EDIT:
I used base class as QFrame
and
I commented out following lines in the ui_form2.h and it worked frame->setFrameShape()
and frame->setFrameShadow()
and it worked.
If there is better way to do it kindly let me know