Hello, recently i created a variable 'x' that changes whenever i run the script. Now i want it to be displayed on my .ui widget i created in qt. I know how to call an input text box value from qt to qcad script but i couldn't manage to change this value and display it on my widget.
In other words, briefly i want qt lcd display number changes with respect to script variable whenever i run the code
Is there a sample script for that? or a function?
Thanks.
Put a variable on qt's display widget
Moderator: andrew
Forum rules
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
Re: Put a variable on qt's display widget
QLCDNumber has a property called digitCount:
http://doc.qt.io/qt-5/qlcdnumber.html#digitCount-prop
So if w if your LCD widget, you can simply do:
w.digitCounter = x;
http://doc.qt.io/qt-5/qlcdnumber.html#digitCount-prop
So if w if your LCD widget, you can simply do:
w.digitCounter = x;