AsciidocFX icon indicating copy to clipboard operation
AsciidocFX copied to clipboard

chinese word issue

Open tbs575 opened this issue 2 years ago • 5 comments

Using asciidocfx 1.8.3, and met some issue with words.

  1. can not display chinese fonts in editor and preview, like italic, bold. image

  2. how to export PDF with chinese?

tbs575 avatar Jan 11 '23 05:01 tbs575

  1. how to export PDF with chinese?

You have three ways to export a PDF containing Chinese.

Method 1 - use AsciidocFX buildin Template

Step1: In AsciidocFX , Left Tree , don't select anything , popup menu, New Template -> Asciidoctor-PDF CJK Demo

Step2: Goto Asciidoctor-PDF CJK Demo , Open README.adoc , Then you can export PDF

Step3: Edit cjk-theme.yml , You can change fonts.

Note: This Template Not Support Italic, Bold, BoldItalic。

Method2 - Install asciidocfx-pdf-cjk-patch ( https://github.com/life888888/asciidocfx-pdf-cjk-patch )

中文日文韓文字型 Noto Sans CJK,Noto Sans Mono CJK,Noto Serif CJK 包含4種樣式(Regular,Italic,Bold,BoldItalic自動下載跟開箱即用。

Method3 - Install asciidocfx-pdf-fop-cjk-patch ( https://github.com/life888888/asciidocfx-pdf-fop-cjk-patch )

中文日文韓文字型 Noto Sans CJK,Noto Sans Mono CJK,Noto Serif CJK 包含4種樣式(Regular,Italic,Bold,BoldItalic自動下載跟開箱即用。

life888888 avatar Jan 12 '23 02:01 life888888

For HTML output, you should modify the default asciidoctor css meaning provide a custom stylesheet, and include required Chinese web fonts. For PDF output, you can follow the paths that @life888888 provided.

rahmanusta avatar Jan 12 '23 10:01 rahmanusta

@rahmanusta

AsciidocFX Preview Not Show italic, bold. (Chinese Text)

2023-01-13_14-20-46

But Export HTML , HTML Can Show italic, bold. (Chinese) , But I don't use any asciidoctor css.

Attatch File EngChtCompare.adoc , You can use AsciidocFX open it , and use HTML -> SAVE

But Save to Html , Html can show italic, bold. (Chinese Text)

2023-01-13_14-22-22

EngChtCompare.adoc.txt

EngChtCompare.html.txt

life888888 avatar Jan 13 '23 06:01 life888888

Hi,

I see the issue now, thank you. Was it working in older versions of AsciidocFX ?

rahmanusta avatar Jan 13 '23 14:01 rahmanusta

  • 1.5.4, 1.6.4, 1.7.4 all have the same issue. (In Ubuntu 20.04) - Open EngChtCompare.adoc , and check preview.

  • Before test difference version , I am delete ~/.AsciidocFX-x.x.x and ~/.com.kodcu.boot.AppStarter.

life888888 avatar Jan 13 '23 16:01 life888888