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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #62 · 4 апр.

Когда разрабатываете свой GUI с помощью PyQt для какого-либо софта бывает необходимо позаимствовать цвета из текущего стиля интерфейса. Например, чтобы правильно раскрасить свои виджеты, подогнав их по цвету. Ведь бывает, что ваш GUI используется в разных софтах. Причём некоторые со светлой темой а другие с тёмной. По умолчанию стили наследуются, но если вы задаёте какую-либо раскраску для части виджета через свой styleSheet, то требуется ссылаться на цвета текущего стиля. Как это сделать? Как получить нужный цвет из палитры имеющегося стиля? Это достаточно просто, нужно использовать класс QPalette и его роли. Например, мне нужно достать цвет текста из одного виджета и применить его в другом как цвет фона (не важно зачем именно так, просто захотелось😊). Получаем палитру виджета и сразу достаём нужный цвет, указав его роль. from PySide2.QtGui import QPalette color = main_window.palette().color(QPalette.Text) теперь можем использовать этот цвет в стилях my_widget.setStyleSheet(f'background-color: {color.name()};') Готово, мы динамически переопределили дефолтный стиль используя текущий стиль окна! На самом деле есть запись покороче, в одну строку и без лишних переменных. Не очень-то по правилам CSS, но Qt это понимает. my_widget.setStyleSheet('background-color: palette(Text);') Этот способ не подходит если вам нужно как-то модифицировать цвет перед применением в своих стилях. В этом случае потребуется первый способ. Зато он прекрасно сработает в файле .qss, то есть не придётся в коде прописывать раскраску отдельных элементов через ссылки на палитру, всё красиво сохранится в отдельном файле .qss! QListView#my_widget::item:selected { background: palette(Midlight); } Про имеющиеся роли можно почитать здесь🌍 #qt#tricks

Hashtags

Резултати

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

Пребарај: #standardchartered

当前筛选 #standardchartered清除筛选
Venture Village Wall 🦄

@venturevillagewall · Post #4281 · 01.03.2025 г., 22:00

Bitcoin Predicted to Reach $200K Soon Standard Chartered's Geoff Kendrick forecasts Bitcoin will hit $200K this year and could reach $500K before Trump exits the presidency. Predictions reflect growing confidence in BTC's potential growth trajectory. #Bitcoin#Crypto#Finance#Investment#Prediction#Market#Trump#StandardChartered#DigitalAssets#GeoffKendrick

Venture Village Wall 🦄

@venturevillagewall · Post #4172 · 17.02.2025 г., 10:00

Joint Venture for HKD-Backed Stablecoin Standard Chartered, Animoca Brands, and HKT have established a joint venture to issue a HKD-backed stablecoin under Hong Kong’s new regulatory framework. This collaboration will leverage Standard Chartered Bank (Hong Kong)'s robust infrastructure and governance. More details can be found here: Animoca Brands. #Stablecoin#HongKong#Finance#Crypto#VC#StandardChartered#AnimocaBrands#HKT#Regulation

Crypto M - Crypto News

@CryptoM · Post #64926 · 10.04.2026 г., 10:15

🚀 Stablecoin Joint Venture Model Dominated by Banking Sector A joint venture in the stablecoin sector is primarily led by the banking industry. According to PANews, Standard Chartered Bank (Hong Kong) holds a 50.5% stake, making it the majority shareholder. Animoca Brands owns 37.5%, while Hong Kong Telecom indirectly holds 12% through Quality Champion Limited. This structure reflects a model where the banking sector leads, with support from technology and telecommunications. #Stablecoin#JointVenture#BankingSector#StandardChartered#AnimocaBrands#HongKongTelecom#Telecommunications#Technology#Banking#Blockchain

Venture Village Wall 🦄

@venturevillagewall · Post #3835 · 10.01.2025 г., 04:00

Russia to Sell Seized Bitcoin Assets The Russian Ministry of Finance plans to sell seized Bitcoin assets from the Infraud hacking case, starting with a batch valued at approximately $10 million. Marat Tambiev, a corrupt official, previously obtained 1,032.1 BTC from the hacker group. Read more here. #Bitcoin#Russia#Infraud#Crypto#DigitalAssets#Banking#Finance#Regulation#MiCA#Custody#StandardChartered#EU#Hacking#Seizure#MaratTambiev#CryptoNews#BTC#Blockchain#FinanceNews#News

Venture Village Wall 🦄

@venturevillagewall · Post #3974 · 24.01.2025 г., 19:00

Big Moves in Crypto Regulation News 🚀 US Senator Cynthia Lummis, a vocal Bitcoin advocate, elected Chair of the Senate Digital Assets Committee. Proposed strategic Bitcoin reserve hints at potential significant moves for Bitcoin. Meanwhile, Trump's recent crypto executive order suggests a reserve of 'seized digital assets,' increasing speculation around Bitcoin's future. 🔗 For further details, read the article here. 🔗 In additional news, the SEC has opened the door for Wall Street banks to hold crypto. 🔗 Standard Chartered forecasts Bitcoin could reach $200,000 by the end of 2025. 🔗 Japan's Central Bank raised interest rates to a 17-year high, now at 0.5%, causing ripples across markets, including crypto. #Crypto#Bitcoin#US#Regulations#SEC#InterestRates#Japan#Senate#DigitalAssets#Investment#FinancialMarkets#WallStreet#Speculation#CynthiaLummis#CryptoBanks#PanteraCapital#StandardChartered#Ethereum#AI#VC

Venture Village Wall 🦄

@venturevillagewall · Post #4074 · 05.02.2025 г., 16:00

Crypto Market Faces Uncertainty, Analysts Warn Analysts predict further decline in the crypto market amid U.S. political uncertainty. Lack of progress on Bitcoin reserves and disappointing updates from David Sachs contribute to investor hesitance, say SkyBridge Capital's Anthony Scaramucci and QCP Capital experts. Yet, Standard Chartered forecasts Bitcoin may hit $500,000 during Trump's presidency. El Salvador recently added 11 BTC to its national Bitcoin reserve, totaling 6068 BTC. Medical firm Semler Scientific bought 871 BTC, raising its total to 3192 BTC. Additionally, Canadian company Neptune Digital Assets acquired 20 BTC, boosting their balance to 376 BTC. Meanwhile, MicroStrategy has paused further Bitcoin purchases after 12 consecutive weeks. For more details, visit: Forklog #Crypto#Bitcoin#TrumpsPresidency#SkyBridge#ElSalvador#SemlerScientific#NeptuneDigitalAssets#MicroStrategy#Investment#MarketAnalysis#QCPCapital#StandardChartered#BTC#CryptoMarket#PoliticalUncertainty#Blockchain#Investors#Reserve#Finance