Example and personal practice of show and edit every key mapping data with table widget
This can get all key mapping data of application.
- PyQt5
python -m pip install git+https://github.com/yjg30737/pyqt-key-binding-example.git --upgrade
if __name__ == "__main__":
import sys
app = DarkNotepadApp(sys.argv) # https://github.com/yjg30737/pyqt-dark-notepad
# or you can make your own application
w = KeyBindingWindow()
w.show()
app.exec_()
Result
pyqt_key_binding_example.mp4
If this were C++ Qt, I would do it with orthodox way such as using QStandardItemEditorCreator
. But that is nowhere to be found in PyQt/PySide, so i have to do it on my own.
I'm still working on it.
Still a lot of things need to be fixed or taken care of such as inconsistent order of key mapping list, database feature, make this enable to use anywhere.
btw, You see that second column's cell? Looks ugly, right? Sadly, I don't even care about style anymore. The style took a lot of time and make me so dizzy that i can't focus on the real goal.
- Star Delegate Example - nice article to read if you want to make QTableWidget/QTableView with certain form included complicated designed widget inside each cells.