Skip to content

Commit

Permalink
we aim to please
Browse files Browse the repository at this point in the history
  • Loading branch information
retorquere committed Feb 10, 2017
1 parent f95f969 commit 20ba9f7
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
11 changes: 10 additions & 1 deletion chrome/content/zotero-better-bibtex/xul/preferences.xul
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
<preference name="extensions.zotero.translators.better-bibtex.autoAbbrev" id="pref-better-bibtex-autoAbbrev" type="bool"/>
<preference name="extensions.zotero.translators.better-bibtex.autoExport" id="pref-better-bibtex-autoExport" type="string"/>
<preference name="extensions.zotero.translators.better-bibtex.citeCommand" id="pref-better-bibtex-citeCommand" type="string"/>
<preference name="extensions.zotero.translators.better-bibtex.quickCopyPandocBrackets" id="pref-better-bibtex-quickCopyPandocBrackets" type="bool"/>
<preference name="extensions.zotero.translators.better-bibtex.citekeyFormat" id="pref-better-bibtex-citekeyFormat" type="string"/>
<preference name="extensions.zotero.translators.better-bibtex.citekeyFold" id="pref-better-bibtex-citekeyFold" type="bool"/>
<preference name="extensions.zotero.translators.better-bibtex.debug" id="pref-better-bibtex-debug" type="bool"/>
Expand Down Expand Up @@ -207,7 +208,7 @@
</menulist>
</row>
<row>
<label>&zotero.better-bibtex.prefs.citekey.quickCopy.command;</label>
<label>&zotero.better-bibtex.prefs.citekey.quickCopy.latex.command;</label>
<textbox size="10" id="id-better-bibtex-preferences-citeCommand" preference="pref-better-bibtex-citeCommand"
onchange="BetterBibTeXPref.update();"
onkeypress="setTimeout(function() { BetterBibTeXPref.update() }, 1);"/>
Expand All @@ -218,6 +219,14 @@
`\citep{key1,key2,...}`
-->
</row>
<row>
<checkbox id="id-better-bibtex-preferences-quickCopyPandocBrackets"
preference="pref-better-bibtex-quickCopyPandocBrackets"
label="&zotero.better-bibtex.prefs.citekey.quickCopy.pandoc.brackets;"/>
<!--
Surround pandoc citations with brackets.
-->
</row>
</rows>
</grid>
</groupbox>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ If you are OK with sending this data, please click &quot;Continue&quot; and post
<!ENTITY zotero.better-bibtex.prefs.citekey.citekeys "Citation keys">
<!ENTITY zotero.better-bibtex.prefs.citekey.quickCopy "Quick copy/drag-and-drop citations">
<!ENTITY zotero.better-bibtex.prefs.citekey.quickCopy.format "QuickCopy format">
<!ENTITY zotero.better-bibtex.prefs.citekey.quickCopy.command "LaTeX command">
<!ENTITY zotero.better-bibtex.prefs.citekey.quickCopy.latex.command "LaTeX command">
<!ENTITY zotero.better-bibtex.prefs.citekey.quickCopy.pandoc.brackets "Surround Pandoc citations with brackets">
<!ENTITY zotero.better-bibtex.prefs.citekey.fold "Force citation key to ASCII">
<!ENTITY zotero.better-bibtex.prefs.citekey.format "Citation key format">

Expand Down
1 change: 1 addition & 0 deletions defaults/preferences/defaults.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ bibtexParticleNoOp: false
biblatexExtendedNameFormat: false
biblatexExtendedDateFormat: false
quickCopyMode: latex
quickCopyPandocBrackets: false
jurismPreferredLanguage: zh-alalc97
ZotFile: true
qualityReport: false
Expand Down
4 changes: 3 additions & 1 deletion resource/translators/Better BibTeX Quick Copy.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ Mode =
keys = []
while item = Translator.nextItem()
keys.push("@#{item.__citekey__}")
Zotero.write(keys.join('; '))
keys = keys.join('; ')
keys = "[#{keys}]" if Zotero.getHiddenPref('better-bibtex.quickCopyPandocBrackets')
Zotero.write(keys)

orgmode: ->
while item = Translator.nextItem()
Expand Down

0 comments on commit 20ba9f7

Please sign in to comment.