5

Where are the BibTeX style sheets that can be used by "Preferences -> TeX preview" in BibDesk?

I would like to add my own.

  • Welcome to TeX.SX! My understanding is that so long as the .bst file is somewhere where a normal TeX distro would find it (such as in TEXMFHOME), then you should be able to use it. You will just have to type the full name of the .bst file yourself. – Adam Liter Feb 28 '15 at 18:41
  • When I put it in texmf and enter the full name, I get an error. Do I have to configure my Tex distro somehow? I'm using BibDesk with Pages. – jjack Feb 28 '15 at 19:05
  • Is it in ~/Library/texmf/bibtex/bst/ or just ~/Library/texmf/? – Adam Liter Feb 28 '15 at 19:07
  • The first, i.e. ~/Library/texmf/bibtex/bst/. And I have TexShop installed. – jjack Feb 28 '15 at 19:09
  • Hmm. I'm not sure. That's how things are set up for me, and it works fine. – Adam Liter Feb 28 '15 at 19:39
6

In order for BibDesk to use a particular style file in its TeX preview, the .bst file only needs to be somewhere where a normal TeX distribution can find it, such as in TEXMFHOME. Since we're talking about a Mac here (because of BibDesk), this usually means that it needs to be in ~/Library/texmf/bibtex/bst/.

(If you do not know how to set up the TEXMFHOME folder, see Alan Munn's answer to How to have local package override default package.)

Once you have your local TEXMFHOME folder set up with the correct directory structure, place the .bst file that you would like to use in BibDesk's TeX preview in ~/Library/texmf/bibtex/bst/.

Next, you need to change the .bst file that BibDesk uses. You can do this by going to BibDesk > Preferences, or by just hitting +, when you have BibDesk open. Click on TeX Preview, where you will this screen:

enter image description here

You need to change the BibTeX style to whichever .bst file that you would like to use. For example, I use a custom .bst file called unified, so I would change apalike to say unified. After I type unified and hit enter, I see this screen come up:

enter image description here

You can go ahead and just click on Use Anyway, and everything should work just fine. Clicking Edit TeX template allows you to edit the preamble of the .tex file that renders the TeX preview in BibDesk. When I click Edit TeX template, it opens the preamble in TeXShop, since that is my default TeX editor.

This isn't strictly necessary and, like I said, you can just go ahead and click Use Anyway and things should work fine.

However, it can be useful to edit the TeX template. For example, the unified.bst file that I use typesets DOIs, but there are many DOIs that contain an underscore, which causes an error.

So, I have edited the TeX template to include the following in the preamble (see Citation with DOI that has underscore breaks functionality in BibDesk):

\usepackage{hyperref}
\newcommand{\doi}[1]{\textsc{doi}: \href{http://dx.doi.org/#1}{\nolinkurl{#1}}}

But again, you should be able to just hit Use Anyway and have things work so long as your .bst file is somewhere where a normal TeX distribution would be able to see it (such as in the TEXMFHOME folder) and so long as your .bst file doesn't depend on any other packages/macros. If the functionality of the .bst file depends on other packages/macros, then you will necessarily have to edit the TeX template and include those in the preamble of the TeX template.

  • Great, it works. Thank you very much. I had the texmf folder in the wrong library directory. – jjack Feb 28 '15 at 20:50
  • 1
    This is a great answer, but note that a more succinct version is also found in BibDesk's Help book, easily accessible via its Help menu. Hint, hint :). bibdesk.sourceforge.net/manual/BibDeskHelp_65.html#SEC125 – Adam Maxwell Feb 28 '15 at 20:53

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.