Problems with backslashes

When I put the name of some author as G\"{u}nter and export to Bibtex, the backslash is replaced by \textbackslash, which is not desirable. Is there any way to fix this?

Thanks!
  • You're putting G\"{u}nter in the Zotero field? Don't do that. Zotero isn't a BibTeX-specific tool. Put data in Zotero fields as is. If you want escaped characters in BibTeX output, change the export charset.
  • This is rather strange. In terms of implementation, it should be easier to leave things as they are instead of changing \ to \textbackslash.

    If there is no way to fix this in Zotero, do I have to set up LaTeX so that it will recognize UTF8?

    Thanks!
  • It actually is desirable. Zotero expects you to enter fields as you want them and not in TeX. So if Zotero sees a backslash it figures you actually want one there and thus exports it as \textbackslash to bibtex. Just writing the regular u with dots in Zotero and setting the character encoding right (I believe to ISO? but someone has to help me out here) will export this to \"{u} with bibtex export. There are a bunch of threads on this on the forum if you search.
  • I see what you mean. I tried all the westerns and isos, none of them seems to work :-(.

    Thanks!
  • Anyone, plz help! Any Zotero developer? Thanks.
  • I see how to fix it: choose UTF-8 without BOM.

    This is probably something that was overlooked by the developing team, since UTF-8 and UTF-8 without BOM should only have one difference: the BOM (byte ordering marker). I hope some developer will see this post and fix the UTF-8 option. Thanks!
  • Thanks so much, phuquocvn! I was looking for a solution to the same problem and that worked perfectly for me too.
  • Just to let people from the internet who land her know: 10+ years later, this problem still persists: You have to choose "UTF-8 without BOM" if you want to get the correct formatting for you Bibtex enty.

    (The name "UTF-8 without BOM" should really be changed to something that indicates that this is what people want to select when exporting to Bibtex, since this is probably a very frequent use-case.)
  • The correct charset to select if you want escaped characters in BibTeX is "Western" and that's working for me (and, I suspect others: we'd get more reports otherwise).

    If you're certain that this is not working for you and UTF-8 without BOM is (it shouldn't), provide a debug output ID for an export with that setting.
    https://www.zotero.org/support/debug_output#zotero
  • Yeah that's just a bug, obviously, as @phuquocvn pointed out a decade ago. I've fixed that — your Zotero should have the fix within a few minutes.

    If you want TeX escape sequences, use Western (which has certainly worked for many years).
  • (I think we'll also remove the "without BOM" option, which doesn't actually do anything.)
Sign In or Register to comment.