1

I am using natbib package and I want to make author names bold in references as in this article: Natbib authors bold. The solution on that article use "jurabib" package. Isn't there any way to do this with "natbib"?

Maybe editing the file "apalike.bst", but how?

1 Answer 1

3

I suggest you proceed as follows:

  • Find the file apalike.bst in your TeX distribution and create a copy called, say, apalike-bf.bst.

  • Open the file apalike-bf.bst in a text editor. The program you use to edit your tex files will do fine.

  • In the bst file, locate the 6-line BibTeX function emphasize. (In my copy of the file, this function starts on line 200.) Make a copy of this function, name it embolden, and change \em to \bfseries. Place the new embolden function immediately below the emphasize function.

  • Next, go down a few lines in the bst file and locate the function called format.names. In that function, locate the following line:

        { s nameptr "{vv~}{ll}{, jj}{, f.}" format.name$ 't :=
    

    Change this line to

        { s nameptr "{vv~}{ll}{, jj}{, f.}" format.name$ embolden 't :=
    
  • Save the file apalike-bf.bst either in the directory that contains your main tex file or in a directory that's searched by BibTeX. If you choose the latter option, be sure to update the filename database of your TeX distribuition. (If you're not sure you understand the preceding sentence, you should follow the former option.)

  • In your main tex file, change \bibliographystyle{apalike} to \bibliographystyle{apalike-bf} and perform a full recompile cycle: LaTeX, BibTeX, and LaTeX twice more.

Happy BibTeXing!


Addendum to address the OP's follow-up question about how to render the connector word "and" in bold: In the file apalike-bf.bst, in the BibTeX function format.names (the same one as above), locate the following 4 lines:

        { ", " * t * }
            { ", " * t * }
            { " et~al." * }
            { " and " * t * }

Replace these lines with

        { "\textbf{,} " * t * }
            { "\textbf{,} " * t * }
            { " \textbf{et~al.}" * }
            { " \textbf{and} " * t * }

Then, save the bst file and rerun a full recompile cycle.

3
  • 1
    What a great explanation! Thank you so much. One more thing, your solution works like a charm, but the word "and" between authors stay unbold. Could we fix this too? Aug 25, 2021 at 10:22
  • @PhilipJohnson - Please see the addendum I just posted.
    – Mico
    Aug 25, 2021 at 11:45
  • 1
    All hail the hero of the day! Cheers! Aug 25, 2021 at 12:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .