Re: Links in Chinese
David Goodger <[email protected]>
| Newsgroups | gmane.text.docutils.user |
|---|---|
| Message-ID | <CABiJP=LZ3WxevHUGk9oFDXxuGPZMTijVZeNzTNtR-2ToR1rGfA@mail.gmail.com> |
On Fri, Mar 6, 2015 at 7:18 AM, Dariusz Suchojad <[email protected]> wrote: > > Hello, > > I'm on docutils 0.12 and I'm having a bit of difficulties with making > links containing characters in Chinese to work. > > Consider the example over here converted to HTML using rst2html .. > > https://zato.io/support/docutils/link-cn.txt > https://zato.io/support/docutils/link-cn.html > > .. which works as expected as long as the contents in ``_ is within > ASCII but fails as soon as Chinese copy is included. > > Will appreciate any assistance on that front - it's difficult to use > Chinese texts and docutils without the feature. The problem has nothing to do with ASCII vs. Chinese text (UTF-8 or any encoding). The link with Chinese text simply lacks whitespace between the end of the link text and the <URL>. Just add a space (or a newline, etc.) after the "。" and before the "<": `Zato 是ESB,并且服务都是用Python写的。 <https://zato.io>`_ It may look like there was a space there already, but that's because of the small Chinese period offset to the left in a full-width glyph. The space is necessary to allow for link text that contains "<" and ">" characters. -- David Goodger <http://python.net/~goodger> ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Docutils-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/docutils-users Please use "Reply All" to reply to the list.