Hi
Widget Promotion
Based on several forums I managed to promote a graphicsView accordingly.
The issue comes when within the promoted class I need to create a QLabel (within the graphicsView) that itself needs to be promoted.
1. Promote Graphics View (through the designer)
2. Add QLabel Widget within graphicsView (programatically)
3. try to promote the generated label (That is within the graphicsView) to another class in codeQt Code:
label->setFixedSize(320, 320); label->setText("Test Label"); proxy = myScene->addWidget(label); proxy->setZValue(0);To copy to clipboard, switch view to plain text mode
Since i only have access to the label in the code and not via the designer.
How do I promote a QLabel to a specified class within code? (Not through the designer)
Your assistance is appreciated
Regards
Bookmarks