3

Here is a near minimal working example. I added Chinese text to show it works outside URLs.

\documentclass{article}

% Load packages 
\usepackage{xeCJK}
\usepackage{url}

% Begin the document
\begin{document}

這樣可以寫中文!

\url{https://zh.m.wikipedia.org/zh-hant/钱谦益.#.E8.BF.8E.E5.A8.B6.E6.9F.B3.E5.A6.82.E6.98.AF}

\end{document}

How to remedy the problem that the Chinese characters in the URL aren't displayed? The output is this: enter image description here

4

You need as url font a font that contains all the glyphs used in your url. E.g.

\documentclass{article}

\usepackage{xeCJK}

\usepackage{url}

\newfontfamily\urlfontfamily{FandolSong-Regular}
\def\UrlFont{\urlfontfamily}

\begin{document}

這樣可以寫中文! 


\url{https://zh.m.wikipedia.org/zh-hant/钱谦益.#.E8.BF.8E.E5.A8.B6.E6.9F.B3.E5.A6.82.E6.98.AF}

\end{document}

enter image description here

  • Thanks! It took some time to get the typesetter on the iPad to learn new fonts, but it's the correct answer! – Ludi Jul 28 '17 at 11:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.