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

Резултати

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

Пребарај: #khartoum

当前筛选 #khartoum清除筛选
Addis Standard

@addisstandardeng · Post #21065 · 14.01.2026 г., 05:51

#Sudan police unveil Khartoum security plan as government returns Sudan’s police on Tuesday outlined a sweeping security plan to protect the seven localities of #Khartoum state, hours before the cabinet and most federal ministries complete their relocation from the wartime seat of Port Sudan. Brigadier-General Fath al-Rahman Mohamed al-Tom told Sudan Tribune the force will deploy additional officers, reactivate criminal-investigation units and relaunch the “999” emergency call centre to handle civilian complaints. “Public facilities, bridges and river crossings are priority targets for protection,” al-Tom said, adding that patrols, fixed checkpoints and daily raids had already “dismantled a major cell in East Nile” and delivered “a measurable drop in crime”. He said the police command had introduced “modern technology” to monitor deployments and pledged “immediate disciplinary action” against any officer found in violation of regulations.... https://sudantribune.com/article/309333

Addis Standard

@addisstandardeng · Post #21272 · 02.02.2026 г., 06:41

News: #Khartoum airport receives first scheduled flight since start of Sudan war The international airport in Khartoum has received its first scheduled commercial flight in more than two years as the #Sudanese government continues to assert its control over Sudan’s capital city after years of fighting. The Sudan Airways flight travelled to Khartoum from the Red Sea city of Port Sudan on Sunday, carrying dozens of passengers. Reporting from near the runway where the flight had landed, Al Jazeera’s Taher Almardi described scenes of jubilation following the arrival of the plane. He said the reopening of the airport will help connect the capital to other regions in Sudan, with officials saying the facility is now ready to welcome as many as four flights daily. Sudan Airways said in a statement that the flight, which was announced on Saturday with ticket prices starting at $50, .... https://web.facebook.com/AddisstandardEng/posts/pfbid021sHpU1gGTz2SZF2qejYi6G1D3siDnLwXXK2hcCEsiHW1Qb8ADaaB8tGA4kq2MvEZl

Addis Standard

@addisstandardeng · Post #21506 · 24.02.2026 г., 05:04

#Khartoum resumes school year after three-year war-induced hiatus Schools in Khartoum state reopened this week after a three-year hiatus caused by #Sudan’s civil war, as officials scramble to repair hundreds of damaged buildings and accommodate a surge in returning students. The Khartoum State Ministry of Education said on Monday that approximately 280 schools in the capital were damaged or destroyed during the conflict, which broke out in April 2023 between the Sudanese army and the paramilitary Rapid Support Forces (#RSF). Many schools were repurposed as shelters for displaced families or occupied by warring factions, while the displacement of teachers & students led to a total collapse of the city’s educational system. Qariballah Mohammed Ahmed, Khartoum’s director of education, told Sudan Tribune that more than one million students are expected to enrol this year as families gradually return to the capital’s relatively stable neighbourhoods. “The number of... https://sudantribune.com/article/311035

Addis Standard

@addisstandardeng · Post #21184 · 26.01.2026 г., 05:31

#Sudan hospital welcomes first patients after war forced it shut At a freshly renovated hospital in #Khartoum the medical team are beaming: nearly three years after it was wrecked and looted in the early days of Sudan's war, the facility has welcomed its first patients. The Bahri Teaching Hospital in the capital's north was stormed by the paramilitary Rapid Support Forces in April 2023, soon after fighting broke out between the #RSF and Sudan's army. Bahri remained a war zone until an army counteroffensive pushed through Khartoum last year, recapturing the area from the RSF in March. "We never thought the hospital would reopen," said Dr Ali Mohamed Ali, delighted to be back in his old surgical ward. "It was completely destroyed, there was nothing left," he told AFP. "We had to start from scratch." Ali fled north from Khartoum in the early days of the war, working in a makeshift... https://web.facebook.com/AddisstandardEng/posts/pfbid0XGAcYjM8H8QZz4QCfQg6MRikKWJ89wV7gkm8xnEGntQfyvMvQBw2BsjXo8pPYgDQl

Addis Standard

@addisstandardeng · Post #21585 · 02.03.2026 г., 19:56

News: #Sudan government alleges drone attacks originated ‘from #Ethiopian territory,’ warns of action to defend sovereignty Sudan has accused Ethiopian authorities of allowing #drones to enter its airspace from Ethiopian territory and strike locations inside the country, warning of consequences and asserting its right to defend its sovereignty and territorial integrity. In a press release issued on Monday, 02 March 2026, the Ministry of Foreign Affairs and International Cooperation said the Government of Sudan had been monitoring what it described as the “entry of drones from within Ethiopian territory” throughout February and early March. #Khartoum warned Ethiopian authorities of what it called the consequences of such acts and reaffirmed Sudan’s right to defend its sovereignty “by all means necessary” to counter the alleged attacks. The ministry characterized the reported incidents as “hostile behavior” that …. Read more: https://addisstandard.com/?p=55508

Addis Standard

@addisstandardeng · Post #21041 · 12.01.2026 г., 06:49

#Sudanese gov't returns to #Khartoum after nearly 3 years of war Sudanese Prime Minister Kamil Idris on Sunday announced the return of the government to the capital, Khartoum, for the first time since the outbreak of war on April 15, 2023, after nearly three years of running state affairs from the eastern city of #Port_Sudan. "The government has returned to the national capital," Idris said in a speech to a crowd following his arrival in Bahri, north of Khartoum. He pledged to improve basic services, particularly in the health and education sectors, and to rebuild hospitals and rehabilitate schools and universities, foremost among them the University of Khartoum. The prime minister added that 2026 would be "the year of peace in Sudan," pointing to plans for reconstruction and development, as well as efforts to improve the economic situation by increasing gross national product, reducing inflation, and stabilizing the exchange .... https://english.news.cn/20260111/57d8cfd50a314aa4bcd1e90564c45698/c.html

Addis Standard

@addisstandardeng · Post #22111 · 25.04.2026 г., 08:28

Regional coalition in #Khartoum calls for peace, dialogue across #Sudan, #Eritrea, #Ethiopia Addis Abeba - A regional coalition bringing together representatives from Sudan, Eritrea, and Ethiopia has called for “peace, coexistence, and an end to ongoing conflicts”, during a public gathering held in Khartoum on 23 April, according to Sudan News Agency. The alliance, identified as the Coalition of the Peoples of Eritrea, Sudan, and Ethiopia, said the meeting reflected “the aspirations of the region’s peoples to live in peace and stability,” while promoting “the values of coexistence” and rejecting “hatred and conflict,” the outlet reported. Speakers and representatives drawn from various communities, including #Tigray, #Amhara, #Oromo, and #Somali constituencies, alongside delegates from Sudan and Eritrea, expressed a “unified stance against continued violence”. https://www.facebook.com/AddisstandardEng/posts/pfbid02sbMgZToVXPCPWfPjK8AQZCYEPVV7SZnsgP8oymTw5Hoajfw75J6qukUrXuV3oLShl

Addis Standard

@addisstandardeng · Post #21576 · 01.03.2026 г., 14:32

#Updates: #Sudan condemns #Iranian missile strikes but excludes #UAE; Trump Threatens with ‘Force Never Seen Before’ if Tehran Retaliates #Khartoum has issued a sharp diplomatic rebuke of Iran’s recent ballistic missile assault on #Gulf states — condemning attacks on #Qatar, #Bahrain, #Kuwait and #Jordan while conspicuously excluding the United Arab Emirates amid strained ties — as #US President Donald #Trump warned that Iran would face a level of force “never seen before” should it pursue further retaliation following the reported death of Supreme Leader Ali Khamenei. #Israel and the United States launched fresh waves of intensive strikes across Iran on the second day of their military campaign, escalating a confrontation that has plunged the Middle East into a rapidly widening regional conflict with no clear timeline or outcome. Sudan’s Ministry of Foreign Affairs on Saturday ..... https://web.facebook.com/AddisstandardEng/posts/pfbid0Akn9sXbPsGrVeyGeKmTrs5TUWEEWyvD83ttZhBmRbcUXNFyYkFBG4VmHmjAAvJzpl

Addis Standard

@addisstandardeng · Post #21964 · 07.04.2026 г., 12:56

News: Federal police charge suspected trafficking kingpin linked to deaths, abuse of migrants Addis Abeba —#Ethiopian Federal Police said it has referred to prosecutors the case of human trafficking kingpin #Yitbarek_Dawit (Kibrom) and nine accomplices, accused of orchestrating a cross-border network that trafficked more than 3,000 people and was linked to over 100 deaths and the rape of more than 50 women. In a statement, police said the suspect, described as an internationally wanted fugitive, was arrested in #Shire town in the #Tigray region following a coordinated operation conducted with the Regional Operational Centre in support of the #Khartoum Process. Authorities said the investigation involved extensive intelligence-sharing across multiple countries. Police said the suspect used multiple identities to evade capture, including names such as #Yitbarek Dawit Alemu, #Paulos Dawit Wolday, and aliases including #Adhanom, #Ahmed, #Munir, and Read more: https://web.facebook.com/share/p/1Arn3MFntC/