{"id":137491,"date":"2020-07-20T22:46:43","date_gmt":"2020-07-20T14:46:43","guid":{"rendered":"http:\/\/4563.org\/?p=137491"},"modified":"2020-07-20T22:46:43","modified_gmt":"2020-07-20T14:46:43","slug":"anki-%e7%9a%84%e4%b8%80%e4%b8%aa%e5%bf%ab%e9%80%9f%e5%88%87%e6%8d%a2%e5%8d%a1%e7%89%87%e7%b1%bb%e5%9e%8b%e7%9a%84%e6%8f%92%e4%bb%b6quick-note-and-deck-buttons-fork-for-21%e7%bb%88","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=137491","title":{"rendered":"anki \u7684\u4e00\u4e2a\u5feb\u901f\u5207\u6362\u5361\u7247\u7c7b\u578b\u7684\u63d2\u4ef6\u201cQuick note and deck buttons Fork for 21\u201d\u7ec8\u4e8e\u66f4\u65b0\u5566"},"content":{"rendered":"<div>\n<div>\n<div>\n<h1>                  anki \u7684\u4e00\u4e2a\u5feb\u901f\u5207\u6362\u5361\u7247\u7c7b\u578b\u7684\u63d2\u4ef6\u201cQuick note and deck buttons Fork for 21\u201d\u7ec8\u4e8e\u66f4\u65b0\u5566               <\/h1>\n<p> <\/p>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : yszsws <\/span>  <span><i><\/i> 6<\/span> <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<\/p><\/div>\n<div isfirst=\"1\"> <\/p>\n<p>anki2.0 \u7248\u672c\u65f6\u4e00\u76f4\u7528\u8fd9\u4e2a\u63d2\u4ef6\uff0c\u4f46\u81ea\u4ece\u66f4\u65b0\u5230 2.1 \u540e\u63d2\u4ef6\u5931\u6548\u4e86\u4e5f\u5c31\u6ca1\u518d\u7528\uff0c\u5dee\u4e0d\u591a\u5feb\u4e24\u5e74\u4e86\u5427\uff0c\u6700\u8fd1\u7a81\u7136\u53d1\u73b0\u8fd9\u4e2a\u63d2\u4ef6\u7684\u4f5c\u8005\u597d\u50cf\u66f4\u65b0\u4e86\u63d2\u4ef6\uff0c\u53ef\u4ee5\u652f\u6301 2.1 \u4e86\uff0c\u94fe\u63a5 https:\/\/github.com\/ijgnd\/anki21__editor_quick_note_and_deck_buttons<\/p>\n<p>\u4f46\u6211\u4e0d\u77e5\u9053\u8be5\u5982\u4f55\u914d\u7f6e\u4ee3\u7801\uff0c\u4f7f\u5b83\u751f\u6548\uff0c\u5728\u6574\u4e2a\u4e2d\u6587\u7f51\u7edc\u8fd8\u6ca1\u6709\u5173\u4e8e\u8fd9\u4e2a\u63d2\u4ef6 2.1 \u7248\u672c\u7684\u6559\u7a0b\uff08\u53ea\u6709\u8001\u7248 2.0 \u7684\uff09\uff0c\u5e0c\u671b\u6709\u5728\u7528 anki \u6216\u5bf9\u8fd9\u4e2a\u63d2\u4ef6\u611f\u5174\u8da3\u7684 v \u53cb\u4eec\u6307\u70b9\u4e00\u4e8c\u3002\u4ee3\u7801\u8d34\u5728\u4e0b\u9762\uff0c\u5728\u8fd9\u4e2a\u63d2\u4ef6\u7684\u914d\u7f6e\u754c\u9762\u53f3\u4fa7\u8fd8\u6709\u4e00\u6bb5\u597d\u50cf\u662f\u6307\u5bfc\u6027\u7684\u6587\u5b57\uff1f\uff0c\u6211\u4e5f\u4e00\u5e76\u8d34\u5728\u4e0b\u9762\u4e86<\/p>\n<p>{ &#8220;Disable for these profiles&#8221;: [], &#8220;Enable only for these profiles&#8221;: [], &#8220;deck__model__proportion&#8221;: [ 1, 1 ], &#8220;deck_button_rows&#8221;: [ [ { &#8220;deck&#8221;: &#8220;Deck1&#8221;, &#8220;label&#8221;: &#8220;Deck1&#8221;, &#8220;note type&#8221;: &#8220;Basic&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+7&#8221;, &#8220;tags clear existing&#8221;: true, &#8220;tags to add&#8221;: [ &#8220;adjust_the_config_of_the_addon_Quick_note_and_deck_buttons&#8221; ] }, { &#8220;deck&#8221;: &#8220;Deck1::my subdeck&#8221;, &#8220;label&#8221;: &#8220;my subdeck&#8221; } ], [ { &#8220;deck&#8221;: &#8220;Deck 2&#8221;, &#8220;label&#8221;: &#8220;Deck 2&#8221; } ] ], &#8220;model_button_rows&#8221;: [ [ { &#8220;deck&#8221;: &#8220;Deck1&#8221;, &#8220;label&#8221;: &#8220;B&#8221;, &#8220;note type&#8221;: &#8220;Basic&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+1&#8221;, &#8220;tags clear existing&#8221;: false, &#8220;tags to add&#8221;: [ &#8220;really_adjust_the_config_of_the_addon_Quick_note_and_deck_buttons&#8221; ], &#8220;tags to remove&#8221;: [ &#8220;remove_this&#8221; ] }, { &#8220;label&#8221;: &#8220;C&#8221;, &#8220;note type&#8221;: &#8220;Cloze&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+2&#8221; } ], [ { &#8220;label&#8221;: &#8220;with reverse&#8221;, &#8220;note type&#8221;: &#8220;Basic (and reversed card)&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+3&#8221; } ] ] }<\/p>\n<p>\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u4e0b\u9762\u662f\u53f3\u4fa7\u7684\u6587\u5b57\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014 general The buttons you see to quickly change &#8230; the note type are defined by &#8220;model_button_rows&#8221; &#8230; the deck are defined by &#8220;deck_button_rows&#8221; &#8220;deck__model__proportion&#8221; 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. &#8220;deck__model__proportion&#8221;: [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 &#8220;Disable for these profiles&#8221; and &#8220;Enable only for these profiles&#8221;. If &#8220;Enable only for these profiles&#8221; is an empty list this add-on will be enabled for all profiles except for those set under &#8220;Disable for these profiles&#8221;. If you set a name in &#8220;Enable only for these profiles&#8221; this add-on will only be active in this profile. This setting will override an entry in &#8220;Disable for these profiles&#8221;. 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\u2019t 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 &#8220;true&#8221; or &#8220;false&#8221;. The default is &#8220;false&#8221;. tags to add and tags to remove must be lists and look like this [&#8220;add_this_one&#8221;, &#8220;and_this_one&#8221;]. You can also set shortcut only\/no button to &#8220;true&#8221; 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&#8217;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 { &#8220;deck_button_rows&#8221;: [ [ { &#8220;label&#8221;: &#8220;Deck1&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+7&#8221;, &#8220;deck&#8221;: &#8220;Deck1&#8221; }, { &#8220;label&#8221;: &#8220;my subdeck&#8221;, &#8220;deck&#8221;: &#8220;Deck1::my subdeck&#8221; } ] ], &#8220;model_button_rows&#8221;: [ [ { &#8220;label&#8221;: &#8220;B&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+1&#8221;, &#8220;note type&#8221;: &#8220;Basic&#8221; }, { &#8220;label&#8221;: &#8220;C&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+2&#8221;, &#8220;note type&#8221;: &#8220;Cloze&#8221; } ] ] }<\/p>\n<p>example with two rows { &#8220;deck_button_rows&#8221;: [ [ { &#8220;label&#8221;: &#8220;Deck1&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+7&#8221;, &#8220;deck&#8221;: &#8220;Deck1&#8221; }, { &#8220;label&#8221;: &#8220;my subdeck&#8221;, &#8220;deck&#8221;: &#8220;Deck1::my subdeck&#8221; } ], [ { &#8220;label&#8221;: &#8220;Deck 2&#8221;, &#8220;deck&#8221;: &#8220;Deck 2&#8221; } ] ], &#8220;model_button_rows&#8221;: [ [ { &#8220;label&#8221;: &#8220;B&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+1&#8221;, &#8220;note type&#8221;: &#8220;Basic&#8221; }, { &#8220;label&#8221;: &#8220;C&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+2&#8221;, &#8220;note type&#8221;: &#8220;Cloze&#8221; } ], [ { &#8220;label&#8221;: &#8220;with reverse&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+3&#8221;, &#8220;note type&#8221;: &#8220;Basic (and reversed card)&#8221; } ] ] }<\/p>\n<p>example with one row where a button changes the note type and deck at the same time and modifies tags { &#8220;deck_button_rows&#8221;: [ [ { &#8220;label&#8221;: &#8220;Deck1&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+7&#8221;, &#8220;deck&#8221;: &#8220;Deck1&#8221;, &#8220;note type&#8221;: &#8220;Basic&#8221;, &#8220;tags clear existing&#8221;: true, &#8220;tags to add&#8221;: [&#8220;quick_note_buttons_addon_sample_tag_for_deck&#8221;], &#8220;tags to remove&#8221;: [] }, { &#8220;label&#8221;: &#8220;my subdeck&#8221;, &#8220;deck&#8221;: &#8220;Deck1::my subdeck&#8221; } ] ], &#8220;model_button_rows&#8221;: [ [ { &#8220;label&#8221;: &#8220;B&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+1&#8221;, &#8220;note type&#8221;: &#8220;Basic&#8221;, &#8220;deck&#8221;: &#8220;Deck1&#8221;, &#8220;tags clear existing&#8221;: false, &#8220;tags to add&#8221;: [&#8220;quick_note_buttons_addon_sample_tag_models&#8221;, &#8220;quick_note_buttons_addon_models_this_too&#8221;], &#8220;tags to remove&#8221;: [&#8220;if_present_this_tag_will_be_removed&#8221;, &#8220;also_this_one&#8221;] }, { &#8220;label&#8221;: &#8220;C&#8221;, &#8220;shortcut&#8221;: &#8220;Ctrl+2&#8221;, &#8220;note type&#8221;: &#8220;Cloze&#8221; } ] ] }<\/p>\n<\/p><\/div>\n<div> <b>\u5927\u4f6c\u6709\u8a71\u8aaa<\/b> (<span>0<\/span>)        <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<ul>\n<li>\n","protected":false},"excerpt":{"rendered":"<p>anki \u7684\u4e00\u4e2a\u5feb\u901f\u5207\u6362\u5361\u7247\u7c7b\u578b\u7684&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/137491"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=137491"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/137491\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=137491"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=137491"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=137491"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}