Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Importing json in listwid with colored text & after clearing the listwid and importing new data an error is prompted
blossomsg last edited by blossomsg
Past couple of days i have been trying to color text which are already imported in listwid
- i have created a json file in which all the data(dict) is stored
- i clear the existing data from the listwid, an error is prompted currently not the concern but still a point which needs to be fixed
# File "E:\Proj_Codes\NitinProj\vacuum_cleaner\vacuum_cleaner_delegate.py", line 47, in vacuum_cleaner_textedit_values # self.vacuum_cleaner_listwid.currentItem().text()))) # AttributeError: 'NoneType' object has no attribute 'text'
and import the updated data in the wid
3) so here is the issue after importing the new json data(dict) i want to show the wrong values in red and correct in green inside listwid
i know "listwidgetitem" but after reading json file i have no clue how can i apply color to text
This tool is for maya with pyside2
suggestions would be great and with an example would be cherry on the cake
Check that the item returned by
is not Noneand continue your code only if it's the case.
blossomsg last edited by
Thank you for your help
i used ".disconnect" to disconnect the previous json and then import the new json file
GersonHdez Banned last edited by
This post is deleted!