LyX ⇒ citation prefix unavailable
citation prefix unavailable
I try to add citations to the lyx document. I use biblatex as described in the lyx documentation (adding stuff to the preamble, putting the bibliography inside comment to be recognized by lyx editor,
biber is set as processor in the lyx settings).
I can not add any 'Text before' item in the citation editor. The Field Formatting -> Citation Style allways shows [#ID, <my given Text after>]
The field Text before: is allways disabled. Any idea why I can not access this field?
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
- Johannes_B
- Site Moderator
- Posts: 4182
- Joined: Thu Nov 01, 2012 4:08 pm
Re: citation prefix unavailable
i am not a LyX user, right now i don't even know if you are talking about the LyX interface or the final pdf.
Can you explain in more detail, maybe even give a screenshot (if LyX is making trouble) or post a minimal example LyX-file that reproduces the output pdf?
citation prefix unavailable
I mean the lyx editor. When I choose the editor function
Insert->Citation...
the following popup is opening: I have marked the fields which I can not edit. It is not possible to enter a text inside the input field 'Text before' and I have no idea how to get it working. I guess it is related o the select box 'Citation style' but I could not figure out yet how it is working.
- Johannes_B
- Site Moderator
- Posts: 4182
- Joined: Thu Nov 01, 2012 4:08 pm
citation prefix unavailable
With usual Author date styles, you can add something like see also before the reference, which will also work when the whole thing is in parenthesis. For an alphabetic style, this would go outside of the brakets, meaning, you can just add it in your regular text and then add the citation.
Re: citation prefix unavailable
I would expect the 'before text' to appear before the citation text generated from the bibliography entry.
My special needs are: The citation should appear as footnote on the page with the citation text, not only the reference to the bib entry.
Therefore I put the citation inside a footnote.
There is no other way I know to use the citation dialog in lyx and get the citation as footnote on the same page.
In plain tex it works out of the box to put the prefix to the citation like this \cite[before text][after text]{key}, but not with the lyx citation dialog.
Of course I can put the 'text before' as simple text before the citation. But this way I loose the possibility to restyle the citation afterwards as the 'text before' is not part of the citation. biblatex offers you the possibility to customize the styling completely by use of the \DeclareCiteCommand. Using this command you also have access to the 'text before' element.
The point is: I can not add the [text before] as part to the citation text using the lyx dialog. So far I have not found a way to go arround this limitiation inside lyx. This is bad. Using plain tex instead offers me all I need but then I have to deal with editing plain tex (what is not so bad at all, but it would be nice to have lyx for editing)
- Johannes_B
- Site Moderator
- Posts: 4182
- Joined: Thu Nov 01, 2012 4:08 pm
citation prefix unavailable
pvogel2 wrote:The point is: I can not add the [text before] as part to the citation text using the lyx dialog. So far I have not found a way to go arround this limitiation inside lyx. This is bad. Using plain tex instead offers me all I need but then I have to deal with editing plain tex (what is not so bad at all, but it would be nice to have lyx for editing)

Since you are ok with writing LaTeX (not plain TeX), just use that with an editor that feels comfortable. Or keep using LyX and use those red ERT boxes.
Code: Select all
\documentclass{article}
\usepackage[style=authoryear,backend=biber]{biblatex}
\addbibresource{biblatex-examples.bib}
\begin{document}
i bet there is something interesting\footcite[as seen in][12]{springer}
\printbibliography
\end{document}