Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for both PyQt5 and PyQt6 #10

Open
shigeyukey opened this issue Mar 10, 2024 · 2 comments
Open

Support for both PyQt5 and PyQt6 #10

shigeyukey opened this issue Mar 10, 2024 · 2 comments

Comments

@shigeyukey
Copy link

Maybe you already know, aqt can be used to support both PyQt5 and PyQt6.
For example,

from PyQt6.QtWidgets import QApplication, QMainWindow, QPushButton, QDialog, QVBoxLayout, QLabel
from aqt import QApplication, QMainWindow, QPushButton, QDialog, QVBoxLayout, QLabel

Since Anki 23.10, enumeration is required for PyQt6.

⭕it works, anki Qt5 & Qt6

from aqt import Qt
Qt.AlignmentFlag.AlignCenter

❌doesn't work, anki Qt6 (Since Anki 23.10)

from aqt import Qt
Qt.AlignCenter

But some features don't work, so maybe you are doing that intentionally. (e.g., Qt Designer)

@Unlucky-Life
Copy link
Owner

exactly there are some features not working yet in pyqt5 and pyqt6 - so i would update this code for pyqt6 and pyqt5 soon but yea issue being: pyqt6 has functions that might not work in pyqt5 anki versions - thats the problem

@shigeyukey
Copy link
Author

I see, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants