* Add description input to fields dialog
QLineEdit seems like the best option, as it saves space and motivates users to keep their descriptions concise.
* Add setDescriptions to note initialization script
Went for the extra function instead of including it in setFields to prevent potential add-on breakages.
* Add tooltip next to field name if description is set
* Refactor code according to suggestions
Set default tooltip placement to right instead of bottom
Use .get() for fld["description"]
Fix tab order in fields dialog
Swap out abbreviation "desc" for full length name to keep consistency
* Update Protobuf and Rust for description
Add description to notetypes.proto and schema11
Co-authored-by: RumovZ <RumovZ@users.noreply.github.com>
* Fix tooltips not updating with description
Remove redundant variable tooltipOptions
Update previousTooltip within reactive function
* Move LabelDescription out of LabelName
Co-authored-by: Henrik Giesel <hgiesel@users.noreply.github.com>
* Decrease icon size and fix alignment
Co-Authored-By: Henrik Giesel <hengiesel@gmail.com>
* the new key needs to be cleared from fields, not the notetype itself
Co-authored-by: RumovZ <RumovZ@users.noreply.github.com>
Co-authored-by: Henrik Giesel <hengiesel@gmail.com>
Co-authored-by: Damien Elmes <gpg@ankiweb.net>
* Declare toolbar api via modifiable property
* Fix addon buttons
* Assign editing areas in a synchronous way
* Restore the Tab shortcut that moves the caret to end
- moveCaretToEnd is called twice now: The moveCaretToEnd calls in
*TextInput causes the caret to be moved to the end when switching back
from the window and back.
- To fix this, I will need the code for saving and restoring locations
from #1377
* Restore selections in the PlainTextInput
* Improve type safety of destroyable
- clearable-array was renamed to destroyable
* Fix invalid path in cargo-env.bat
* Assume cargo-env.bat is run from repo root; fix package script (dae)
* mention cargo-raze doesn't work on Windows (dae)
* Refactor editor css, fix editor button highlight
- Avoid using webview.css
- Move more buttons css into button_mixins
* Fix DropdownItem appearance
* Fix the visuals of tags
* Make dropdown font slightly smaller
* Give SelectOption a background color
* Move some css from deck-options-base to CardStateCustomizer
* Avoid using core.scss for CardStats
* Avoid using sass/core in congrats package
* Inline core.scss into webview.scss
* Include fusion-vars for base.scss
* need to keep core.scss around for now (dae)
We're getting an enum instead of an int in Qt6
normal/reversed have been renamed to ascending/descending; no add-ons
appear to be using the old versions.
* Alias PyQt5 to PyQt6 on PyQt6 builds
Restores basic compatibility with PyQt5 add-ons
* Register QtCore early to work around sip error
* Monkey-patch unscoped enums that are in use by add-ons back in
Enums whose namespace moved with PyQt6 were determined using the tooling in https://github.com/qutebrowser/qutebrowser/issues/5904
Relevant enums for the Anki add-on ecosystem were found by grepping through all AnkiWeb add-ons and a selection of GitHub-released add-ons.
* Add full Qt.Key namespace
Maintains compatibility with add-ons that allow specifying key bindings via Qt.Key enums
* Reintroduce PyQt6.Qt as an alias for QtCore.Qt
* Alias classes shifted from QtWidgets to QtGui
* Add missing enums
Adds ≈200 enums that were missed during the initial grep
* Map exec_ calls to exec
* Tweak section headers
* Fix QtWebEngineWidgets imports failing due to delayed import
Addesses: "QtWebEngineWidgets must be imported before a QCoreApplication instance is created"
* Register additional aliases for top-level Qt modules
Given how we have had to deal with side-effects when not registering other aliased imports ahead of time, it seems safer to also register the remaining few with sys.modules.
* Handle calls to deprecated PyQt resource API graciously
* Create QtWebEngineWidgets aliases for classes moved to QtWebEngineCore
* Alias QShortcut
* Restore QWebEnginePage.view()
* Alias sip to PyQt6.sip
* Alias QtCore.QRegExp to QtCore.QRegularExpression
* Restructure aqt.qt into package
Pre-requirement for aliasing the PyQt5.Qt namespace correctly.
Should hopefully also make it easier to keep an overview as Qt-compat-related modules were proliferating.
* Properly alias PyQt5.Qt
PyQt5.Qt used to serve as a common namespace for all Qt classes, not just QtCore.Qt.*
While this changes does not make all classes accessible via PyQt5.Qt, it does so for the most important Qt submodules, which should cover most add-on breakages.
* Simplify Qt resource system legacy handling
* Also alias PyQt6.Qt
Covers imports of the form `from PyQt5 import import Qt` (due to previous aliasing of PyQt5 to PyQt6)
* Add missing enums
Better approach to grepping through add-ons yielded additional hits
* Run formatters
* Satisfy pylint
An experimental new approach based on PyOxidizer instead of PyInstaller.
PyInstaller doesn't currently define __file__ in bundled files, so a
few parts of the code that were referencing __file__ directly needed
to be updated. The root_path argument to flask is for the same reason -
it tries to look up __file__ without it.