https://bugs.kde.org/show_bug.cgi?id=426856

--- Comment #8 from neurosh...@hotmail.com ---
(In reply to nobodyinperson from comment #7)
> Thanks for bringing this up again. It's currently also a big pain point for
> me. It seems that KBibTeX v0.10.0 doesn't how to encode some Unicode
> characters (non-breaking spaces, weird dashes, etc.) to LaTeX. Ran from the
> terminal, these are the errors for me (a location in the file would be
> helpful):
> 
> ```bash
> kbibtex.io: Don't know how to encode Unicode char "0x00a0"                  
> 
> kbibtex.io: Don't know how to encode Unicode char "0x2010"  
> kbibtex.io: Don't know how to encode Unicode char "0x2010"                  
> 
> kbibtex.io: Don't know how to encode Unicode char "0x202f"                  
> 
> ```
> 
> When I find-replace those characters in the file (in vim, do   
> `:%s/\%u202f/ /g`    and `%s/\%u00a0/-/g`  etc.), then KBibTeX is finally
> stable when saving the encoding again and stays at LaTeX encoding. 😮‍💨

You very much helped me here! I dug through my (large) .bib file in a text
editor, and eventually found some characters that KBibTeX was having trouble
converting to LaTeX. In my case, they were the characters α (alpha) and ’
(single right apostrophe). Once I replaced them with LaTeX-friendly characters,
namely, {$\alpha$} and ', the problem disappeared, and KBibTeX is now stably
saving with LaTeX encoding.

So the lesson here is to make sure there are no troublesome characters in the
.bib file! Ideally KBibTeX would handle this problem more elegantly, either
warning the user about bad characters, or at least not encoding the whole file
as UTF-8.

Thanks!

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to