> Message: 1 > Date: Tue, 23 Jun 2009 14:41:20 +0200 > From: "V. Armando Sol?" <[email protected]> > Subject: Re: [PyQt] Pressing enter in QLineEdit clicks QPushButton? > To: Mads Ipsen <[email protected]> > Cc: Sibylle Koczian <[email protected]>, PyQt-Liste > <[email protected]> > > Mads Ipsen wrote: >> rom the manual pages: >> >> "A dialog's default button is the button that's pressed when the user >> presses Enter (Return). This button is used to signify that the user >> accepts the dialog's settings and wants to close the dialog." >> >> In other words, the first button that gets added probably gets >> connected up with this behaviour, which explains the behaviour. So >> using a QWidget is probably the correct solution: >> > > It is certainly not the correct solution if you really need a dialog :-) >
Right, but in this case I don't need a return value from my window and so I don't think I need a dialog. This is a small application with only one form. > You can also call setAutoDefault(False) for all the buttons. > Yes, just tried it, that works too. So, this being solved, on to the next problem I won't be able to solve for myself. Thank you, Sibylle _______________________________________________ PyQt mailing list [email protected] http://www.riverbankcomputing.com/mailman/listinfo/pyqt
