@thedevs · Post #1394 · 13.02.2019 г., 18:13
30 Seconds of Knowledge, Google Chrome extension that lets you gain new developer skills, every time you open a new tab. #resources#extension @thedevs https://kutt.it/XUe4Mf
Hashtags
TGINSIGHT SIMILAR POSTS
Изворен канал @pythonotes · Post #381 · 23 окт.
Установить свойства виджета в PySide можно не только через соответствующие методы и конструктор класса. Можно их изменять с помощью метода setProperty по имени. btn = QPushButton("Click Me") btn.setProperty("flat", True) Это аналогично вызову btn.setFlat(True) Если указать несуществующее свойство, то оно просто создается btn.setProperty("btnType", "super") Получить его значение можно методом .property(name) btn_type = btn.property("btnType") Когда это может быть полезно? ▫️Можно просто хранить какие то данные в виджете и потом их доставать обратно widget = QWidget() widget.setProperty('my_data', 123) print(widget.property('my_data')) ▫️ Назначая эти свойства разным виджетам можно потом отличить виджеты во время итераци по ним. Например, найти все кнопки со свойством my_data="superbtn". Но ведь вместо кастомного свойства можно использовать objectName, будет тот же результат. Да, но y ObjectName есть ограничение - только строки. ▫️ Если нам потребуется не просто поиск а, например, сортировка по числу, то свойства позволяют нам это сделать. Поддерживается любой тип данных widget.setProperty('my_data', {'Key': 'value'}) widget.setProperty('order', 1) all_widgets.sort(key=w: w.property('order')) Но ведь Python позволяет всё вышеперечисленное сделать простым созданием атрибута у объекта widget.order = 1 widget.my_data = 123 Да, но я думаю что не надо объяснять почему не стоит так делать. К тому же, если у виджета нет свойства то метод .property(name) вернет None, а отсутствующий атрибут выбросит исключение. ▫️ Действительно полезное применение кастомным свойствам - контроль стилей. Здесь атрибутами не обойтись, нужны именно свойства. Дело в том, что в селекторах стилей можно указывать конкретные свойства виджетов на которые следует назначать стиль. Просто запустите этот код from PySide2.QtWidgets import * if __name__ == "__main__": app = QApplication([]) widget = QWidget(minimumWidth=300) layout = QVBoxLayout(widget) btn1 = QPushButton("Action 1") btn2 = QPushButton("Action 2") btn3 = QPushButton("Action 3", flat=True) layout.addWidget(btn1) layout.addWidget(btn2) layout.addWidget(btn3) # добавим кастомное свойство одной кнопке btn1.setProperty("btnType", "super") # добавляем стили widget.setStyleSheet( """ QPushButton[btnType="super"] { background-color: yellow; color: red; } QPushButton[flat="true"] { color: yellow; } """ ) widget.show() app.exec_() С помощью селектора мы избирательно назначили стили на конкретные кнопки. Как получить список всех кастомный свойств? Функция получения списка кастомных свойств отличается от получения дефолтных. def print_widget_dyn_properties(widget): for prop_name in widget.dynamicPropertyNames(): property_name = prop_name.data().decode() property_value = widget.property(property_name) print(f"{property_name}: {property_value}") #tricks#qt
Пребарај: #extension
@thedevs · Post #1394 · 13.02.2019 г., 18:13
30 Seconds of Knowledge, Google Chrome extension that lets you gain new developer skills, every time you open a new tab. #resources#extension @thedevs https://kutt.it/XUe4Mf
Hashtags
@hanzichen · Post #895 · 25.06.2025 г., 16:18
YouLy+ YouLy+ is a browser extension that enhances your YouTube Music experience by providing an enhanced lyrics feature with line-by-line and word-by-word synchronization. Follow along with your favorite songs like never before! 🔗 Links: - Add it to your browser - Screenshots - Features - Source code Developer: Ibra Al Tabian ❤️ Support the Project If this project makes your life easier, here are a few quick ways to show some love: ⭐ Star the repo/app ☕ Buy a coffee for the developer 🛠 Contribute code, issues, or pull-requests 🏷 Tags: #Extension#Music
Hashtags
@githubredteam · Post #84656 · 18.05.2026 г., 09:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:RetireJSExporter 👤项目作者:grime66 🛠开发语言: Python ⭐Star数量: 0 | 🍴Fork数量: 0 📅更新时间: 2026-05-18 09:01:12 📝项目描述: Burp Suite extension that exports Retire.js findings only from .js endpoints to JSON and filters false positives. 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84525 · 17.05.2026 г., 02:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:Burp-Suite 👤项目作者:Kieyontay 🛠开发语言: None ⭐Star数量: 0 | 🍴Fork数量: 0 📅更新时间: 2026-05-17 02:00:16 📝项目描述: 无描述 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84520 · 17.05.2026 г., 01:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:DuckDuckBurp 👤项目作者:rainmana 🛠开发语言: Java ⭐Star数量: 3 | 🍴Fork数量: 0 📅更新时间: 2026-05-17 01:01:22 📝项目描述: Front Burp data with DuckDB to enable super fast and awesome querying and AI integration 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84452 · 16.05.2026 г., 13:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:BurpSuite-Extensions 👤项目作者:EmilijaMicovic 🛠开发语言: None ⭐Star数量: 0 | 🍴Fork数量: 0 📅更新时间: 2026-05-16 12:44:42 📝项目描述: 无描述 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84394 · 16.05.2026 г., 02:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:jwt-intruder 👤项目作者:mshartz 🛠开发语言: Java ⭐Star数量: 0 | 🍴Fork数量: 0 📅更新时间: 2026-05-16 02:01:05 📝项目描述: A Burp extension designed to imbed intruder payloads inside of JWTs for which you have the secret key. 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84305 · 15.05.2026 г., 09:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:Postman2burp 👤项目作者:zalakamal08 🛠开发语言: Java ⭐Star数量: 3 | 🍴Fork数量: 0 📅更新时间: 2026-05-15 09:03:40 📝项目描述: 无描述 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84240 · 14.05.2026 г., 17:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:RestoringTestability 👤项目作者:federicodotta 🛠开发语言: None ⭐Star数量: 0 | 🍴Fork数量: 0 📅更新时间: 2026-05-14 16:49:52 📝项目描述: Stuff of my talk "Restoring Testability - Handling complex scenarios in Burp Suite with a custom extension" 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84103 · 13.05.2026 г., 16:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:ProtoME 👤项目作者:twisted007 🛠开发语言: Java ⭐Star数量: 1 | 🍴Fork数量: 0 📅更新时间: 2026-05-13 15:43:07 📝项目描述: Burp Extension to allow for security audit of Protobuf requests. Can generate requests from either a whitebox or completely blackbox perspective. 🔗点击访问项目地址
Hashtags
@githubredteam · Post #84092 · 13.05.2026 г., 15:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:UnusualFuzzer 👤项目作者:Ozozuz 🛠开发语言: None ⭐Star数量: 3 | 🍴Fork数量: 0 📅更新时间: 2026-05-13 15:02:49 📝项目描述: Burp extension for when you have no more ideas and still want errors. 🔗点击访问项目地址
Hashtags
@githubredteam · Post #83938 · 12.05.2026 г., 13:03
🚨 GitHub 监控消息提醒 🚨发现关键词:#Burp#Extension 📦项目名称:revelion-burp-extension 👤项目作者:RevelionAI 🛠开发语言: None ⭐Star数量: 0 | 🍴Fork数量: 0 📅更新时间: 2026-05-12 12:41:38 📝项目描述: Revelion Burp Suite Professional extension - pair your local Burp with Revelion missions 🔗点击访问项目地址
Hashtags