AsciidocFX icon indicating copy to clipboard operation
AsciidocFX copied to clipboard

How to adjust the font-weight?

Open yimikite opened this issue 7 years ago • 5 comments
trafficstars

I chose to use a Chinese font in the Windows font library, which contains 7 types of font-weights, but the default displayed font-weight is the thinnest. How to adjust the font-weight?

Font: Noto Sans CJK SC

Set the full name of the font to be unrecognized and the exported PDF will display ###. For example, Noto Sans CJK SC Bold.

yimikite avatar Aug 30 '18 08:08 yimikite

Do you use it in html or pdf?

rahmanusta avatar Aug 30 '18 19:08 rahmanusta

I use it in pdf. I modified the fo-pdf.xsl file in reference what hefanbo said in #138 and added the Chinese font Noto Sans CJK SC Black, a separate OTF file under the Noto Sans CJK SC family font. However, it does not take effect. After exporting the PDF file, the Chinese is displayed as ###. image

yimikite avatar Aug 31 '18 07:08 yimikite

Can you share a test document for me including Chinese characters.?

rahmanusta avatar Sep 02 '18 19:09 rahmanusta

Try pasting the following into an .adoc file.

= 中文文章
example
:lang: zh

这是一篇示例的中文asciidoc文档。


. 第一条无序列表
. 第二条无序列表
. 第三条无序列表

* 子列表
* 第二个子列表

== 我是个二级标题

[quote,作者]
____
我要引用一句话。
____

TIP: 就只是放个tips试一下。

yimikite avatar Sep 11 '18 01:09 yimikite

Find conf/docbook-config/fo-pdf.xsl file in installation directory and edit font size attributes. You can search body.font.size first.

rahmanusta avatar Sep 11 '18 21:09 rahmanusta