I'm trying to include all the Unicode whitespace characters in a LaTeX document as verbatim text (eg \\verb#start end#
), but I've gotten three different results:
\\usepackage[utf8x,utf8]{inputenc}
I get an error: "Unicode char \\u8: not set up for use with LaTeX." \\usepackage[T1]{fontenc}
I get rubbish, such as á
. Full-blown Unicode input is almost impossible to support in vanilla TeX (of which pdflatex is a variant). There are just too many characters to set up enough fonts to handle everything that might occur; there are many partial solutions, but no complete ones.
The TeXnically correct way to go about this is to use xetex
instead, which was designed with Unicode in mind. That said, don't all spaces look pretty much the same? What do you actually want rendered? Or is the problem really to be able to process any verbatim input whatsoever, without pre-munging?
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.