> On May 23, 2024, at 5:16 AM, Christiaan Hofman <[email protected]> wrote:
> 
> I am not sure what to do exactly about the underscore and the dueling 
> requirements for URL and tex. I am also not completely sure about what tex 
> can handle, also combined with the \url command. One option may be to use a 
> tex conversion  for the underscore, so it its saved as {\_} in .bib, but in 
> BibDesk it turns up as _.

I don't think TeX conversion of URL and DOI fields is a good idea, although I 
haven't analyzed all the implications of such a choice. Adam R. Maxwell's 
response seemed right to me: you "need to edit the BibTeX style to 
interpret/display those fields correctly, instead of altering the underlying 
data to be incorrect".

> On May 22, 2024, at 9:02 PM, Adam R. Maxwell via Bibdesk-users 
> <[email protected]> wrote:
> 
> You are missing something, although I don't know if it's obvious. You (or 
> Elsevier) need to edit the BibTeX style to interpret/display those fields 
> correctly, instead of altering the underlying data to be incorrect. Take a 
> look at how abbrvnat.bst (to pick a random example) handles this. 
> Unfortunately, not all styles handle a "doi" field correctly, so you may not 
> find a one-size-fits-all solution. 
> 
> If you can't modify the style or are sending your input files to Elsevier, 
> you might look into wrapping the doi field contents in a \url command (style 
> will be tricky here), or just export a minimal BibTeX file without doi and 
> send that.
> 
> A final option if you can't modify the style would be to send the contents of 
> your .bbl file after you correctly handle doi (or just insert the \bibitem 
> commands to your document to produce camera-ready copy). IIRC some publishers 
> require this, as they won't use BibTeX.


By the way, I encountered similar URL encoding issues some years ago when 
exporting citations to HTML with a BibDesk export template. As I recall, the 
problem was that I needed to translate some characters in URLs to HTML entities 
such as "&amp;", "&gt;", "&lt;". I solved that particular problem by 
post-processing the exported HTML with a simple regex shell script.

Nathan

_______________________________________________
Bibdesk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-users

Reply via email to