Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm trying to move everything nonessential into the margins. But I couldn't find how BibLaTeX generates the entries' labels (like [1] generated by \cite and in front of the item in the list, don't know the exact term).

I want these labels in the margin (by surrounding them with \llap).

Inserting the following after \usepackage{biblatex} just lets the labels disappear:

\defbibenvironment{bibliography}{\list{%
    \llap{here}%
    \hspace{0.5em}%
}{%
    \setlength\leftmargin{0pt}%
}}{\endlist}{\item}

What code do I have to insert here to print the label? (Regardless of the style, this should work with style=alphabetic and style=numeric for example)

(complete example seems like overkill?)

Intended result at the bottom

Here, the [1] is hardcoded.

share|improve this question
add comment

1 Answer 1

Each style loads its .bbx file which defines its own bibliography (bib)environment, so I think that a solution working for all the styles it's not easy to achieve. In the case of the numeric style, you could define (in the preamble of your document) the bibliography (bib)environment like this:

\makeatletter
\defbibenvironment{bibliography}
{\list{\printtext[labelnumberwidth]{%
    \printfield{prefixnumber}%
    \printfield{labelnumber}}}
{\setlength{\bibhang}{0pt}%
\setlength{\leftmargin}{\bibhang}%
\setlength{\itemindent}{-\leftmargin}%
\setlength{\itemsep}{\bibitemsep}%
\setlength{\parsep}{\bibparsep}}}
{\endlist}
{\item}
\makeatother
share|improve this answer
    
didn't think of that… I actually wanted something that would work with any style (since it's only layout) though. But I found the bbx'es now, it seems they just use \defbibenvironment, too, piecing together the label there. I thought there was a common macro… –  pascal Jul 22 '11 at 23:20
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.