TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #175 · 30 окт.

В прошлом посте говоря "Все вызовы теперь одинаковы" я несколько слукавил. Всё-таки есть в этом зоопарке версий некоторая несовместимость вызов которой просто так не унифицировать. Эти моменты вынесены в отдельный модуль QtCompat (compatibility). Там не так много функций но они довольно полезны. Этот модуль содержит унификаци модуля shiboken2, функций loadUi, translate и несколько переименованных функций классов или изменённую сигнатуру аргументов и возвращаемых значений. Это единственное исключение из правила когда вам потребуется где-то изменить свой код кроме импортов и этот код не похож на обычный код PySide2. Например, в PyQt4 и PySide есть метод QHeaderView.setResizeMode Для PyQt5 и PySide2 они были благополучно переименованы в QHeaderView.setSectionResizeMode Чтобы применить этот метод следует использовать такой код from Qt import QtCompath header = self.horizontalHeader() QtCompat.QHeaderView.setSectionResizeMode(header, QtWidgets.QHeaderView.Fixed) Унификация загрузки UI файлов: # PySide2 from PySide2.QtUiTools import QUiLoader loader = QUiLoader() widget = loader.load(ui_file) # PyQt5 from PyQt5 import uic widget = uic.loadUi(ui_file) # Qt.py from Qt import QtCompat widget = QtCompat.loadUi(ui_file) Хорошо что таких моментов не много и их легко запомнить. Полный список можно посмотреть в таблице. #qt#tricks

Hashtags

Резултати

Пронајдени 2 слични објави

Пребарај: #truthonukraine

当前筛选 #truthonukraine清除筛选

@RusEmbMalta press release: Situation around #Ukraine. 🔷 Root causes of the conflict over Ukraine; 🔷 Role of the “collective West” countries; 🔷Western equipment and hostilities by the Kiev regime; 🔷 Settlement prospects; 🔷 Mediation initiatives; 🔷 Grain Deal; 🔷 Situation around the Ukrainian Orthodox Church of the Moscow Patriarchate (UOC MP); 🔷 About the conference in Switzerland. #TruthOnUkraine

@RusEmbMalta: On November 3, 2025, the Times of Malta published a commentary by the Russian Ambassador to Malta, Andrey Lopukhov, responding to the editorial of October 19, 2025 📰 In his commentary, Ambassador Lopukhov emphasized the importance of relying on verified facts when assessing the situation in Ukraine and warned against the spread of misinformation. Key points: 🔹 the so-called “Ukrainian crisis” began not in February 2022, but with the coup d’état in Kiev in 2014; 🔹 for years, the Kiev authorities pursued policies of discrimination and violence against Russian-speaking citizens; 🔹 the Odessa tragedy of May 2014 remains an uninvestigated crime; 🔹 Western arms supplies and financial support to Kiev only deepen the crisis; 🔹 Russia has consistently raised the issue of human-rights violations by the Kiev regime, despite the West’s unwillingness to listen; 🔹 millions of people around the world believed Russia – because truth, however suppressed, always breaks through lies and propaganda. 💬“There are facts that cannot be denied. And it is those very facts that made people across the world see what was happening with their own eyes and draw their own conclusions.” 🔗 Read the full text of the commentary onTimes of Malta. #UkrainianCrisis#TruthOnUkraine#TruthMatters