Commit graph

386 commits

Author SHA1 Message Date
Damien Elmes
d877fad653 remove obsolete test 2012-05-17 10:13:30 +09:00
Damien Elmes
cdfaa664ed fix intermittent sync test fails 2012-05-16 05:04:15 +09:00
Damien Elmes
e10e4aed1d fix due check, remove obsolote unit test 2012-05-14 06:55:32 +09:00
Damien Elmes
dd45746a41 fix unit test 2012-05-06 19:40:35 +09:00
Damien Elmes
aedf88ee6d don't allow {{c0:: 2012-05-06 18:08:15 +09:00
Damien Elmes
e3a848b5b8 tally lrn separately so we don't limit it with the rev limit 2012-05-06 02:20:25 +09:00
Damien Elmes
0e2637a999 when cram deck removed, cards in learning need to be reset 2012-05-06 01:55:18 +09:00
Damien Elmes
7c95b00253 fix unit test 2012-05-05 01:29:54 +09:00
Damien Elmes
5b97c3f20f don't throw error when update causes empty cards; fix unit test 2012-04-24 10:03:34 +09:00
Damien Elmes
b2bc97ee49 clear overdue lapsed cards from learning queue 2012-04-24 05:28:19 +09:00
Damien Elmes
014dc3d987 fix unit test 2012-04-21 06:56:30 +09:00
Damien Elmes
7c51a7bb16 update sort field when field moved 2012-04-21 06:40:20 +09:00
Damien Elmes
74bd61139a fix unit test 2012-04-19 11:42:56 +09:00
Damien Elmes
609e165c95 use deck of existing cards if all use same deck 2012-04-18 05:24:02 +09:00
Damien Elmes
55812bef86 remove cards from cram decks and the relearning queue on suspend 2012-04-17 22:53:48 +09:00
Damien Elmes
3ab91c600b fix unit tests 2012-04-17 22:23:44 +09:00
Damien Elmes
cbeccc4d8a fix sched unit test 2012-04-15 10:51:34 +09:00
Damien Elmes
4f8053b165 make sure to export deck creation date on apkg export 2012-04-12 00:34:40 +09:00
Damien Elmes
1077c71c2e don't throw error in half-complete field filter 2012-04-08 21:39:04 +09:00
Damien Elmes
ad661add7c ignore sound: tags when rendering furigana 2012-04-08 09:27:50 +09:00
Damien Elmes
6e8f2f5993 when creating child decks, inherit case from parents 2012-04-08 08:45:36 +09:00
Damien Elmes
bbac32b477 ensure lapsed reviews are scheduled for tomorrow on graduate 2012-04-07 14:28:41 +09:00
Damien Elmes
2f75e99671 ntype -> note 2012-04-07 13:53:55 +09:00
Damien Elmes
7d8c0d96b5 fix unit tests 2012-04-06 12:50:46 +09:00
Damien Elmes
aa559431b6 on upgrade all cards of a note should share the same due # 2012-04-06 12:45:01 +09:00
Damien Elmes
b413b1562a when updating, preserve unmapped fields 2012-03-25 02:07:20 +09:00
Damien Elmes
51b70a5787 genCards() on model change 2012-03-20 02:46:45 +09:00
Damien Elmes
dc85212bfe remove review order options
As cram decks provide a more efficient way of ordering reviews, we can limit
normal reviews to just due order.
2012-03-13 19:25:28 +09:00
Damien Elmes
60dd0b426c store order as an index 2012-03-13 18:12:06 +09:00
Damien Elmes
cabf25bacc add upgrade unit test 2012-03-12 12:42:26 +09:00
Damien Elmes
f4e962aa58 make sure we move reviews back to original deck 2012-03-12 12:33:46 +09:00
Damien Elmes
ea64e4da1b don't need to removeFailed() when suspending 2012-03-12 12:16:37 +09:00
Damien Elmes
8030b2c969 use type not queue for rev sib. spacing, fix cram case 2012-03-11 14:52:12 +09:00
Damien Elmes
4a12ec62c1 log cram reps separately; fix std rev reps 2012-03-11 14:06:59 +09:00
Damien Elmes
da07e15a87 generalize into 'dynamic decks'
- search and limits are embedded in the deck
- decks can be refreshed
- they have the option to treat due reviews normally rather than cram them
- some options are inherited from the original deck, others taken from the
  dynamic deck
2012-03-10 19:41:37 +09:00
Damien Elmes
f6b2e69669 remove did from notes, use model did instead 2012-03-09 09:12:27 +09:00
Damien Elmes
ffaf7ffc66 removing cram decks, estimates, failure handling 2012-03-09 06:56:07 +09:00
Damien Elmes
01404fafaa start of cram refactor 2012-03-08 16:47:22 +09:00
Damien Elmes
a2312f9a1f change cards table schema
In preparation for cramming:

- add odid for storing old deck on a per-card basis
- rename edue to odue
- at the moment note.did still exists, but in the future we may ignore it and
  use model.did instead
2012-03-08 11:28:12 +09:00
Damien Elmes
972526d265 update supermemo importer; fix factor 2012-03-07 06:58:06 +09:00
Damien Elmes
beef571d95 include _, remove some old unittest support files 2012-03-07 06:10:18 +09:00
Damien Elmes
869d665c22 gui integration for mnemosyne 2012-03-07 05:54:57 +09:00
Damien Elmes
1d29c7bcc0 foreign card importing; mnemosyne 2.0 importer 2012-03-07 05:45:52 +09:00
Damien Elmes
66534db987 make the cloze hint a prefix 2012-03-07 03:27:04 +09:00
Damien Elmes
a99101d95c initMapping(); csv tweaks 2012-02-29 13:33:55 +09:00
Damien Elmes
099ba71bb0 fix updating 2012-02-29 12:49:42 +09:00
Damien Elmes
7189e57e80 csv importing basics 2012-02-29 12:39:35 +09:00
Damien Elmes
cd5dfa2116 deck and packaged deck export 2012-02-26 01:45:39 +09:00
Damien Elmes
8539c081b3 start porting export code 2012-02-25 22:10:57 +09:00
Damien Elmes
f9ed0d657c remove notes field from cloze 2012-01-30 07:45:52 +09:00
Damien Elmes
766e153840 try to avoid showing the same card twice in a row 2012-01-24 00:43:44 +09:00
Damien Elmes
87a996cdce add flag fields for conditional templates 2012-01-23 23:57:33 +09:00
Damien Elmes
1ad65bfb5f Merge branch 'master' of https://github.com/aaronharsh/libanki 2012-01-17 11:21:30 +09:00
Aaron Harsh
54fe8bb96f libanki support for drag-and-drop changes of deck hierarchy in deckbrowser 2012-01-15 20:55:29 -08:00
Damien Elmes
8ac1587b12 add per-deck due counts back to scheduler 2012-01-16 09:55:44 +09:00
Damien Elmes
9e35e4acf2 template and cloze changes
While writing the documentation I realized that the default templates were
somewhat overwhelming. So I've moved the default settings into the card css,
and moved the css into a separate attribute which gets combined with the
question and answer templates.

Also:
- Detect cloze references directly rather than the conditional wrapper
- Add the cloze css to the template
2011-12-17 19:42:30 +09:00
Damien Elmes
bacbea13e0 conf() -> confForDid(); add getConf() 2011-12-13 13:56:05 +09:00
Damien Elmes
0a677fee56 sync tweaks 2011-12-13 10:44:50 +09:00
Damien Elmes
35a10744a6 'open' was a silly choice 2011-12-12 02:25:16 +09:00
Damien Elmes
0b96e8a1a9 per-fact empty card deletion, and delete hook 2011-12-11 23:48:24 +09:00
Damien Elmes
8be0e6cccd make sure we add + delete cards after template changes 2011-12-11 23:35:59 +09:00
Damien Elmes
0a279f6a26 remove clozectx, add styling to stdmodels 2011-12-11 02:33:27 +09:00
Damien Elmes
78494283c2 store forgetting index as %, fix card sorting 2011-12-10 04:11:43 +09:00
Damien Elmes
20ffbd57a7 don't need relearn flag, can infer from empty delays list 2011-12-09 08:36:00 +09:00
Damien Elmes
451962d4a8 drop the special config for top level decks
New/rev card mixing, collapse time and the timeboxing limit are now a
collection property. I appreciate how it could be useful to have those
settings per top-level deck in some cases, but having some settings inherited
from the top level deck makes for a confusing UI.
2011-12-09 07:55:40 +09:00
Damien Elmes
8c9c3489e5 fetch reviews in subdecks incrementally like new cards
- allows separate review order for different decks
- makes new card and rev card handling consistent
- for users who find it confusing to have cards from different decks mixed in
  and thus click on each deck in turn, they can now just select the parent
  deck and have it work as expected
- for users who want their cards mixed together randomly, they can keep the
  cards in a single deck
2011-12-09 04:02:43 +09:00
Damien Elmes
95106908dd check sort field when searching
If the field they want to search is the one being used to sort, this saves us
having to go the full search route
2011-12-08 09:53:27 +09:00
Damien Elmes
0ef3fe5d75 fix media unittest, turn of sync during upgrade 2011-12-07 23:23:58 +09:00
Damien Elmes
be66c960a9 rework media syncing so we can resume 2011-12-06 22:18:41 +09:00
Damien Elmes
8308c79fa6 minor refactor of count handling
- drop lrnCount; rename lrnRepCount to lrnCount
- on card fetch, decr count by card.left
- drop cardCounts(), rename repCounts() to just counts()
- fix lrn count bugs
2011-12-05 19:15:46 +09:00
Damien Elmes
b99dbb1466 don't .reset() on deck load by default anymore 2011-12-05 13:40:37 +09:00
Damien Elmes
cca3b5cba6 scm ts should be ms too, fix unit tests 2011-12-04 17:52:01 +09:00
Damien Elmes
9d5357f7a6 after a save, revert to unmodified state; sync tweaks 2011-12-04 14:56:12 +09:00
Damien Elmes
6965a9c102 sync tweaks 2011-12-03 21:06:27 +09:00
Damien Elmes
d148a6cf1b bundle ssl certs; share con across all sync types 2011-12-03 16:38:45 +09:00
Damien Elmes
c961b5843a fix ivl estimation for new cards 2011-12-02 22:10:33 +09:00
Damien Elmes
8f1404642a always generate new cards on edit; don't delete 2011-12-02 21:52:33 +09:00
Damien Elmes
8c1266ab2a less terse card state searches 2011-11-28 20:18:16 +09:00
Damien Elmes
b5c0b1f2c7 drop required/unique field properties
Instead of having required and unique flags for every field, enforce both
requirements on the first field, and neither on the rest. This mirrors the
subject/body format people are used to in note-taking apps. The subject
defines the object being learnt, and the remaining fields represent properties
of that object.

In the past, duplicate checking served two purposes: it quickly notified the
user that they're entering the same fact twice, and it notified the user if
they'd accidentally mistyped a secondary field. The former behaviour is
important for avoiding wasted effort, and so it should be done in real time.
The latter behaviour is not essential however - a typo is not wasted effort,
and it could be fixed in a periodic 'find duplicates' function. Given that
some users ended up with sluggish decks due to the overhead a large number of
facts * a large number of unique fields caused, this seems like a change for
the better.

This also means Anki will let you add notes as long as as the first field has
been filled out. Again, this is not a big deal: Anki is still checking to make
sure one or more cards will be generated, and the user can easily add any
missing fields later.

As a bonus, this change simplifies field configuration somewhat. As the card
layout and field dialogs are a popular point of confusion, the more they can
be simplified, the better.
2011-11-24 22:16:03 +09:00
Damien Elmes
daea038aa4 deckCounts -> deckDue 2011-11-24 17:04:26 +09:00
Damien Elmes
eac9a00b22 fix syncing tests 2011-11-23 20:11:21 +09:00
Damien Elmes
f7790275ce groups -> decks 2011-11-23 19:28:09 +09:00
Damien Elmes
279a942642 deck -> collection 2011-11-23 17:47:44 +09:00
Damien Elmes
6e4e8249fb facts -> notes 2011-11-23 12:37:21 +09:00
Damien Elmes
7a5cee1d20 remove remaining CSS; more template properties into div 2011-11-18 08:25:56 +09:00
Damien Elmes
c76c08069e change template replacement behaviour
Previously {{field}} wrapped the field in a span with the field's font
properties. This wasn't obvious, and caused frequent problems with people
trying to combine field and template text, or use field content in dictionary
links.

Now that AnkiWeb has a wizard for configuring the front & back layout, we can
just put the formatting in the template instead.
2011-11-18 02:50:47 +09:00
Damien Elmes
770f402905 don't allow template removal to orphan facts 2011-11-17 23:09:18 +09:00
Damien Elmes
a51307701d del -> rem for consistency 2011-11-17 22:55:03 +09:00
Damien Elmes
58c56c433a apply review limit; fix finished msg 2011-11-15 04:05:44 +09:00
Damien Elmes
795cdd7d3f remove the concept of non-active templates
The old template handling was too complicated, and generated frequent
questions on the forums. By dropping non-active templates we can do away with
the generate cards function, and advanced users can simulate the old behaviour
by using conditional field templates.
2011-11-08 18:06:19 +09:00
Damien Elmes
c6c6af4328 split remote sync tests into separate file 2011-11-07 16:21:29 +09:00
Damien Elmes
3614a13a50 fix model unit test 2011-11-07 14:27:42 +09:00
Damien Elmes
cbdb283b20 refactor model copying 2011-10-31 11:34:03 +09:00
Damien Elmes
7a849fccc5 fix allMedia() and unit tests 2011-10-29 15:31:27 +09:00
Damien Elmes
1ce5a7552e ensure top level properties updated on rename 2011-10-23 05:45:15 +09:00
Damien Elmes
f37f4aff96 need to sort tree based on split components, not string order 2011-10-22 21:14:46 +09:00
Damien Elmes
b9dc5764a3 add group renaming 2011-10-22 20:41:33 +09:00
Damien Elmes
bbe2973952 add newly created clozes too 2011-10-22 03:58:54 +09:00
Damien Elmes
46dd863f3c convert genCards() to bulk update; drop random 2011-10-22 03:39:34 +09:00
Damien Elmes
852189808f catch attempts to save a fact that deletes a cloze card 2011-10-22 03:10:34 +09:00