Chris, Marc, thank you for your helpful insight.
Marc, your solution is the perfect one for me, as you suggest addWidget does the job:
frmRealParts = new CRealPartsForm(this); // add form with Real parts
ui->stackedWidget->addWidget( frmRealParts, "Realparts" );
frmDistParts = new CDistPartsForm(this); // add form with Distributor parts
ui->stackedWidget->addWidget( frmDistParts, "Distributor" );
frmRealParts = new CRealPartsForm(this); // add form with Real parts
ui->stackedWidget->addWidget( frmRealParts, "Realparts" );
frmDistParts = new CDistPartsForm(this); // add form with Distributor parts
ui->stackedWidget->addWidget( frmDistParts, "Distributor" );
To copy to clipboard, switch view to plain text mode
Apart from improved partitioning in the designer and code, this approach also has two other very real advantages for me:
1. I can add tabs and stacked widget pages on the fly as the user requires them;
2. If it turns out the UI is better served for some pages as a modal / modeless dialog, I can just call ->exec() or ->show() instead!
Thanks again!
Bookmarks