В прошлом посте говоря "Все вызовы теперь одинаковы" я несколько слукавил. Всё-таки есть в этом зоопарке версий некоторая несовместимость вызов которой просто так не унифицировать. Эти моменты вынесены в отдельный модуль 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
#OlympicGames
В останній день Олімпіади в Мілані-Кортіні проходить одне з найбільш очікуваних видовищ цьогорічних змагань - фінал з хокею між збірними Канади і США.
Обидві команди прогнозовано дісталися поєдинку за золото, хоча й не сказати, що без певних складнощів на цьому шляху.
Поєдинок розпочинається цими хвилинами. Також сьогодні згадуємо перші секунди матчу команд США і Канади в рамках турніру NHL 4 Nations Face-Off, що проходив у лютому 2025 року, тимчасово замінивши собою щорічний Матч всіх зірок НХЛ.
В турнірі брали участь команди Фінляндії, Швеції, Канади та США, що складалися виключно з гравців Національної хокейної ліги. Перші 9 секунд поєдинку між головними претендентами перетворились на бійцівський турнір на льоду, ставши вже легендарними.
Сьогодні 🇺🇸 та 🇨🇦 знов один проти одного.
відео: ESPN
#OlympicGames
Вчора відбулось відкриття Олімпіади-2026 в Мілані.
Основна частина Церемонія відкриття 25-ї зимової Олімпіади Мілан-Кортіна пройшла на футбольному «Сан-Сіро». Однак італійці цікаво та незвично підійшли до організації дійства, розширивши проведення заходу на 4 локації. Окрім легендарного футбольного стадіону, церемонія проходила також у Кортіні-д'Ампеццо, Предаццо та Лівіньйо.
Прапороносцями збірної України були шорт-трекістка Єлизавета Сидьорко та скелетоніст Владислав Гераскевич.
Під час виходу збірної України у Кортіні, Гераскевич вказував пальцем на прапор. Як повідомляють ЗМІ, перед початком Олімпіади Міжнародний олімпійський комітет просив українського спортсмена не влаштовувати протестних акцій під час церемонії. Раніше Владислав закликав до підписання петиції про запровадження санкцій проти російських спортсменів.
Зимові Ігри триватимуть до 22 лютого. Україну представлятимуть 46 учасників з 11-ти видів спорту. Наші спортсмени змагатимуться в біатлоні, санному спорті, фристайлі, лижних перегонах, лижному двоборстві, гірськолижному спорті, стрибках з трампліна, шорт-треку, фігурному катанні, скелетоні і сноубордингу.
🏃♂️🏃♂️🇷🇺Simple math: calculating Russia's chances at the 2026 Olympic Games
With less than ten days before the Milan–Cortina 2026 Winter Olympics, Russia enters the Games with one of its smallest delegations in history. After years of restrictions and late easing of international isolation, 13 athletes will compete — many without full international rankings, raising the question: are podium finishes realistic or merely symbolic?
✍️Diana Yuknelite
Senior Research Assistant, Institute of China and Contemporary Asia of the Russian Academy of Sciences (ICCA RAS)
➡️The path to admission has been politically charged. While the IOC recommended allowing Russian and Belarusian juniors, some federations — notably the IIHF — resisted, citing “security” concerns. At the same time, precedents such as the relocation of the European Fencing Championships from Estonia to France, after Tallinn refused entry guarantees, signal a gradual shift in the international sports climate. Economically and diplomatically, the Olympic return remains limited, but the fact of participation itself reflects a cautious normalization of Russia’s presence in global sport.
The results will be on the scoreboard, but our support will stay with them much longer. We are with you with all our heart, soul, and thoughts!
➡️The delegation of 13 athletes — the smallest since 1908 — spans cross-country skiing, figure skating, ski mountaineering, short track, speed skating, luge, and alpine skiing. Figure skaters Adelia Petrosyan and Petr Gumennik are considered medal contenders, though the absence of international rankings places them in early warm-up groups, complicating competitive positioning. Ski mountaineer Nikita Filippov arrives after a World Cup bronze in France, while speed and luge athletes have shown top-20 and occasional top-10 results during comeback seasons. Statistically, podium probabilities remain modest, but breakthrough performances cannot be ruled out given recent upward trends.
🟦The greater challenge lies in expectations. Admission alone is not victory, and excessive political or public pressure could undermine athletes competing after years of isolation. Milan–Cortina 2026 will test not only physical preparation but psychological resilience and institutional adaptation. Even limited medal success would mark a strategic step toward full reintegration into international sport, while broader participation itself serves as an indicator of shifting global sports governance dynamics.
#Europe#OlympicGames#Russia
READ MORE
✅@NewEasternOutlook
به عنوان یک ایرانی و دنبالکننده بازیهای المپیک، برایم ناخوشایند است وقتی میبینم نزدیک به نیمی از اعضای تیم پناهندگان را ورزشکاران ایرانی تشکیل میدهند، و همزمان، ورزشکاران زن کشورمان، محبوس در پوشش اجباری، در شرایطی نابرابر باید با ورزشکاران دیگر کشورها رقابت کنند. این شرایط، شایسته ورزشکاران ایرانی نیست. یقین دارم روزی دوباره همه ورزشکاران ایرانی با افتخار و آزادانه زیر پرچم ملی ایران در مسابقات المپیک و جهانی شرکت خواهند کرد، و با پشتیبانی یک ملت، مدالهای رنگارنگ را برای ایران به ارمغان خواهند آورد.
As an Iranian and a fan of the #OlympicGames, it is disheartening to see that nearly half of the members of the refugee team are Iranian athletes. Meanwhile, our female athletes are forced to compete under mandatory head coverings and restrictive clothing, putting them at a disadvantage. These conditions are unjust for Iranian athletes. They deserve better. I firmly believe that one day, all Iranian athletes will once again proudly and freely compete under the national flag of Iran in the #Olympics and other world championships, bringing home a multitude of medals with the support of a united nation.
@OfficialRezaPahlavi
«На спортивном Олимпе», холст на картоне, масло, digital art, Doping Pong, 2015
З августа 1980 года закрылись Игры XXII Олимпиады, проходившие в Москве, Ленинграде, Таллине, Киеве и Минске. Это были первые Олимпийские игры на территории Советского Союза. Столицей летних Олимпийских игр стала столица СССР - Москва.
Эстетика церемонии открытия и закрытия Олимпиады-80 была вдохновлена культурой Древней Греции и античными Олимпийскими играми.
В 2025 году мы отмечаем 45-летний юбилей XXII Летних олимпийских игр 1980 года.
#dopingpong#olympicgames#олимпиада80#москва80
📰🌐Good News. Liberated settlements, the lifting of the Cuba blockade, announcements of international programs, and other positive developments
In our regular column in NEO, we feature the most inspiring news of recent weeks—from Russian battlefield advances to the long-awaited delivery of oil to Cuba and Russian athletes triumphing at the Paralympics despite Western sanctions
✏️Ksenia Muratshina
is a Senior Researcher at the Institute of Oriental Studies of the Russian Academy of Sciences
➡️In the Special Military Operation zone, the Russian army continues liberating settlements from Ukrainian forces—Aleksandrovka, Potapovka, Veselyanka, Novoosinovo, and over twenty others in the Donetsk People's Republic, Kharkiv, Sumy, and Zaporizhia oblasts. Russian Foreign Ministry Ambassador Rodion Miroshnik addressed the UN Human Rights Council, presenting evidence of the Kyiv regime's crimes against Russian citizens. Russia also celebrated the 12th anniversary of Crimea's return—March 18, 2014, marked a special milestone, and the peninsula remains an outpost for defending state borders, a center of agriculture, industry, science, and tourism where brave, friendly people live.
Thus, in battle, a multipolar world is being born in the Middle East—a rebuff to Western tyranny that has perpetrated it for many years.
➡️Iran is methodically breaking the horns of the "Epstein coalition," adapting its defense system and striking back at American and Israeli aggressors in ways they never imagined. Every news of Iranian successes—downing an American F-35, reducing LUCAS drones to scrap, direct hits on aggressor targets—is good news. The Russian tanker Anatoly Kolodkin delivered 100,000 tons of oil to Cuba—humanitarian aid even more valuable because Russia was the first to defy American sanctions and support the Island of Freedom. Half of Russia's fertilizer exports now go to BRICS countries, with Brazil and India purchasing the largest volumes—growing trade aligns with BRICS objectives, prioritizing agricultural cooperation.
🟦People in 40 countries now have access to MAX, a Russian-powered alternative to Western social media—including Russia, Belarus, Indonesia, Turkey, UAE, India, Venezuela, and Cuba. Despite Western sanctions, the Russian Paralympic team—only six athletes—won eight gold medals, one silver, and three bronze in the Italian Alps, finishing third overall. After their triumphant return, they attended a reception with President Putin and received state awards. At the Milan Olympics, Israeli and US national teams were booed at the opening ceremony—demonstrating global condemnation of their war against Palestine. Finally, applications are now open for the International Summit of Young Diplomats in Artek (until April 10), the InteRussia internship for energy specialists from Latin America (until May 3), and several other international programs for youth, researchers, and journalists.
#Cuba#modernsociety#OlympicGames#Politicalcooperation#Russia
READ MORE
✅@NewEasternOutlook