Open sati-bodhi opened 4 years ago
What's your pandoc version?
pandoc 2.7.3 Compiled with pandoc-types 1.17.5.4, texmath 0.11.2.2, skylighting 0.8.1
@tarleb is the expert on this and might be able to comment.
The problem stems from the semicolon between the citations: pandoc seems to mishandle the fullwidth semicolon (U+FF1B) in your text. It works if one uses a normal semicolon (U+003B) instead.
We could consider to treat more punctuation characters as "special characters" in the parser, which would resolve this. I will take a look into this.
Yes, if it's a common thing in Asian languages to use the full-width semicolon. Otherwise I don't think we should get into the hole of considering similar unicode chars for all the chars in our syntax.
Full width punctuation is very common at least within the Chinese and Japanese context, partly because words in these two languages are not separated by spaces. For example:
This is a sentence; This is another sentence. これは文です。これは別の文です。 這是一句話;這是另一句話。
Adding a full-stop at the back of the syntax also breaks the code.
cite:陳鼓應YiChuanYuDaoJiaSiXiang1994。
From what I can tell, org-ref cites are special in that they do not conform to the usual emphasis conditions checked by org-mode.
Here are some examples and how they are translated to LaTeX by org-ref:
cite:陳鼓應YiChuanYuDaoJiaSiXiang1994
<cite:陳鼓應YiChuanYuDaoJiaSiXiang1994>
;citep:陳鼓應YiChuanYuDaoJiaSiXiang1994
#citep:陳鼓應YiChuanYuDaoJiaSiXiang1994
$citep:陳鼓應YiChuanYuDaoJiaSiXiang1994
%citep:陳鼓應YiChuanYuDaoJiaSiXiang1994
output
\cite{陳鼓應YiChuanYuDaoJiaSiXiang1994}
\cite{陳鼓應YiChuanYuDaoJiaSiXiang1994}
;\citep{陳鼓應YiChuanYuDaoJiaSiXiang1994}
\#\citep{陳鼓應YiChuanYuDaoJiaSiXiang1994}
\$citep:陳鼓應YiChuanYuDaoJiaSiXiang1994
\%citep:陳鼓應YiChuanYuDaoJiaSiXiang1994
Seems like it is mostly breaking at word boundaries, although I'm a bit confused about $
and %
. I'll have to read the code.
Citations with locator also didn't resolve well.
[[cite:陳鼓應YiChuanYuDaoJiaSiXiang1994][55-100]]
This one got interpreted as a simple link:
Another weird bug that might be a separate issue:
The Pandoc
interpreter renders book citations with an extra text term in between title and publisher.
陳鼓應,《易傳與道家思想》。收入台北:臺灣商務印書館,1994年。
If we use the same csl
file on Zotero or the Visual CSL Editor, the text term should not be there:
Add the following csl-data.json
to Example citations → Advanced → Add new reference
to testify the issue.
[
{"id":"陳鼓應YiChuanYuDaoJiaSiXiang1994","type":"book","title":"易傳與道家思想","publisher":"臺灣商務印書館","number-of-pages":"382","source":"Google Books","ISBN":"978-957-05-0994-6","language":"zh-TW","author":[{"literal":"陳鼓應"}],"issued":{"date-parts":[[1994]]},"publisher-place":"台北"}
]
Should be superceded by #7329?
Does Pandoc currently support the rendering of Org-Ref style citations? The documentation over here seems to suggest it does; but I was not able to get it working correctly.
Org Citations
(saved as
citation_issues.org
)To be rendered as:
CSL:
https://gist.github.com/sati-bodhi/31dd24dd280c88d51908
Bibtex:
(saved as
thesis.bib
)Pandoc:
Result:
Native Pandoc syntax works but org-ref syntax doesn't.