LaTeX forum ⇒ BibTeX, biblatex and bibercitations in ( ) format, not [ ]

Information and discussion about BiBTeX - the bibliography tool for LaTeX documents.
blinklily
Posts: 2
Joined: Wed Jan 28, 2009 7:11 am

citations in ( ) format, not [ ]

Postby blinklily » Sat Jan 31, 2009 1:22 am

I'm using a style file for my thesis and I need the citations to be in [1] format, but for some reason that I cannot find it puts it like this: (1), I have the bibstyle set to ieeetr but still comes with () instead of []. Help :oops: Here is where I think it might be occurring (in the style file) but this stuff baffles me. Thanks

% Bibliography/references changes

% Fix the bibliography environment of report.sty to use \fchapter.
\def\thebibliography#1{\fchapter{\bibname\@mkboth
{\uppercase{\bibname}}{\uppercase{\bibname}}}\list
{\@biblabel{\arabic{enumiv}}}{\settowidth\labelwidth{\@biblabel{#1}}%
\leftmargin\labelwidth
\advance\leftmargin\labelsep
\usecounter{enumiv}%
\let\p@enumiv\@empty
\def\theenumiv{\arabic{enumiv}}}
\def\newblock{\hskip .11em plus.33em minus.07em}%
\sloppy\clubpenalty4000\widowpenalty4000
\sfcode`\.=\@m}


% Call \authordatereferences before beginning thebibliography to suppress
% the numbering of references. The following is taken from apalike.sty.
\def\authordatereferences{%
\def\@cite##1##2{(##1\if@tempswa , ##2\fi)}
\def\@biblabel##1{}

% Set length of hanging indentation for bibliography entries
\newlength{\bibhang}
\setlength{\bibhang}{2em}

\def\thebibliography##1{\fchapter{\bibname\@mkboth
{\uppercase{\bibname}}{\uppercase{\bibname}}}\list
{\relax}{\setlength{\labelsep}{0em}
\setlength{\itemindent}{-\bibhang}
\setlength{\leftmargin}{\bibhang}
\usecounter{enumiv}% % kludge!
\let\p@enumiv\@empty % kludge!
\def\theenumiv{\arabic{enumiv}}}% % kludge!
\def\newblock{\hskip .11em plus .33em minus .07em}
\sloppy\clubpenalty4000\widowpenalty4000
\sfcode`\.=\@m}

% `; ' goes between cites, and there's no \hbox around individual cites
%
\def\@citex[##1]##2{\if@filesw\immediate\write\@auxout{\string\citation{##2}}\f
\let\@citea\@empty
\@cite{\@for\@citeb:=##2\do
{\@citea\def\@citea{;\penalty\@m\ }%
\def\@tempa##1##2\@nil{\edef\@citeb{\if##1\space##2\else##1##2\fi}}%
\expandafter\@tempa\@citeb\@nil
\@ifundefined{b@\@citeb}{{\reset@font\bf ?}\@warning
{Citation `\@citeb' on page \thepage \space undefined}}%
{\csname b@\@citeb\endcsname}}}{##1}}

marco_d
Posts: 57
Joined: Tue Jan 20, 2009 7:49 pm

Postby marco_d » Sat Jan 31, 2009 11:08 am

Hello,

you can use the package cite or natbib. The brackets are an option of these packages.

regards
Marco
i am German. I can not use difficult words. :-)


Return to “BibTeX, biblatex and biber”

Who is online

Users browsing this forum: No registered users and 2 guests