文章詳情頁
python3 PyQt5 多線程報錯,QObject: Cannot
瀏覽:68日期:2022-06-29 08:53:20
問題描述
錯誤信息如下:`QObject: Cannot create children for a parent that is in a different thread.(Parent is QTextDocument(0x27e4150), parent’s thread is QThread(0xc306a0), current thread is QThread(0xc0eca0)`求解。。有沒有遇到這種問題情況?
問題解答
回答1:GUI相關的對象不能在非GUI的線程創建和使用,是非線程安全的
排行榜
