Commit Graph

3816 Commits

Author SHA1 Message Date
Arthur Milchior
0c39c4f106 add an id to name tab 2020-03-23 16:52:24 +01:00
Damien Elmes
b1a8107aa1 formatting 2020-03-23 19:54:01 +10:00
Damien Elmes
11a4d582b4 convert asc to desc instead of appending desc to the end of the order
as the latter doesn't work when sorting on more than one column

https://anki.tenderapp.com/discussions/beta-testing/1868-anki-2124-beta#comment_48174812
2020-03-23 19:53:57 +10:00
Damien Elmes
84eaf43525 reduce the chances of a race condition in mplayer code
Not perfect, it may still happen.

https://anki.tenderapp.com/discussions/ankidesktop/39832-an-error-occurred-audio
2020-03-23 19:15:32 +10:00
Damien Elmes
f889616ef1 don't pop up network errors for media sync
log them instead
2020-03-23 19:06:13 +10:00
Damien Elmes
f429986246 fix collection_did_load() not being called, and remove dead code
https://anki.tenderapp.com/discussions/ankidesktop/39765-_colloadingstate-is-never-run-thus-collection_did_load-hook-is-never-triggered
2020-03-23 18:57:23 +10:00
Damien Elmes
7d94465256 cache dark mode value so UI doesn't break when it changes
https://anki.tenderapp.com/discussions/ankidesktop/39550-cant-deactivate-night-mode-on-2121-for-mac
2020-03-23 18:39:37 +10:00
Damien Elmes
7a4f3d0318 dump more info in card()/bcard() 2020-03-23 18:39:00 +10:00
Damien Elmes
14a970e923 rename long filenames in fields if files renamed in a previous sync 2020-03-23 18:38:45 +10:00
Arthur Milchior
349d145014 Ident html in editor
Sometime I like to print html to understand why it bugs. And I really
prefer to have html indented if it's okay with you. There is no change
appart from the identation and quotes
2020-03-23 08:15:48 +01:00
Damien Elmes
c615342130 fix English being shown in prefs for fully qualified langs like zh-CN
https://anki.tenderapp.com/discussions/ankidesktop/39845-a-new-bug-has-been-found
2020-03-23 16:08:06 +10:00
Damien Elmes
966eb666f0 fix v2 timing being returned for v1 users 2020-03-23 13:53:09 +10:00
Damien Elmes
4e2e0d1b84 fix setting of wal 2020-03-23 13:52:57 +10:00
Damien Elmes
cd9ceebd59 simplify how the local offset is passed around
- no need to store it in conf
- move local_minutes_west() call to collection
2020-03-23 13:52:52 +10:00
Damien Elmes
dc8cf9d554 release GIL during collection open/close 2020-03-23 09:27:42 +10:00
Damien Elmes
75b7ebb156 add back new_timezone_enabled(), as it's used in the prefs screen 2020-03-23 07:40:50 +10:00
Arthur Milchior
f2f92fb0c3 editor_did_init
That would be useful to add elements in the editor, such as in multi
column editor
2020-03-22 17:15:47 +01:00
Damien Elmes
427bf268fc apply same list->tuple fix to v1 sched 2020-03-22 21:56:02 +10:00
Damien Elmes
4f99d0d3e5
Merge pull request #519 from zjosua/lrnQueue
Fill _lrnQueue with tuples, not lists
2020-03-22 21:53:53 +10:00
zjosua
0b94eee97e Fill _lrnQueue with tuples, not lists 2020-03-22 11:49:40 +01:00
Damien Elmes
430f1ad616 handle trailing whitespace inside group 2020-03-22 18:52:44 +10:00
Damien Elmes
25ff4642ec accept now_mins_west for v2 legacy timing as well 2020-03-22 17:33:14 +10:00
Damien Elmes
6c6817563e fix sync error introduced by 69d8cdd9ed 2020-03-22 17:32:34 +10:00
Damien Elmes
ac36fba90f handle the two remaining timing issues 2020-03-22 14:43:29 +10:00
Damien Elmes
69d8cdd9ed use backend for v1 and v2 cutoff calculations
this should also fix the CI failures, which were happening because
the datetime module wasn't matching the shifted time.time()
2020-03-22 14:28:26 +10:00
Damien Elmes
c5629e96df exclude autogenerated src from build deps
prevents unnecessary rebuilds
2020-03-22 03:39:38 +00:00
Damien Elmes
47fcdd0723 possible fix for CI failure 2020-03-22 13:17:00 +10:00
Damien Elmes
f28e57a367 add enum for controlling sort order
eg col.find_cards("", order=BuiltinSortKind.CARD_DUE)
2020-03-22 12:59:24 +10:00
Damien Elmes
199713a39a handle collections with sortBackwards set to 0 instead of a bool 2020-03-22 10:26:09 +10:00
Damien Elmes
9dda5cf6ca fall back on stock json if orjson unavailable 2020-03-21 21:24:21 +10:00
Damien Elmes
cc44523449 remove debugging line 2020-03-21 18:29:04 +10:00
Damien Elmes
99416477ac allow customizing search order 2020-03-21 17:38:09 +10:00
Damien Elmes
dfa7f5e142 fix reversing sort order 2020-03-21 16:57:33 +10:00
Damien Elmes
9afbcd4178 remove old finder code; add search hooks to browser & remove old one 2020-03-21 16:38:46 +10:00
Damien Elmes
9696e959be increase the rated search cap to 365, and allow searches for ease 0
An add-on appears to use ease 0 when rescheduling cards, and it may
make sense for Anki to do the same in the future as well.
2020-03-21 16:05:17 +10:00
Damien Elmes
51a379de23 add search that ignores combining chars
On a test of a ~40k card collection, the 'ignore accents' add-on
takes about 1150ms, and this code takes about 70ms.
2020-03-21 15:15:59 +10:00
Damien Elmes
f0ed34d79b support regexp search in single field 2020-03-21 13:06:46 +10:00
Damien Elmes
97577dbc16 support wildcard in field*:val search 2020-03-21 12:45:25 +10:00
Damien Elmes
08e64d246d don't require wildcard for unicode case folding in search 2020-03-21 12:44:56 +10:00
Damien Elmes
4ff17d31b3 add unicase collation
sqlite's like is hard-coded to use ASCII comparisons, so we can't
take advantage of this yet
2020-03-21 12:40:20 +10:00
Damien Elmes
d1ebdbdcce support regex searches 2020-03-21 12:00:48 +10:00
Damien Elmes
2dc1b5c982 add regexp() to sqlite 2020-03-21 10:23:11 +10:00
Damien Elmes
2aab44d9ce support deck:"foo bar" style searches 2020-03-21 09:34:24 +10:00
Damien Elmes
a5787781d7 add note searching 2020-03-21 09:00:05 +10:00
Damien Elmes
aee64016ac fix formatting and unit test 2020-03-21 08:17:24 +10:00
Damien Elmes
307aadfd8a don't set deck.sched.today in test 2020-03-21 08:12:32 +10:00
Damien Elmes
daa848bb4d update tests to reflect what now constitutes an error 2020-03-21 08:12:01 +10:00
Damien Elmes
868c463fb1 tests need to flush before searching 2020-03-21 08:10:52 +10:00
Damien Elmes
3a4146560c handle escaped tag searches and tag:* special case 2020-03-21 08:09:28 +10:00
Damien Elmes
ad09c89c3c check for child decks case-insensitively 2020-03-21 07:57:07 +10:00