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

Резултати

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

Пребарај: #traders

当前筛选 #traders清除筛选
TONlines – News

@tonlines · Post #7625 · 27.11.2025 г., 09:27

⚡️MRKT League: Autumn Champions Announced #MRKT#traders The Autumn Open League on MRKT has concluded, with winners now available in the app. A total of 50 traders earned prizes, ranging from a Plush Pepe to a Heroic Helmet. The next tournament has started, with results to be announced on December 3. Source: link @tonlines

TONlines – News

@tonlines · Post #7575 · 21.11.2025 г., 19:05

MRKT: Prepare for the Next Trading Opportunity #MRKT#traders MRKT provides a new opportunity for traders to buy Stars at the best price and participate in the upcoming trading rush. Direct purchase through @mrktbank is available. Source: link @tonlines

TONlines – News

@tonlines · Post #7538 · 19.11.2025 г., 18:41

MRKT: Autumn Open League Concludes #MRKT#traders The Autumn Open League hosted by MRKT has concluded, celebrating top traders with prizes like Plush Pepe and Durov’s Cap. A new tournament is already underway, inviting more participants to join. Source: link @tonlines

ProtradeFx

@protradeforex · Post #9938 · 19.02.2026 г., 09:19

The @OrderOfMentors now have a YouTube channel, please subscribe and share your charts in the YouTube community group chat to help us attract other traders. Your help is needed to grow. https://youtu.be/Xi4qxpq-2GU?si=t7GfRMqfC93j0Fk8 #OOM#Traders#Jayfx

Venture Village Wall 🦄

@venturevillagewall · Post #3913 · 18.01.2025 г., 13:00

Bitcoin Predicted to Reach $200K by 2025 CryptoQuant analysts forecast Bitcoin may hit $200,000 by 2025. Driving factors include: ✔️ $520 billion institutional capital influx ✔️ Easing monetary policy and favorable crypto regulation ✔️ Historical price surges in the final year of four-year cycles. For more details, visit Forklog News. #Bitcoin#Crypto#Market#Analysis#Forecast#Investment#Institutional#Regulations#BullMarket#Trends#Finance#CryptoNews#Blockchain#Tech#Economy #2025 #Capital#Growth#QuantAnalysis#Traders#Volatility

Venture Village Wall 🦄

@venturevillagewall · Post #4338 · 08.03.2025 г., 10:00

Utah Establishes First Bitcoin Reserve 🔵 Utah becomes the first U.S. state to create a strategic Bitcoin reserve. This initiative aims to enhance regional economic stability and protect state assets from inflation and market fluctuations. Read more here. 🔴 In contrast, Russia remains hesitant to include Bitcoin in its National Wealth Fund, citing its volatility. Nevertheless, the Deputy Minister of Finance indicated a review of the strategy may occur if reserves reach a certain level, potentially incorporating higher-yield assets like crypto in the future. Read more here. ⭐️ Gemini cryptocurrency exchange confidentially filed for an IPO, partnering with Goldman Sachs and Citigroup, potentially eyeing a market entry in 2025. More details available here. #Bitcoin#Utah#Crypto#Russia#IPO#Gemini#Finance#Market#Investment#ETF#Volatility#Assets#Economy#Regulation#Wealth#Liquidity#Traders#CryptoExchanges#BNB#BSC#VC

Venture Village Wall 🦄

@venturevillagewall · Post #3760 · 31.12.2024 г., 13:00

XRP Market Insights and Predictions 📉 Current XRP Price: $2.16 with a $123B market cap. Trading volume: $2.21B. 📊Consolidation Phase: Support at $2.1, resistance at $2.5. RSI: 49.81 | Stochastic: 26.35 | CCI: -95.21. Mixed signals overall, MACD suggests bearish sentiment. 🔄Short-term Downtrend: Testing support at $2.115; resistance at $2.22 - $2.25. EMAs indicate sell signals for 10- and 20-periods. 📈Bullish/ Bearish Scenarios: Break above $2.25 targets $2.5; break below $2.1 targets $1.9. Traders should implement tight stop-losses. Full analysis details can be read here. #XRP#Crypto#MarketAnalysis#TradingStrategy#Investing#TechnicalAnalysis#PricePrediction#Bullish#Bearish#Support#Resistance#EMAs#MACD#RSI#Stochastic#CCI#Volume#Traders#Bulls#Bears#Consolidation