[OS X TeX] Re: Bibtex and non-ASCII characters

Adam R. Maxwell amaxwell at mac.com
Sun Nov 11 01:21:20 CET 2007

On Nov 10, 2007, at 3:35 PM, Markus S wrote:

> On 2007-11-11 00:10:41 +0100, "Adam R. Maxwell" <amaxwell at mac.com>  
> said:
>> Well, "&" /is/ part of the ASCII character set.  It just needs to  
>> be  escaped in TeX.
> You are right, to be precise: Non-ASCII caracters and ASCII  
> characters that need to be escaped in TeX.
>>> Currently, I am sometimes replacing the & symbol with \& within   
>>> Endnote, sometimes in the .bib file. Doing it always in Endnote   
>>> would be safer way but browsing Endnote this looks a bit odd.
>>> My (planned) way out is to use a Perl script that converts all  
>>> non- ASCII characters in the .bib file exported from Endnote so  
>>> that  things work in Latex. I have the Perl script, the tough job  
>>> is to  come up with a list of all characters that have to be  
>>> replaced (and
>>> I first have to reverse all the characters I've already fixed within
>>> Endnote).
>> You could do this in BibDesk with regular expression find and replace
>> or AppleScript, which may be easier than manipulating the .bib  
>> file  directly.  BibDesk also converts non-ASCII characters such as  
>> ø or ü   to the appropriate TeX sequence if you want (see the  
>> Files preference
>> pane).
> Yes, the Umlaut and accents are taken care of in BibDesk. It also  
> ignores any environments put around stuff (like {} or \ce{CO2}) and  
> only displays the characters itself (ie, CO2). But it only covers  
> some stuff.

It's not reasonable from a performance standpoint to parse/remove all  
TeX for display.

> Take the & symbol, the degree sign, chemical formulas, the whole  
> issue of protecting capital letters (eg, abbreviations) inside the  
> fields.There is so much stuff that has to be hand-coded and if you  
> are not very diligent about where you do it (GUI interface or .bib  
> file), you are going to keep correctiong the same things over and  
> over again.

If you're managing the file with EndNote and keeping it free of BibTeX- 
isms, that's likely going to be painful.  I manage .bib files directly  
with BibDesk, so the changes are at least persistent, but converting  
between formats is a difficult problem because of BibTeX/TeX syntax.

> My goal is to get the stuff from, eg, Web of Science, export it from  
> Endnote into a folder with an attached folder action that takes care  
> of everything.

Have fun!  It sounds like you have used BibDesk, but I'll point out  
that you can now search Web of Science and other ISI databases in  
BibDesk.  We backslash-escape & and % when importing from WoS and  
SciFinder, since those are common characters in titles; RIS sources  
get an even more complex conversion, since some publishers dump HTML  
into their RIS.


More information about the macostex-archives mailing list