0

I have read many related posts regarding the issue of having squared brackets with biblatex. Unfortunately, none have made me fully understand how to compute the squared brackets. I know that biblatex is not compatible with natbib, so that was not an option.

This is what it looks like now in the text: enter image description here

This is what it looks like in the bibliography: enter image description here

Disered output: I want to have squared brackets instead of the rounded brackets. It seems very simple, but after many frustrating hours I can't figure it out.

This is what it looks in code:

\usepackage[style=numeric, backend=biber]{biblatex} % Adjust bibliography style
\addbibresource{bibliography.bib} % BibTeX bibliography file
\DeclareFieldFormat{labelnumber}{\RN{#1}}

The MWE.tex file:

%----------------------------------------------------------------------------------------
%   DOCUMENTCLASS
%----------------------------------------------------------------------------------------

\documentclass[11pt,a4paper,fleqn,twoside]{book} % Default font size and left-justified equations

%----------------------------------------------------------------------------------------
%   FONTS
%----------------------------------------------------------------------------------------
% itemize with dash
\def\labelitemi{--}

\usepackage{avant} % Use the Avantgarde font

%
\renewcommand{\familydefault}{\sfdefault} % Makes changes in the text font

\usepackage{microtype} % Slightly tweak font spacing for aesthetics
\usepackage[utf8]{inputenc} % Required for including letters with accents
\usepackage[T1]{fontenc} % Use 8-bit encoding that has 256 glyphs


%----------------------------------------------------------------------------------------
%   BIBLIOGRAPHY
%----------------------------------------------------------------------------------------

\usepackage{csquotes}
\usepackage[style=numeric, backend=biber]{biblatex} % Adjust bibliography style
\addbibresource{bibliography.bib} % BibTeX bibliography file
\DeclareFieldFormat{labelnumber}{\RN{#1}}
\defbibheading{bibempty}{}


%----------------------------------------------------------------------------------------
%   START DOCUMENT
%----------------------------------------------------------------------------------------

\begin{document}


%----------------------------------------------------------------------------------------
%   PART II
%----------------------------------------------------------------------------------------

Value-based health care is a health care delivery model that aims to achieve high value for patients, with value defined as health outcomes achieved per dollar spent \cite{porter2010value}.


%----------------------------------------------------------------------------------------
%   BIBLIOGRAPHY
%----------------------------------------------------------------------------------------


\printbibliography


%----------------------------------------------------------------------------------------
%   END DOCUMENT
%----------------------------------------------------------------------------------------

\end{document}

The bibliography.bib file:

@article{porter2010value,
    title={What is value in health care?},
    author={Porter, Michael E},
    journal={New England Journal of Medicine},
    volume={363},
    number={26},
    pages={2477--2481},
    year={2010},
    publisher={Mass Medical Soc}
}
  • 1
    By default biblatex will produce square brackets with style=numeric, and nothing in the code shown in the question suggests otherwise. Can you please post a complete example document that reproduces the output you see. Please test the example document in a new, empty folder to ensure it really reproduces the issue. See tex.meta.stackexchange.com/q/228/35864 and tex.meta.stackexchange.com/q/4407/35864. – moewe Sep 29 at 12:13
  • 1
    It may just be me, but in the screenshot the brackets around the years "(2010)" look slightly different than the brackets around the citation labels. So I would guess that the font you use simply has square brackets that look a bit more round than usual. So this may not be a biblatex issue at all. You may just have to choose a different font with more square square brackets. – moewe Sep 29 at 12:14
  • @moewe, I think you are right! Very insightful comment. Is there a smart workaround to fix the braces? Perhaps: Is there a way to keep the main font for the text, and use another font for the bibliography? – Nadia Merquez Sep 29 at 13:00
  • I wouldn't do it, but you can try and access the square bracket character from a different font, see for example tex.stackexchange.com/q/333171/35864. For more specific advice I would need to see a full example document (see my first comment). – moewe Sep 29 at 13:02
  • @moewe: I added the content of the 'MWE.tex' file, and that of the seperate file 'bibliography.bib' . I hope that works for you. – Nadia Merquez Sep 29 at 13:27
2

As it turns out what you get in the MWE are square brackets, but avant's square brackets are a bit round at the ends. You can, however, still see a small difference between round brackets and square brackets – at least when you see them side by side.

Here is a solution to let biblatex use the square brackets from Latin Modern Sans. Note that this only changes square brackets under biblatex's control and only those that are properly typeset with \mkbibbrackets and friends. If you are looking for a solution that also replaces the characters [ and ] whenever you type them in, I suggest you ask a new question about that (since it has nothing to do with biblatex at all).

\documentclass[british]{article}

\usepackage{avant}
\renewcommand{\familydefault}{\sfdefault}

\usepackage{microtype}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

\usepackage{babel}
\usepackage{csquotes}

\usepackage[style=numeric, backend=biber]{biblatex}

\newcommand*{\sqqbrackleft}{{\usefont{T1}{lmss}{m}{n}\symbol{91}}}
\newcommand*{\sqqbrackright}{{\usefont{T1}{lmss}{m}{n}\symbol{93}}}

\makeatletter
\renewcommand*{\bibleftbracket}{\blx@postpunct\sqqbrackleft}
\renewcommand*{\bibrightbracket}{\blx@postpunct\sqqbrackright\midsentence}
\makeatother

\addbibresource{biblatex-examples.bib}

\begin{document}
[square] (round)

\sqqbrackleft square\sqqbrackright

\cite{sigfridsson}
\printbibliography
\end{document}

avant with biblatex-controlled square brackets from lmss

  • Thanks for the effort and solution. I upvoted and marked your answer as the correct one. And yes, I would actually want to adjust the brackets also for the text as well. I will be posting a new question. – Nadia Merquez Sep 29 at 14:18
-1

I would recommend to use

\usepackage[style=numeric,backend=bibtex8]{biblatex}

if there's no specific need for biber. Most of the time, bibtex8 works fine for me and when it doesn't, I quickly find a solution.

  • The backend should make absolutely no difference to the issue at hand. This is purely a font (or style) issue which is only controlled by the LaTeX side of things. I would also strongly like to disagree with the statement that there is no specific need to use Biber. Many of biblatex's advanced features only work with Biber. Indeed a while ago BibTeX was designated a legacy backend that is only supported for backwards compatibility and the documentation assumes Biber is used. Unless there are reasons that force you to use BibTeX, I strongly recommend using Biber. – moewe Sep 29 at 13:39
  • 1
    I agree with moewe. The problem boils down to: Adjust the squared brackets '[' and ']' of the avant font type such that the squared brackets become less roundish. I would like them to look like a regular squared bracket. – Nadia Merquez Sep 29 at 13:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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