Damien Elmes
91892aa816
Merge pull request #1050 from BlueGreenMagick/choose-addon-to-update
...
Choose addon to update
2021-03-10 11:41:50 +10:00
RumovZ
d857e05e30
Ensure mouse is at current index before searching
...
Thus, no search will be triggered when clicking an expansion indicator
as this doesn't update the current element. However, if the indicator
belongs to the current item, a search will be triggered anyway.
2021-03-09 20:36:15 +01:00
RumovZ
fb87f1e2df
Disable expand on double click in search mode
2021-03-09 20:18:12 +01:00
bluegreenmagick
2600d89850
don't show routine update when not update_enabled
2021-03-09 22:27:28 +09:00
bluegreenmagick
7ccfb61154
add context menu to open ankiweb page
2021-03-09 22:19:03 +09:00
bluegreenmagick
328ecb9ec3
add bool_to_check and checked method
2021-03-09 22:19:03 +09:00
bluegreenmagick
aa58d3922e
fix check issues in ChooseAddonsToUpdateList
2021-03-09 22:19:03 +09:00
bluegreenmagick
fa95d36bf9
save chooseaddonupdate check state
2021-03-09 22:19:03 +09:00
Henrik Giesel
94355978a2
Refactor bridgeCommand and silence false "uncaught msg" log
2021-03-09 13:43:11 +01:00
Henrik Giesel
3a8fad5dc5
Make sure topleft buttons are rounded too, prefer Bootstrap's rounded class
2021-03-09 13:43:11 +01:00
Henrik Giesel
d8e8153aae
Change signature of editor onBridgeCmd to Any instead of None
2021-03-09 13:43:11 +01:00
Henrik Giesel
59c69bd8dd
Replace pin icon with lock icon
...
Credit goes out to @kleinerpirat
2021-03-09 13:43:11 +01:00
Henrik Giesel
b580e192f4
Remove Change Tracker again
2021-03-09 13:43:11 +01:00
Henrik Giesel
3f96290214
Connect icons to sticky fields values
2021-03-09 13:37:56 +01:00
Henrik Giesel
6b444782e9
Remove explicit popperjs again, because it's included in bootstrap.bundle
2021-03-09 13:37:56 +01:00
Henrik Giesel
5aaf76bc19
Include the bootstrap icons in the editor view
2021-03-09 13:37:56 +01:00
Henrik Giesel
adfe645966
Fix positioning of buttons
2021-03-09 13:37:56 +01:00
Henrik Giesel
dbcf0ffee1
Include bootstrap in editor
2021-03-09 13:37:56 +01:00
Henrik Giesel
b7c24a9f98
Add bootstrap, bootstrap-icons, and popperjs
2021-03-09 13:37:56 +01:00
RumovZ
7edb51a2af
Add shortcuts for sidebar tools
2021-03-09 11:19:44 +01:00
RumovZ
d202befe3f
Improve toolbar styling for macOS
2021-03-09 08:50:01 +01:00
RumovZ
589fea1046
Remove edit mode
2021-03-08 11:55:15 +01:00
RumovZ
f303f24c47
Enable drag for all sidebar items ...
...
... and set valid drop targets dynamically based on the current
selection.
2021-03-08 11:35:39 +01:00
RumovZ
8b3539b009
Ask before removing tags from collection
2021-03-07 11:40:11 +01:00
RumovZ
a4d030e7b4
Simplify multi deletion confirmation strings
2021-03-07 11:05:43 +01:00
RumovZ
f30510371b
Only show edit actions with conform selection
2021-03-07 11:05:28 +01:00
RumovZ
7e622d05de
Fix repainting in case of tree building exception
2021-03-07 09:47:17 +01:00
RumovZ
2d5baac35d
Remove context action dict
...
Now that almost all actions can be triggered from outside the context
menu and are available for more than one item type, it's easier to check
for available actions dynamically.
2021-03-05 12:22:49 +01:00
RumovZ
c8b5689e47
Fix children check in context tree actions
2021-03-05 10:27:44 +01:00
Benjamin K
61fd5688c0
Clean up imports
2021-03-04 19:55:35 +01:00
Benjamin K
48da1bda1d
The old delimiter is now kept, when cancel button is clicked
2021-03-04 19:39:43 +01:00
RumovZ
837c305ece
Enable deleting via delete key
2021-03-04 18:31:35 +01:00
RumovZ
ca7e3a4ddd
Enable Enter/Return search in all modes ...
...
... but don't trigger search if the key closes the editor.
Also get rid of the on_click of the saved searches root which has
already been removed on main.
2021-03-04 17:40:12 +01:00
RumovZ
873a1897d1
Ask for confirmation when overwriting saved search
2021-03-04 17:22:03 +01:00
RumovZ
3b1af18b4f
Adjust sidebar tool icons to smaller size
2021-03-04 17:20:10 +01:00
RumovZ
ee00c341c3
Make renamed item current (don't just select)
2021-03-03 23:00:37 +01:00
RumovZ
a09c09e1c1
Remove renaming dialogues from sidebar ...
...
... in favour of in-line editing. This is simpler and more ergonomic for
the user (and the programmer) but doesn't allow for editing parents
through text input (in the case of tags and decks).
2021-03-03 21:57:39 +01:00
RumovZ
dc4f9edc29
Enable renaming templates from the sidebar
2021-03-03 18:09:53 +01:00
RumovZ
4a4b02a0ea
Enable renaming notetypes
2021-03-03 15:18:50 +01:00
RumovZ
3fbb8e83f0
Enable group expanding/collapsing
...
Also, only show expand/collapse actions if they will have an effect.
2021-03-03 11:44:42 +01:00
RumovZ
4c061b398b
Make SidebarItem._is_extended a property
2021-03-03 11:43:31 +01:00
RumovZ
0eddf1100a
Escape backslashes in re.sub()'s repl
2021-03-03 09:20:02 +01:00
RumovZ
9f10d465c6
Add DECK_CURRENT as a SidebarItemType
...
Thus, disable renaming, deleting etc. for the current deck item.
As a consequence, editable is no longer needed as a field of SidebarItem
as it can be derived from its type.
2021-03-03 09:15:36 +01:00
bluegreenmagick
35364b3b94
add dialog to choose addons to update
2021-03-03 10:34:43 +09:00
RumovZ
526532ab44
Select and scroll to renamed/added sidebar item
2021-03-02 23:13:34 +01:00
RumovZ
8b9b9d2b1e
Enable removal of multiple tags from the sidebar
2021-03-02 11:05:16 +01:00
RumovZ
572bf12d9d
Make clickable dyndeck labels fixed in size
2021-03-01 11:26:52 +01:00
RumovZ
16817c81e4
Enable deleting multiple saved searches
2021-03-01 09:41:41 +01:00
RumovZ
97cca52be0
Fix repainting when renaming tag via dialogue
2021-03-01 08:45:33 +01:00
RumovZ
5fb370dfa9
Enable extended selection in edit mode
2021-03-01 08:45:03 +01:00
Damien Elmes
45e1aacaf1
monospace font in html editor
...
https://forums.ankiweb.net/t/change-default-font-of-html-edit-mode-to-a-monospaced-font/7833
2021-03-01 10:16:12 +10:00
Damien Elmes
24ba4e3a29
catch attempts to nest under a filtered deck; don't show traceback
2021-03-01 09:58:12 +10:00
Damien Elmes
5045517f8a
Merge pull request #1040 from RumovZ/deck-name-err
...
Catch deck rename errors and localise warnings
2021-03-01 09:40:55 +10:00
RumovZ
c1a0977519
Fix Qt types
2021-02-28 22:36:31 +01:00
RumovZ
22d1146b02
Always return False from rename_node
...
setData expects a result but due to the asynchrony of the editor it
might not be known, yet.
2021-02-28 22:36:21 +01:00
RumovZ
5523a72253
Enable in-place editing of sidebar tags
2021-02-28 21:50:21 +01:00
RumovZ
670bb4531b
Enable in-place editing of saved searches
2021-02-28 21:13:26 +01:00
RumovZ
6b9e2fa485
Enable in-place editing of sidebar deck items
2021-02-28 21:03:19 +01:00
RumovZ
47d96a32e6
Add support for multi deck deletion in python
2021-02-26 19:52:34 +01:00
RumovZ
b7b7cd4b20
Place sidebar tools right of search bar
2021-02-26 13:04:30 +01:00
RumovZ
c4a2a212ec
Catch DeckIsFilteredError directly on frontend
2021-02-26 11:32:40 +01:00
Damien Elmes
0377783a59
remove left-click on saved searches
...
Multiple users have thought it was a bug rather than an intentional
feature, and it breaks double-clicking:
https://forums.ankiweb.net/t/anki-2-1-41-beta/7305/51
2021-02-26 18:48:32 +10:00
Damien Elmes
5e946fad08
fix browser appearance defaults
...
https://forums.ankiweb.net/t/small-bug-in-the-browser-appearance-window/7806
2021-02-26 18:46:09 +10:00
Damien Elmes
2ffaf9499d
Merge pull request #1039 from RumovZ/dyndeck-hint
...
Clickable hint in dyndeck dialogue for unmovable cards
2021-02-26 18:02:51 +10:00
RumovZ
b127fb0fb3
Add group search context action
2021-02-25 21:24:11 +01:00
RumovZ
afb6b88128
Handle search on event level
...
Instead of assigning each sidebar item a lambda, add a field for search
representation and handle searching in event handler.
2021-02-25 19:57:12 +01:00
RumovZ
25a9d08833
Make search first (default) mode
2021-02-25 19:28:29 +01:00
RumovZ
b2964d65bb
Add edit mode in sidebar
2021-02-25 13:12:51 +01:00
RumovZ
fc4a2c05dd
Save last sidebar tool
2021-02-25 12:20:54 +01:00
RumovZ
79c2856201
Add select and search modes to sidebar
2021-02-25 11:06:59 +01:00
RumovZ
a41b639d27
Add toolbar to sidebar
2021-02-25 11:05:04 +01:00
RumovZ
5a2bed7d8e
Add icons for sidebar tools
2021-02-25 11:02:17 +01:00
bluegreenmagick
5ef9401686
StudyDeck without add button
2021-02-25 07:34:01 +09:00
RumovZ
b8f828a465
Fix #1024 – catch deck rename errors
2021-02-24 13:59:38 +01:00
RumovZ
5e7b594c71
Localise RenameDeckError
2021-02-24 13:57:44 +01:00
RumovZ
1686a065f8
Fix type hints in dyndeckconf
2021-02-24 11:24:27 +01:00
RumovZ
6ae03c3aa9
Refactor dyndeckconf/on_hint_button
2021-02-24 11:14:33 +01:00
RumovZ
6eca669cb0
Give dyndeck hint unique styling
2021-02-23 23:34:05 +01:00
RumovZ
c0dfce3908
Add clickable hint to dyndeckconf
2021-02-23 23:14:11 +01:00
RumovZ
bb58060c91
Add direct col reference to dyndeckconf
2021-02-23 22:31:04 +01:00
Henrik Giesel
e2bda7273e
Fix scrollbar issue in anki-editable component in two ways
...
- using :host-context(.nightMode) allows for applying the nightmode
scroll bar inside the component
- apply max-width: 100% to all element within editable, not just images
2021-02-23 15:52:20 +01:00
Damien Elmes
abd9d42869
Merge pull request #1034 from abdnh/clayout-cloze-shortcuts
...
Shortcuts to preview clozes in card layout screen
2021-02-22 10:07:16 +10:00
abdo
f137c21d02
Shortcuts to preview clozes in card layout screen
...
Assign Alt+{number} to select cloze cards.
2021-02-21 14:46:53 +03:00
Damien Elmes
c2c5174bd2
tweak update message
...
- Since we need to show this to new users until AnkiDroid is updated,
use a wording that doesn't seem so out of place to new users.
- Avoid mentioning syncing, since the user may not sync, and the
modSchema() call will allow the user to confirm anyway.
- Let the user know they can change their mind about AnkiDroid by
visiting the preferences.
2021-02-21 19:47:26 +10:00
Damien Elmes
125c2b232a
rework v2 scheduler upgrade; drop downgrade
...
- Rework V2 upgrade so that it no longer resets cards in learning,
or empties filtered decks.
- V1 users will receive a message at the top of the deck list
encouraging them to upgrade, and they can upgrade directly from that
screen.
- The setting in the preferences screen has been removed, so users
will need to use an older Anki version if they wish to switch back to
V1.
- Prevent V2 exports with scheduling from being importable into a V1
collection - the code was previously allowing this when it shouldn't
have been.
- New collections still default to v1 at the moment.
Also add helper to get map of decks and deck configs, as there were
a few places in the codebase where that was required.
2021-02-21 15:50:41 +10:00
bluegreenmagick
8c5ffa5c19
change _on_click_current to _on_click_index
...
fix bug where clicking on a blank space below sidebar item
would still trigger currentIndex item's click event
2021-02-20 22:58:02 +09:00
Damien Elmes
be823c39f0
tweak getFile() arguments in editor to be more readable
2021-02-19 10:18:40 +10:00
Damien Elmes
17396dc89b
disable card shifting in reposition by default
...
https://forums.ankiweb.net/t/uncheck-shift-position-of-existing-cards-by-default/7550
2021-02-19 10:09:01 +10:00
Damien Elmes
0b2ee8dcff
use add-on id if name is blank
...
https://forums.ankiweb.net/t/support-for-rtl-layout-in-ankiweb-add-on-page/7522
2021-02-16 11:12:05 +10:00
Henrik Giesel
c2410ded9c
Remove unused imports
2021-02-12 02:16:05 +01:00
Henrik Giesel
72253e129f
Allow for passing in custom note type and template
2021-02-12 02:12:03 +01:00
Henrik Giesel
6e22b8b145
Allow for passing in custom note types for rendering ephemeral cards
2021-02-12 01:53:03 +01:00
Damien Elmes
0907b77fef
Revert "Use new note.ephemeral_card method in clayout"
...
This partially reverts commit 4ca24f1d84 .
2021-02-12 10:05:46 +10:00
Damien Elmes
28a9ba473d
tweak search wording and tidy up API
...
- SearchTerm -> SearchNode
- Operator -> Joiner; share between messages
- build_search_string() supports specifying AND/OR as a convenience
- group_searches() makes it easier to negate
2021-02-11 19:57:19 +10:00
Damien Elmes
6e28b096f8
more search bikeshedding
...
While implementing the overdue search, I realised it would be nice to
be able to construct a search string with OR and NOT searches without
having to construct each part individually with build_search_string().
Changes:
- Extends SearchTerm to support a text search, which will be parsed
by the backend. This allows us to do things like wrap text in a group
or NOT node.
- Because SearchTerm->Node conversion can now fail with a parsing error,
it's switched over to TryFrom
- Switch concatenate_searches and replace_search_term to use SearchTerms,
so that they too don't require separate string building steps.
- Remove the unused normalize_search()
- Remove negate_search, as this is now an operation on a Node, and
users can wrap their search in SearchTerm(negated=...)
- Remove the match_any and negate args from build_search_string
Having done all this work, I've just realised that perhaps the original
JSON idea was more feasible than I first thought - if we wrote it out
to a string and re-parsed it, we would be able to leverage the existing
checks that occur at parsing stage.
2021-02-11 17:11:17 +10:00
Damien Elmes
5ad2cd56d1
switch some existing code to use SearchTerm(negated=...)
2021-02-11 10:55:02 +10:00
Damien Elmes
fe503ba009
split due into 'due today' and 'overdue'
2021-02-11 10:49:36 +10:00
Damien Elmes
e871ec68b5
Revert "experiment with using right click for AND/OR/NOT"
...
This reverts commit cbf0cdd30e and
manually comments out the setSelectionMode() call.
Switching back to the old behaviour until issues can be worked through.
https://forums.ankiweb.net/t/anki-2-1-41-beta/7305/24
2021-02-11 10:14:26 +10:00
Damien Elmes
9146c79f9e
Revert "add escape hatch for new clicking behaviour, in case it causes problems"
...
This reverts commit e618756998 .
2021-02-11 10:10:45 +10:00
Damien Elmes
42a44875ab
convert qt strings to f-strings with flynt
...
Also revealed an incorrect type def in editor.py that mypy wasn't
noticing before :-(
2021-02-11 10:09:06 +10:00