LaTeX forum ⇒ BibTeX, biblatex and biberlong citations for multiple formats

Information and discussion about BiBTeX - the bibliography tool for LaTeX documents.
ExecutorElassus
Posts: 79
Joined: Wed Sep 07, 2011 3:14 pm

long citations for multiple formats

Postby ExecutorElassus » Mon Oct 02, 2017 8:42 am

Oh! I misunderstood. I thought you wanted a .pdf file, when I think (??) you want a .tex file. Is that correct? If so, it's attached.

Cheers,

EE
Attachments
ibid tester.tex
(1.68 KiB) Downloaded 6 times

Tags:

User avatar
Johannes_B
Site Moderator
Posts: 3582
Joined: Thu Nov 01, 2012 4:08 pm

Postby Johannes_B » Tue Oct 03, 2017 10:11 am

The following code is provided by one of the biblatex contributors. Personally, i have no idea what is going on or is expected.

moewe wrote:Oh crikey, that is a complicated one. The code in biblatex-chicago is really complicated and lengthy and can be a pain to modify. There is \ifuniquework to check for situations where one labelname-labeltitle combination occurs more than once, one could use that to add additional information. It is not clear to me, however, what the expected behaviour would be in that case. What would one add? Can we make sure that by adding that bit we get a unique citations? Etc.?

Not really keen on signing up for another forum, but a first suggestion can be found at gist.github.com/moewew/9805f72a43ca2cc56ee6e4c3819a2354 This will issue a full citation if the short 'name-title' is not unique. For LyX users note that I had to add the loading option uniquework=true to biblatex-chicago (this is crucial), the other interesting bit is between the redefinition of cite.
Source

  1. \documentclass{article}
  2. \usepackage{fontspec}
  3. \usepackage{polyglossia}
  4. \setdefaultlanguage[variant=american]{english}
  5. \setotherlanguage[variant=german,spelling=new,babelshorthands=true]{german}
  6. \newenvironment{ngerman}{\begin{german}}{\end{german}}
  7. \usepackage[notes, natbib, backend=biber, alldates=edtf, idemtracker=context, ibidtracker=context, dateabbrev=false, language=american, autocite=footnote, uniquework=true]{biblatex-chicago}
  8. \renewcommand{\citet}[1]{\autocite{#1}}
  9.  
  10. \defaultfontfeatures{Ligatures=TeX,Numbers=OldStyle}
  11. \setmainfont{Linux Libertine O}
  12. \setsansfont{Linux Biolinum O}
  13.  
  14.  
  15. \usepackage{filecontents}
  16. \begin{filecontents}{\jobname.bib}
  17. % Encoding: UTF-8
  18.  
  19. @Audio{logothetis1970anastaseis,
  20. author = {{A}nestis {L}ogothetis},
  21. title = {Άναστάσεις},
  22. year = {1971},
  23. note = {{S}y. 2210},
  24. organization = {{G}. {R}icordi und {C}o. {B}{\"u}hnen- und {M}usikverlag, {G}mb{H}},
  25. location = {{M}{\"u}nchen},
  26. }
  27.  
  28.  
  29. @Video{logothetis1970anastasisvideo,
  30. author = {{A}nestis {L}ogothetis},
  31. editor = {{S}iegfried {B}ehrend},
  32. title = {Άναστάσεις},
  33. year = {1970},
  34. date = {1970-06-24},
  35. organization = {{S}aarl{\"a}ndischer {R}undfunk},
  36. location = {Saarbr{\"u}cken},
  37. url = {https://www.youtube.com/watch?v=yzdC56ByWqU},
  38. urldate = {2017-06-28},
  39. editora = {{C}laudia {B}rodzinska-{B}ehrend},
  40. editoratype = {none},
  41. editortype = {director},
  42. }
  43.  
  44. @Music{logothetis1985anastaseis,
  45. author = {{A}nestis {L}ogothetis},
  46. editor = {{S}iegfried {B}ehrend},
  47. title = {Άναστάσεις},
  48. year = {1985},
  49. type = {LP},
  50. editortype = {director},
  51. publisher = {{A}madeo},
  52. series = {{\"O}sterreichische {M}usik der {G}egenwart},
  53. }
  54.  
  55. @Misc{logothetis1970anastasissendung,
  56. author = {{A}nestis {L}ogothetis},
  57. editor = {{S}iegfriend {B}ehrend},
  58. title = {Άναστάσεις},
  59. year = {1970},
  60. date = {1970-06-24},
  61. type = {radio broadcast},
  62. location = {{S}aarbr{\"u}cken},
  63. editora = {{C}laudia {P}rodzinska-{B}ehrend},
  64. editoratype = {none},
  65. editorb = {{E}wald {L}iska},
  66. editorbtype = {none},
  67. editortype = {director},
  68. publisher = {{S}aarl{\"a}ndischer {R}undfunk},
  69. series = {{H}{\"o}rspielabend},
  70. }
  71.  
  72.  
  73. \end{filecontents}
  74.  
  75. \addbibresource{\jobname.bib}
  76. \addbibresource{biblatex-examples.bib}
  77.  
  78.  
  79. \makeatletter
  80. \newbibmacro*{cite}{%
  81. \ifciteseen%
  82. {\ifboolexpr{%
  83. test {\iffieldundef{shorthand}}%
  84. or
  85. (
  86. togl {blx@skipbiblist}%
  87. and
  88. togl {cms@inheritshhand}%
  89. and
  90. not test {\iffieldundef{crossref}}%
  91. )
  92. }%
  93. {\ifthenelse{\ifciteibid\AND\NOT\iffirstonpage}%
  94. {\usebibmacro{cite:ibid}%
  95. \usebibmacro{cite:save}}%
  96. {\ifuniquework
  97. {\global\toggletrue{cms@shortnote}%
  98. \global\togglefalse{cms@fullnote}%
  99. \usebibmacro{cite:short}}%
  100. {\global\toggletrue{cms@fullnote}%
  101. \global\togglefalse{cms@shortnote}%
  102. \usebibmacro{cite:full}}%
  103. \usebibmacro{cite:save}}}%
  104. {\iftoggle{cms@shorthandibid}%
  105. {\ifthenelse{\ifciteibid\AND\NOT\iffirstonpage}%
  106. {\usebibmacro{cite:ibid}%
  107. \usebibmacro{cite:save}}%
  108. {\usebibmacro{cite:shorthand}%
  109. \usebibmacro{cite:save}%
  110. \global\toggletrue{cms@noidem}}}%
  111. {\usebibmacro{cite:shorthand}%
  112. \usebibmacro{cite:save}%
  113. \global\toggletrue{cms@noidem}}}}%
  114. {\ifboolexpr{%
  115. togl{cms@firstshort}%
  116. and
  117. not test {\iffieldundef{shorthand}}%
  118. }%
  119. {\usebibmacro{cite:shorthand}%
  120. \usebibmacro{cite:save}%
  121. \global\toggletrue{cms@noidem}}%
  122. {\ifboolexpr{togl {cms@allshort} and test {\ifuniquework}}
  123. {\global\toggletrue{cms@shortnote}%
  124. \global\togglefalse{cms@fullnote}%
  125. \global\toggletrue{cms@printshhand}%
  126. \usebibmacro{cite:short}%
  127. \usebibmacro{cite:save}}%
  128. {\global\toggletrue{cms@fullnote}%
  129. \global\togglefalse{cms@shortnote}%
  130. \usebibmacro{cite:full}%
  131. \usebibmacro{cite:save}}}}}%
  132. \makeatother
  133.  
  134. \begin{document}
  135. Lorem\autocite{logothetis1970anastaseis}
  136. ipsum\autocite{logothetis1970anastasisvideo}
  137. dolor\autocite{logothetis1970anastaseis}
  138. amet\autocite{sigfridsson}
  139. sit\autocite{logothetis1970anastasissendung}
  140. amet\autocite{logothetis1985anastaseis}
  141.  
  142. Lorem\autocite{logothetis1970anastaseis}
  143. amet\autocite{sigfridsson}
  144. ipsum\autocite{logothetis1970anastasisvideo}
  145. dolor\autocite{logothetis1970anastaseis}
  146. sit\autocite{logothetis1970anastasissendung}
  147. amet\autocite{logothetis1985anastaseis}
  148. \printbibliography
  149. \end{document}
Attachments
moeweChicago.pdf
(27.09 KiB) Downloaded 5 times
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.


Return to “BibTeX, biblatex and biber”

Who is online

Users browsing this forum: No registered users and 3 guests