[Qt-interest] Setting text of Commit button in QWizard does not work?

Andre Somers andre at familiesomers.nl
Wed Apr 28 11:45:10 CEST 2010


Hi,

In my wizard, quite a number of pages are commit pages. I don't like the 
word "Commit" on the buttons in the wizard though. It is too technical, 
and it looks scary to some users. Luckely, QWizard offers access to it's 
buttons using its button() method.

Now the weird thing:

(within a QWizard subclass):
     button(QWizard::CommitButton)->setText(tr("Bar"));
     button(QWizard::NextButton)->setText(tr("Foo"));

The first line does not work, the second does. That is, there are no 
compilation issues, but the text of the commit button does not change.

Am I missing something here, or is Qt misbehaving?

André




More information about the Qt-interest-old mailing list