В фреймворке PyQt (и PySide тоже) часто встречается настройка чего-либо с помощью так называемых флагов.
widget.setWindowFlags(Qt.Window)
Взаимодействие нескольких флагов делается с помощью бинарных (или побитовых) операторов.
Несколько флагов можно указать с помощью оператора "|"
list_item.setFlags(Qt.ItemIsSelectable | Qt.ItemIsEnabled)
исключить флаг из уже имеющегося набора можно так
list_item.setFlags(list_item.flags() ^ Qt.ItemIsEnabled)
Добавить новый флаг к имеющимся можно так
list_item.setFlags(list_item.flags() | Qt.ItemIsEnabled)
А проверка наличия делается так
is_enabled = item.flags() & Qt.ItemIsEnabled > 0
Почему именно так? Всё дело в том как именно работают побитовые операторы. Но об этом в следующем посте.
#qt
#RIF/USDT analysis :
Following a significant decline of -83% from its all-time high, the price has found support at the $0.0600 level. Subsequently, it has bounced back and successfully broken above the trendline, indicating a confirmation of anticipated bullish momentum. It is expected that the price will continue this upward trajectory and test the previous swing high.
TF : 1W
Entry : $0.1117
Target : $0.3377
SL : $0.0766
#RIF/USDT analysis :
#RIF is trading above the support zone and the 200 EMA. The price is anticipated to rebound from this level and proceed to rise, testing the previous swing high.
TF : 15min
Entry : $0.0977
Target : $0.1007
SL : $0.0956
#RIF yielded an impressive 3,010% return in a few days ⭐
If you used 200x leverage on this signal, you would've made a mind-blowing profit of 12,040%🤩
$50💰 would return $750💵
$50 💰 would return $1,500
💲
$50💰 would return $6,000💰
When you understand the market like we do, every move becomes predictable With 5+ years of trading experience, we spot these moves before they happen 💯
If you want daily signals like this, DM me to join our private group! 👇
@Kevindexter✅
#RIF
I'm expecting roughly this kind of movement on this asset, either with streaming start ups behind our magnets from above.
📈Sign up on Bybit to trade with me