Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How can I represent esoteric characters (e.g. character entities) in a document?

0
Posted

How can I represent esoteric characters (e.g. character entities) in a document?

0

For example, say you want an em-dash (XML character entity —, Unicode character U+2014) in your document: use a real em-dash. Insert concrete characters (e.g. type a real em-dash) into your input file, using whatever encoding suits your application, and tell Docutils the input encoding. Docutils uses Unicode internally, so the em-dash character is a real em-dash internally. Emacs users should refer to the Emacs Support for reStructuredText document. Tips for other editors are welcome. ReStructuredText has no character entity subsystem; it doesn’t know anything about XML charents. To Docutils, “—” in input text is 7 discrete characters; no interpretation happens. When writing HTML, the “&” is converted to “&”, so in the raw output you’d see “—”. There’s no difference in interpretation for text inside or outside inline literals or literal blocks — there’s no character entity interpretation in either case. If you can’t use a Unicode-compatible encoding and must

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123