V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
yszsws
V2EX  ›  问与答

anki 的一个快速切换卡片类型的插件“Quick note and deck buttons Fork for 21”终于更新啦

  •  
  •   yszsws · 2020-07-17 12:09:54 +08:00 · 725 次点击
    这是一个创建于 1395 天前的主题,其中的信息可能已经有所发展或是发生改变。

    anki2.0 版本时一直用这个插件,但自从更新到 2.1 后插件失效了也就没再用,差不多快两年了吧,最近突然发现这个插件的作者好像更新了插件,可以支持 2.1 了,链接 https://github.com/ijgnd/anki21__editor_quick_note_and_deck_buttons

    但我不知道该如何配置代码,使它生效,在整个中文网络还没有关于这个插件 2.1 版本的教程(只有老版 2.0 的),希望有在用 anki 或对这个插件感兴趣的 v 友们指点一二。代码贴在下面,在这个插件的配置界面右侧还有一段好像是指导性的文字?,我也一并贴在下面了

    { "Disable for these profiles": [], "Enable only for these profiles": [], "deck__model__proportion": [ 1, 1 ], "deck_button_rows": [ [ { "deck": "Deck1", "label": "Deck1", "note type": "Basic", "shortcut": "Ctrl+7", "tags clear existing": true, "tags to add": [ "adjust_the_config_of_the_addon_Quick_note_and_deck_buttons" ] }, { "deck": "Deck1::my subdeck", "label": "my subdeck" } ], [ { "deck": "Deck 2", "label": "Deck 2" } ] ], "model_button_rows": [ [ { "deck": "Deck1", "label": "B", "note type": "Basic", "shortcut": "Ctrl+1", "tags clear existing": false, "tags to add": [ "really_adjust_the_config_of_the_addon_Quick_note_and_deck_buttons" ], "tags to remove": [ "remove_this" ] }, { "label": "C", "note type": "Cloze", "shortcut": "Ctrl+2" } ], [ { "label": "with reverse", "note type": "Basic (and reversed card)", "shortcut": "Ctrl+3" } ] ] }

    ————————下面是右侧的文字———————— general The buttons you see to quickly change ... the note type are defined by "model_button_rows" ... the deck are defined by "deck_button_rows" "deck__model__proportion" allows you influence the relative width of the deck area and note type area. A higher number means that the affected element should get relatively bigger. E.g. "deck__model__proportion": [9,1], means that the deck area will be much wider if the number of visible buttons allows this. It does not mean that the deck area will be exactly nine times as wide as the model area. If you work with multiple profiles you can enable or disable this add-on for selected profiles with "Disable for these profiles" and "Enable only for these profiles". If "Enable only for these profiles" is an empty list this add-on will be enabled for all profiles except for those set under "Disable for these profiles". If you set a name in "Enable only for these profiles" this add-on will only be active in this profile. This setting will override an entry in "Disable for these profiles". Details model_button_rows and deck_button_rows each contain a list of lists. Each nested list represents one row. The buttons in each row are defined by a list of dictionaries. Each dictionary must contain: label: the text of the button deck or note type: the name of the note type or deck to change to. The deck is created if it doesn’t exist already. You can also add the following values to each dictionary: shortcut, deck or note type, tags clear existing, tags to add, tags to remove, shortcut only/no button, focus to field number tags clear existing must be "true" or "false". The default is "false". tags to add and tags to remove must be lists and look like this ["add_this_one", "and_this_one"]. You can also set shortcut only/no button to "true" so that a button is not shown for this option. In this case the value for label will be ignored. focus to field number must be an integer (1, 2, 3, etc.) Closely follow the examples. Use the correct symbols like brackets, curly braces, etc. Before Anki 2.1.24 you can't select text to copy it from the readme sidebar of this add-on config dialog. If you use an older Anki version you can view the following examples also on this website from where you can copy them. example with one row { "deck_button_rows": [ [ { "label": "Deck1", "shortcut": "Ctrl+7", "deck": "Deck1" }, { "label": "my subdeck", "deck": "Deck1::my subdeck" } ] ], "model_button_rows": [ [ { "label": "B", "shortcut": "Ctrl+1", "note type": "Basic" }, { "label": "C", "shortcut": "Ctrl+2", "note type": "Cloze" } ] ] }

    example with two rows { "deck_button_rows": [ [ { "label": "Deck1", "shortcut": "Ctrl+7", "deck": "Deck1" }, { "label": "my subdeck", "deck": "Deck1::my subdeck" } ], [ { "label": "Deck 2", "deck": "Deck 2" } ] ], "model_button_rows": [ [ { "label": "B", "shortcut": "Ctrl+1", "note type": "Basic" }, { "label": "C", "shortcut": "Ctrl+2", "note type": "Cloze" } ], [ { "label": "with reverse", "shortcut": "Ctrl+3", "note type": "Basic (and reversed card)" } ] ] }

    example with one row where a button changes the note type and deck at the same time and modifies tags { "deck_button_rows": [ [ { "label": "Deck1", "shortcut": "Ctrl+7", "deck": "Deck1", "note type": "Basic", "tags clear existing": true, "tags to add": ["quick_note_buttons_addon_sample_tag_for_deck"], "tags to remove": [] }, { "label": "my subdeck", "deck": "Deck1::my subdeck" } ] ], "model_button_rows": [ [ { "label": "B", "shortcut": "Ctrl+1", "note type": "Basic", "deck": "Deck1", "tags clear existing": false, "tags to add": ["quick_note_buttons_addon_sample_tag_models", "quick_note_buttons_addon_models_this_too"], "tags to remove": ["if_present_this_tag_will_be_removed", "also_this_one"] }, { "label": "C", "shortcut": "Ctrl+2", "note type": "Cloze" } ] ] }

    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   923 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 21:46 · PVG 05:46 · LAX 14:46 · JFK 17:46
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.