* add methods that allow the user to configure answer keys
* allow editing answer buttons in preferences
* import optional
* Give the layout referenced in code a clearer name (dae)
* Update placeholder text and make it translatable (dae)
The other items in the preferences screen don't have tooltips, so
placeholder text may be easier for the user to discover than a tooltip.
* changed install location and elevation
* change registry keys to HKCU
change context to current user
* filetype associations non elevated
* added an "upgrade" from elevated to non elevated
* added comment to clarify bug
* removed commented out registry entries
* Update CONTRIBUTORS
add mgrottenthaler to contributors
* change upgrade routine to manual uninstall
* added suggestion
- Ensure our unit tests cover the non-legacy path, and check file
contents and not just existence.
- Pass `compressed` into copy_and_ensure_sha1_set(). We can't just
test for self.sha1.is_none(), as that fails in the case where an existing
media file was found in the legacy path.
https://forums.ankiweb.net/t/anki-media-file-corruption-when-exporting-png-files/30315
Quite a few users have been experiencing crashes recently that were
resolved by resetting their window positions/states. I presume this is
related to Qt updates, as there have been previous instances where old
state caused glitchy behaviour or crashes after a Qt upgrade.
The browser headers are now also reset when resetting window positions
in the preferences.
Way back in Qt4, there was an issue where (some?) windows would open
at a different location to where they were previously open. I've tested
the primary windows in Qt 5.14 on macOS, and the issue no longer seems
to exist, so this code is no longer useful.
The qtmajor > 5 check was a mistake introduced in 70dbd06be3ff56f13b9efe7c886c2a6c4f873ce9;
it was intended to limit the code to Qt 5.
A quick grep of an add-on snapshot indicates there are no add-ons that
were using the offset param, so it has been removed.
* Refactor CSS preloading
- Rename css.ts to preload.ts
- Rename type/function names
- Automatically remove style/link element on load/error event
* Refactor image preloading
- Reuse template element
- Change timeout value from 100ms to 200ms, as it often takes more than
100ms to load even a single small image on a low-spec machine
- Refactor preloadAnswerImages():
- Use 'new Image()' instead of <link rel=preload>
- Stop calculating images that only appear on the answer side as
cached images are resolved immediately
* Update tsconfig.json
es2020.string -> String.matchAll()
es2018.regexp -> RegExprMatchArray.groups
* Implement custom font preloading
Font files for some languages such as Chinese and Japanese can be as
large as 20MB, so we set the timeout value to 800ms for font preloading.
* Fix sync client ignoring directories
Current implementation of the sync client does not properly send requests to a
self-hosted sync server if the URL has directories.
If the self-hosted sync URL is `https://example.org/foo/bar/`, Anki is expected
to send requests to `https://example.org/foo/bar/sync/hostKey`. Instead, it will
discard the directories and wrongly send requests to
`https://example.org/sync/hostKey`.
Fixes: e5d5d1d ("Fix panic with invalid sync server URL with port")
* Add XeR to contributors
* add grading shortcuts
* add a new setting: grade with space
* new key: u for undo
* run ./ninja format
* rename property
* rename translation
* run ./ninja format
* Prevent MathJax editor from closing unexpectedly when selecting text
* Revert "Prevent MathJax editor from closing unexpectedly when selecting text"
This reverts commit b43d33a6de36d0af38933c6dae8bdd635294effd.
* Prevent floating/overlay element from closing when selecting text
Apply suggestions from code review.
Use a 'mousedown' event instead of a 'click' event so that releasing
the mouse button at the end of a text selection operation when the
pointer is outside a floating/overlay element does not close it.
Co-authored-by: Damien Elmes <dae@users.noreply.github.com>
---------
Co-authored-by: Damien Elmes <dae@users.noreply.github.com>
* Fix file extension not being appended on export
Regressed in #2427
* Improve import messaging when notetype has changed
- If the local notes are up to date, we don't need to warn about the
changed notetype, as no updates are required.
- Make it clearer that a changed notetype only affects updates.
Will update the docs as well.