PyQt pass data from class

Michael Torrie torriem at gmail.com
Tue Nov 15 13:41:53 EST 2016


On 11/15/2016 10:01 AM, luca72 via Python-list wrote:
> in wich way i can have access to the lineedit of class Form without event from class Cornice

If I understand you, you are asking how to set the text without having
it emit a signal. Is that correct? Or are you asking how to access the
member of one class from a method in another class?

If it's the former, you can ask PyQt to suppress a callback for a while.
 Look up the blockSignals() method of QWidget.

If it's the latter, your best bet is to pass the object you want to
access into the other class somehow, perhaps as an argument to __init__().




More information about the Python-list mailing list