View Single Post
Old 07-13-2014, 10:28 AM   #82
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,682
Karma: 205039118
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Since the QString method isEmpty() is gone in PyQt5, what would be the equivalent of:
Code:
if QLineEdit.text().isEmpty();
That will work in 4 and 5?

Is it as simple as:
Code:
if not unicode(QLineEdit.text()):
?

Or even
Code:
if not QLineEdit.text():
or
Code:
if not len(QLineEdit.text()):

Last edited by DiapDealer; 07-13-2014 at 10:39 AM.
DiapDealer is offline   Reply With Quote