Replies: 2 comments 5 replies
|
Writing a filter using the quote AST elements is rather trivial: just filter on the double-quoted/single-quoted tags and replace them with a span including the literal quote marks you want. Without those AST elements it would be a lot harder. I have written two Pandoc filters which do this. Both let you specify which quotes to use in Pandoc metadata, which unfortunately doesn't work yet in djot. The new one also lets you specify "local" quotes as attributes on divs, to be applied only within that div. It also lets you specify characters to replace the |
|
Are you wanting to have a system where |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Languages generally use different forms of quotation marks, Wikipedia has an overview.
The style of smart quotation in djot is specific to English. This, for example, makes German text with quotations look weird. Correct would be „Guten Morgen“, but djot outputs “Guten Morgen“.
Djot generally seems to avoid language-specific features, so this stands out. Personally, I would prefer having English-style smart quotations as a filter or optional feature, rather than part of the core syntax. Different styles could then be implemented in a similar fashion. What do you think?
All reactions