X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=lib%2Fciteengines%2Fnatbib.citeengine;h=8eda539f9aa964698bec8f9ea705c6cd22995585;hb=9bf3e7b045f38a8b45d69007e37fd812446cc217;hp=89200ddf2b7bc8f8526e2bba08cdc2981fe11eba;hpb=a04a2f9a8aa79f3cb604a0a6848065495677571a;p=lyx.git diff --git a/lib/citeengines/natbib.citeengine b/lib/citeengines/natbib.citeengine index 89200ddf2b..8eda539f9a 100644 --- a/lib/citeengines/natbib.citeengine +++ b/lib/citeengines/natbib.citeengine @@ -8,7 +8,7 @@ # Author: Julien Rioux -Format 63 +Format 74 Requires natbib @@ -44,6 +44,8 @@ MaxCiteNames 2 # # Note further: # +# * The LyXName "keyonly" has a special meaning: only the citation key, +# without any latex command, is output. # * Capitalization indicates that the command also has a capitalized # form (\Latexcmd vs. \latexcmd). These usually enforce upcasing of # name prefixes (von Goethe => Von Goethe). @@ -75,6 +77,7 @@ CiteEngine authoryear citeyear[] citeyearpar[][] nocite + keyonly End CiteEngine numerical @@ -86,6 +89,7 @@ CiteEngine numerical citeyearpar[][] citeyear nocite + keyonly End @@ -100,20 +104,27 @@ End # There are common definitions (default) and specific definitions for # either cite engine type (which overwrite existing defaults. # + +# Input standard format definitions for the bibliography +Input stdciteformats.inc + CiteFormat default # # MACROS # - # 1. Translatable bits (need to be marked by _ prefix) + # 1. Translatable bits (need to be marked by _ prefix, if translated to the GUI language, + # or B_, if translated to the buffer language) # Note that preceding and trailing spaces matter. # _notcited not cited _addtobib Add to bibliography only. + _keyonly Key only. + _key Key # The following are handled by BiblioInfo - _etal et al. - _namesep , [[separate author names in citation, except for last name]] - _lastnamesep , and [[separate name of last author in citation]] - _pairnamesep and [[separate two authors in citation]] + B_etal et al. + B_namesep , [[separate author names in citation, except for last name]] + B_lastnamesep , and [[separate name of last author in citation]] + B_pairnamesep and [[separate two authors in citation]] # # 2. Macros re-used in the style definitions @@ -124,11 +135,11 @@ CiteFormat default !endlink {!!} # "Author et al." or "??" - !abbrvauthor {%abbrvauthor%[[%abbrvauthor%]][[??]]} + !abbrvciteauthor {%abbrvciteauthor%[[%abbrvciteauthor%]][[??]]} # "Author, ..." or "??" - !fullauthor {%fullauthor%[[%fullauthor%]][[??]]} + !fullciteauthor {%fullciteauthor%[[%fullciteauthor%]][[??]]} # Handle starred command: abbr. or full author list - !makeauthor {%ifstar%[[%!fullauthor%]][[%!abbrvauthor%]]} + !makeauthor {%ifstar%[[%!fullciteauthor%]][[%!abbrvciteauthor%]]} # "prenote " !textbefore {%textbefore%[[%textbefore% ]]} # ", postnote" @@ -155,6 +166,8 @@ CiteFormat default citeyearpar %!open%%!textbefore%%!startlink%%!year%%!endlink%%!nextyear%%!textafter%%!close% # "Add to bibliography only." (dialog) / "[ID] (not cited)" (button) nocite {%dialog%[[%_addtobib%]][[%key%%!nextkey% (%_notcited%)]]} + # Output only the key + keyonly {%dialog%[[%_keyonly%]][[%_key%: %key%%!nextkey%]]} End CiteFormat authoryear