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

TGINSIGHT SIMILAR POSTS

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

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

Регулярно приходится писать и ревьюить код, где используется PySide2-6. Заметил, что в подавляющем большинстве случаев настройка создаваемых базовых виджетов происходит через методы. Думаю, всем знаком такой способ. Простой пример с кнопкой: button = QPushButton("Click Me") button.setMinimumWidth(300) button.setFlat(True) button.setStyleSheet("font-size: 20pt") button.setToolTip("Super Button") button.clicked.connect(lambda: print("Button clicked")) Но есть и альтернативный способ - настройка через свойства. Это просто ключевые аргументы конструктора класса. Хоть они и не указаны в документации как аргументы, но они есть) Этот код делает тоже самое но с помощью Property button = QPushButton( "Click Me", minimumWidth=300, flat=True, styleSheet="font-size: 20pt", toolTip="Super Button", clicked=lambda: print("Button clicked"), ) Где это может быть полезно ▫️ Это выглядит более аккуратно и коротко, уже повод использовать ▫️ Может использоваться в заполнении лейаута, когда нам не нужно никакое другое взаимодействие с виджетом и поэтому сохранять его в переменную не требуется. Например, лейбл или кнопка. widget = QWidget(minimumWidth=400) layout = QHBoxLayout(widget) layout.addWidget(QLabel("Button >", alignment=Qt.AlignRight)) layout.addWidget(QPushButton("Click Me", clicked=lambda: print("Button clicked"))) widget.show() Либо так widget = QWidget(minimumWidth=400) layout = QHBoxLayout(widget) for wd in ( QLabel("Button >", alignment=Qt.AlignRight), QPushButton("Click Me", clicked=lambda: ...) ): layout.addWidget(wd) widget.show() ▫️ Можно хранить настройки в каком-то конфиге или генерировать на лету, после чего передавать как kwargs. kwargs = {"text": "Hello " * 30, "wordWrap": True} my_label = QLabel(**kwargs) Как получить полный список доступных свойств? Эта функция распечатает в терминал все свойства виджета и их текущие значения def print_widget_properties(widget): meta_object = widget.metaObject() for i in range(meta_object.propertyCount()): property_ = meta_object.property(i) property_name = property_.name() property_value = property_.read(widget) print(f"{property_name}: {property_value}") #tricks#qt

Hashtags

Резултати

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

Пребарај: #imx

当前筛选 #imx清除筛选
Coin Sonar

@CoinSonar · Post #243970 · 18.04.2026 г., 04:55

#IMX | Volume spike (USDT PAIR) 204 times the average volume 101.81K USDT traded in 1 min └Buying vol: 54.51K USDT 🟢 Boost score: 5/10 24h Vol: 715.73K USDT (Binance) Price: 0.167 (-2.8% in 24h)

Hashtags

Pro Analysis

@proanalysistrader · Post #28446 · 02.02.2025 г., 13:06

#IMX/USDT analysis : #IMX is in an uptrend, forming higher highs (HHs) and higher lows (HLs). The price is currently undergoing a correction phase and is expected to test the previously respected support zone. A rebound from this level is anticipated, allowing the bullish momentum to resume and potentially test previous highs. TF : 1W Entry : $0.850 Target : $3.761 SL : $0.565

Hashtags

Pro Analysis

@proanalysistrader · Post #27820 · 08.08.2024 г., 14:57

#IMX/USDT analysis - #IMX is in a correction phase, showing retracement towards the 200 EMA. Price is expected to test the resistance zone and reject from there to continue its downward direction. The previous swing low will be tested. TF : 2H Entry : $1.208 Target : $0.985 SL : $1.298

Hashtags

Coinlegs Cryptocurrency Signals

@coinlegs · Post #10218 · 19.04.2024 г., 09:02

#IMX | Trendline Breakout detected by CoinLegs Algorithm 😎 After a retest of breakout, long position can be taken. Put your stop loss below the trendline (candle close). www.coinlegs.com

Hashtags

BULLSTAR - SIGNALS

@bullstar1 · Post #5166 · 20.02.2026 г., 16:46

COIN: $IMX/USDT (5-10x) Direction: LONG 📈 #IMX/USDT Take-Profit Target 4🎯 Profit : 32.66% with 10x Leverage (PREMIUM SIGNAL) Everyone else trying to survive… while our VIPs keep scoring big🔥 t.me/BULLSTAR_ADMIN

Hashtags

BULLSTAR - SIGNALS

@bullstar1 · Post #4986 · 24.12.2025 г., 23:18

COIN: $IMX/USDT (5-10x) Direction: LONG 📈 #IMX/USDT Take-Profit Target 3🎯 Profit : 22.82% with 10x (PREMIUM SIGNAL) This is the profit we make every day with our VIP members. We secured the profit, moved the stop-loss to entry, and now we’re holding the rest for the upcoming targets 🚀 t.me/BULLSTAR_ADMIN

Hashtags

BULLSTAR - SIGNALS

@bullstar1 · Post #4354 · 09.08.2025 г., 09:52

COIN: $IMX/USDT (5-10x) Direction: LONG 📈 #IMX/USDT Take-Profit Target 5🎯 Profit : 45.20% with 10x Leverage (PREMIUM SIGNAL) First 5 TP levels reached, profit taken and stops moved. Nice move!🚀 t.me/BULLSTAR_ADMIN

Hashtags

ПретходнаСтраница 1 од 4Следна