summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author郭俊余 <hagbgreen@yahoo.com>2018-06-11 22:32:32 +0800
committerIru Cai (vimacs) <mytbk920423@gmail.com>2018-06-11 14:32:32 +0000
commit96aba8642f7d9714816519a8e36e37d74b126d59 (patch)
tree2a68d1616caf81224a95a7316eae4e021a492f0d
parentb95c221d0d0af79350db1d1454f6422bd42aaafd (diff)
downloadfsfs-zh-96aba8642f7d9714816519a8e36e37d74b126d59.tar.xz
附录B的排版 (#190)
* 简化了用于字符串替换的字符串((used-by-pdf)改为(pdf)) * 附录B所有语言改为字符串形式
-rwxr-xr-xMakefile20
-rw-r--r--docs/appendix-a.md2
-rw-r--r--docs/appendix-b.md48
-rw-r--r--docs/appendix-c.md2
-rw-r--r--docs/categories.md2
-rwxr-xr-xinstall.latex.ubuntu.sh3
-rw-r--r--pdf/template.tex24
7 files changed, 63 insertions, 38 deletions
diff --git a/Makefile b/Makefile
index e2d1ae0..4f1b4e2 100755
--- a/Makefile
+++ b/Makefile
@@ -5,7 +5,7 @@ METADATA = ebook/metadata.xml
TOC = --toc --toc-depth=2 --epub-chapter-level=2
COVER_IMAGE = docs/cover.png
LATEX_CLASS = book
-PANDOC_TEX = pandoc --from="markdown_mmd+link_attributes+backtick_code_blocks+fenced_code_attributes+raw_tex" $(TOC) --latex-engine=xelatex -V documentclass=book
+PANDOC_TEX = pandoc --from="markdown_mmd+link_attributes+backtick_code_blocks+fenced_code_attributes+raw_tex+latex_macros" $(TOC) --latex-engine=xelatex -V documentclass=book
TEMPLATE=./pdf
PREFACES = docs/foreword-trans.md \
docs/foreword-v3.md \
@@ -66,7 +66,7 @@ APPENDIXS = docs/appendix-a.md \
docs/appendix-c.md
APPENDIXS_PDF = $(shell echo $(APPENDIXS) | sed 's/.md/_pdf.md/g')
PDF_IMG = category.pdf code-zh.pdf song-book-jutta-scrunch-crop-zh.pdf
-SVG_IMG = docs/fs-translations/ar-libre.svg docs/fs-translations/be-libre.svg docs/fs-translations/bg-gratis.svg docs/fs-translations/bg-libre.svg docs/fs-translations/bn-libre.svg docs/fs-translations/el-gratis.svg docs/fs-translations/el-libre.svg docs/fs-translations/fa-gratis.svg docs/fs-translations/fa-libre.svg docs/fs-translations/he-gratis.svg docs/fs-translations/he-libre.svg docs/fs-translations/hi-gratis.svg docs/fs-translations/hi-libre.svg docs/fs-translations/hy-libre.svg docs/fs-translations/ja-kanji-gratis.svg docs/fs-translations/ja-kanji-libre.svg docs/fs-translations/ja-libre.svg docs/fs-translations/ka-gratis.svg docs/fs-translations/ka-libre.svg docs/fs-translations/ko-libre.svg docs/fs-translations/mk-gratis.svg docs/fs-translations/mk-libre.svg docs/fs-translations/ml-gratis.svg docs/fs-translations/ml-libre.svg docs/fs-translations/ru-gratis.svg docs/fs-translations/ru-libre.svg docs/fs-translations/si-libre.svg docs/fs-translations/sr-gratis.svg docs/fs-translations/sr-libre.svg docs/fs-translations/ta-gratis.svg docs/fs-translations/ta-libre.svg docs/fs-translations/th-libre.svg docs/fs-translations/uk-libre.svg docs/fs-translations/ur-gratis.svg docs/fs-translations/ur-libre.svg docs/fs-translations/vi-libre.svg docs/fs-translations/zh-cn-free.svg docs/fs-translations/zh-cn-gratis.svg docs/fs-translations/zh-cn-libre.svg docs/fs-translations/zh-tw-free.svg docs/fs-translations/zh-tw-gratis.svg docs/fs-translations/zh-tw-libre.svg
+#SVG_IMG = docs/fs-translations/ar-libre.svg docs/fs-translations/be-libre.svg docs/fs-translations/bg-gratis.svg docs/fs-translations/bg-libre.svg docs/fs-translations/bn-libre.svg docs/fs-translations/el-gratis.svg docs/fs-translations/el-libre.svg docs/fs-translations/fa-gratis.svg docs/fs-translations/fa-libre.svg docs/fs-translations/he-gratis.svg docs/fs-translations/he-libre.svg docs/fs-translations/hi-gratis.svg docs/fs-translations/hi-libre.svg docs/fs-translations/hy-libre.svg docs/fs-translations/ja-kanji-gratis.svg docs/fs-translations/ja-kanji-libre.svg docs/fs-translations/ja-libre.svg docs/fs-translations/ka-gratis.svg docs/fs-translations/ka-libre.svg docs/fs-translations/ko-libre.svg docs/fs-translations/mk-gratis.svg docs/fs-translations/mk-libre.svg docs/fs-translations/ml-gratis.svg docs/fs-translations/ml-libre.svg docs/fs-translations/ru-gratis.svg docs/fs-translations/ru-libre.svg docs/fs-translations/si-libre.svg docs/fs-translations/sr-gratis.svg docs/fs-translations/sr-libre.svg docs/fs-translations/ta-gratis.svg docs/fs-translations/ta-libre.svg docs/fs-translations/th-libre.svg docs/fs-translations/uk-libre.svg docs/fs-translations/ur-gratis.svg docs/fs-translations/ur-libre.svg docs/fs-translations/vi-libre.svg docs/fs-translations/zh-cn-free.svg docs/fs-translations/zh-cn-gratis.svg docs/fs-translations/zh-cn-libre.svg docs/fs-translations/zh-tw-free.svg docs/fs-translations/zh-tw-gratis.svg docs/fs-translations/zh-tw-libre.svg
all: book html
@@ -79,7 +79,7 @@ clean:
-rm $(PDF_IMG)
-rm -r site
-rm $(BOOKNAME).*
- -rm $(SVG_IMG)
+ #-rm $(SVG_IMG)
-rm $(PREFACES_PDF) $(CHAPTERS_PDF) $(APPENDIXS_PDF)
epub: $(BOOKNAME).epub
@@ -90,17 +90,17 @@ pdf: $(BOOKNAME).pdf
odf: $(BOOKNAME).odt
-$(SVG_IMG): docs/fs-translations/%.svg : docs/fs-translations/%.pdf
- pdf2svg $< $@
+#$(SVG_IMG): docs/fs-translations/%.svg : docs/fs-translations/%.pdf
+ #pdf2svg $< $@
-$(BOOKNAME).epub: $(TITLE) $(PREFACES) $(CHAPTERS) $(APPENDIXS) $(SVG_IMG)
+$(BOOKNAME).epub: $(TITLE) $(PREFACES) $(CHAPTERS) $(APPENDIXS) #$(SVG_IMG)
ln -s docs/fs-translations/ . #消除Warning
# cp docs/*.png .
pandoc $(TOC) -S -t epub3 --epub-metadata=$(METADATA) --epub-cover-image=$(COVER_IMAGE) -o $@ $^ #$(shell echo $(SVG_IMG) | sed 's/docs\///g' )
rm fs-translations
# rm *.png
-$(BOOKNAME).html: $(PREFACES) $(CHAPTERS) $(APPENDIXS) $(SVG_IMG)
+$(BOOKNAME).html: $(PREFACES) $(CHAPTERS) $(APPENDIXS) #$(SVG_IMG)
ln -s docs/fs-translations/ . #消除Warning
pandoc $(TOC) --standalone --to=html5 -o $@ $^ #$(shell echo $(SVG_IMG) | sed 's/docs\///g' )
mkdocs build --clean
@@ -111,8 +111,8 @@ $(BOOKNAME).html: $(PREFACES) $(CHAPTERS) $(APPENDIXS) $(SVG_IMG)
$(PREFACES_PDF) $(CHAPTERS_PDF) $(APPENDIXS_PDF): docs/%_pdf.md : docs/%.md
cp $< $@
-# 编译时把<!--(used-by-pdf)和(used-by-pdf)-->去掉,把<!--(pdf-newline)--><br>替换成\newline{},将svg替换成pdf
- sed -i 's/<!--(used-by-pdf)//g;s/(used-by-pdf)-->//g;s/.svg)/.pdf)/g;s/<!--(pdf-newline)--><br>/\\newline{}/g' $@
+# 编译时把<!--(pdf)和(pdf)-->去掉,把<!--(pdf-newline)--><br>替换成\newline{},将svg替换成pdf
+ sed -i 's/<!--(pdf)//g;s/(pdf)-->//g;s/.svg)/.pdf)/g;s/<!--(pdf-newline)--><br>/\\newline{}/g' $@
$(BOOKNAME).pdf: $(TITLE) $(PREFACES_PDF) $(CHAPTERS_PDF) $(APPENDIXS_PDF) $(PDF_IMG)
@@ -140,7 +140,7 @@ define pdfgen
@echo "Done!"
endef
-$(BOOKNAME).odt: $(PREFACES) $(CHAPTERS) $(APPENDIXS) $(SVG_IMG)
+$(BOOKNAME).odt: $(PREFACES) $(CHAPTERS) $(APPENDIXS) #$(SVG_IMG)
ln -s docs/fs-translations/ .
pandoc -t odt -o $@ $^ #$(shell echo $(SVG_IMG) | sed 's/docs\///g' )
rm fs-translations
diff --git a/docs/appendix-a.md b/docs/appendix-a.md
index 35b53ea..0cf273c 100644
--- a/docs/appendix-a.md
+++ b/docs/appendix-a.md
@@ -10,7 +10,7 @@
程序最初的形态通常是*源代码*。这一系列高级指令由*编程语言*(比如 C 或者 Java)编写而成。之后会被一个名为*编译器*的工具编译为一种更底层的语言——*汇编语言*。另一种被称为*汇编器*的工具会将汇编代码分解为最终的*机器语言*——计算机可以*原生*理解的最底层代码。
-![计算机程序是如何从源代码生成二进制可执行文件的](code-zh.svg)<!--(used-by-pdf){ width=100% }(used-by-pdf)-->
+![计算机程序是如何从源代码生成二进制可执行文件的](code-zh.svg)<!--(pdf){ width=100% }(pdf)-->
例如,“Hello World”这个程序,通常是人们学习 C 语言时的第一个程序,编译和执行后会在屏幕上打印出“Hello World”[^ap-1]。
diff --git a/docs/appendix-b.md b/docs/appendix-b.md
index c43c139..9b111a3 100644
--- a/docs/appendix-b.md
+++ b/docs/appendix-b.md
@@ -9,63 +9,63 @@
|----------|-----------------------------------|---------------------------------------------------|------------------------------------------|
| en | 英语 | free software | gratis software |
| af | 南非荷兰语 | vrye sagteware | gratis sagteware |
-| ar | 阿拉伯语 | ![fs-translations/ar-libre](fs-translations/ar-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(barmajiyat ḥorrah)* |
-| be | 白俄罗斯语 | ![fs-translations/be-libre](fs-translations/be-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(svabodnae pragramnae zabes’pjachen’ne)* |
-| bg | 保加利亚语 | ![fs-translations/bg-libre](fs-translations/bg-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(svoboden softuer)* | ![fs-translations/bg-gratis](fs-translations/bg-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(bezplaten softuer)* |
-| bn | 孟加拉语 |![fs-translations/bn-libre](fs-translations/bn-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(swadhin software)* |
+| ar | 阿拉伯语 | <!--(pdf)\la{\ar حرة برمجيات \iffalse (pdf)-->برمجيات حرة <!--(pdf)\fi}(pdf)--><!--(pdf-newline)--><br> *(barmajiyat ḥorrah)* |
+| be | 白俄罗斯语 | свабоднае праграмнае забесьпячэньне <!--(pdf-newline)--><br> *(svabodnae pragramnae zabes’pjachen’ne)* |
+| bg | 保加利亚语 | <!--(pdf)\la{\bg (pdf)--> свободен софтуер <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(svoboden softuer)* | <!--(pdf)\la{\bg (pdf)--> безплатен софтуер <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(bezplaten softuer)* |
+| bn | 孟加拉语 | <!--(pdf)\la{\bn (pdf)--> স্বাধীন সফটওয়্যার <!--(pdf)}(pdf)--><!--(pdf-newline)--><br> *(swadhin software)* |
| ca | 加泰罗尼亚语 | programari lliure | programari gratuït |
| cs | 捷克语 | svobodný software | bezplatný software |
| cy | 威尔士语 | meddalwedd | rydd |
| da | 丹麦语 | fri software *或* frit programmel | gratis software |
| de | 德语 | freie Software | Gratis-Software *或* kostenlose Software |
-| el | 希腊语 | ![fs-translations/el-libre](fs-translations/el-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(elefthero logismiko)* | ![fs-translations/el-gratis](fs-translations/el-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(dorean logismiko)*|
+| el | 希腊语 | ελεύθερο λογισμικό <!--(pdf-newline)--><br> *(elefthero logismiko)* | δωρεάν λογισμικό <!--(pdf-newline)--><br> *(dorean logismiko)*|
| eo | 世界语 | libera programaro *或* programo |
| eu | 巴斯克语 | software librea | doako softwarea |
| es | 西班牙语 | software libre | software gratuito |
| et | 爱沙尼亚语 | vaba tarkvara | tasuta tarkvara |
-| fa | 波斯语 | ![fs-translations/fa-libre](fs-translations/fa-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(narmafzar azad)* | ![fs-translations/fa-gratis](fs-translations/fa-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(narmafzar raygan)* |
+| fa | 波斯语 | <!--(pdf)\la{\fa آزاد افزار نرم \iffalse (pdf)--> نرم افزار آزاد<!--(pdf) \fi }(pdf)--> <!--(pdf-newline)--><br> *(narmafzar azad)* | <!--(pdf)\la{\fa رایگان افزار نرم \iffalse (pdf)-->نرم افزار رایگان <!--(pdf) \fi }(pdf)--> <!--(pdf-newline)--><br> *(narmafzar raygan)* |
| fi | 芬兰语 | vapaa ohjelmisto | ilmainen ohjelmisto |
| fr | 法语 | logiciel libre | logiciel gratuit |
| ga | 爱尔兰语 | saorbhogearraí | bogearraí saora in aisce |
-| he | 希伯来语 | ![fs-translations/he-libre](fs-translations/he-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(tochna chofshit)* | ![fs-translations/he-gratis](fs-translations/he-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(tochna chinamit)* |
-| hi | 印地语 | ![fs-translations/hi-libre](fs-translations/hi-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(mukt software)*|![fs-translations/hi-gratis](fs-translations/hi-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(muft software)*|
+| he | 希伯来语 | <!--(pdf)\la{\he (pdf)--> תוכנה חופשית <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(tochna chofshit)* | <!--(pdf)\la{\he (pdf)--> תוכנה חינמית <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(tochna chinamit)* |
+| hi | 印地语 | <!--(pdf)\la{\hi (pdf)-->मुक्त सॉफ्टवेयर<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(mukt software)*|<!--(pdf)\la{\hi (pdf)-->मुफ़्त सॉफ्टवेयर <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(muft software)*|
| hr | 克罗地亚语 | slobodan softver | besplatan softver|
| hu | 匈牙利语 | szabad szoftver | ingyenes szoftver *或* ingyen szoftver |
-| hy | 亚美尼亚语 | ![fs-translations/hy-libre](fs-translations/hy-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(azat tsragir/tsragrer)* |
+| hy | 亚美尼亚语 | <!--(pdf)\la{\hy(pdf)--> ազատ ծրագիր<!--(pdf)}(pdf)-->/<!--(pdf)\la{\hy (pdf)-->ծրագրեր <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(azat tsragir/tsragrer)* |
| ia | 国际语 | libere programmage *或* libere programmario |
| id | 印度尼西亚语 | perangkat lunak bebas|
| io | 伊多 | libera programaro |
| is | 冰岛语 | frjáls hugbúnaður |
| it | 意大利语 | software libero | software gratuito |
-| ja | 日语 | ![fs-translations/ja-kanji-libre](fs-translations/ja-kanji-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(jiyū-sofutouea)* | ![fs-translations/ja-kanji-gratis](fs-translations/ja-kanji-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(muryō-sofutouea)*|
-| ka | 格鲁吉亚语 |![fs-translations/ka-libre](fs-translations/ka-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(tavisupali programebi)* | ![fs-translations/ka-gratis](fs-translations/ka-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(upaso programebi)* |
-| ko | 韩语 | ![fs-translations/ko-libre](fs-translations/ko-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(ja-yu software)* |
+| ja | 日语 | <!--(pdf)\la{\ja (pdf)-->自由ソフトウェア <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(jiyū-sofutouea)* | <!--(pdf)\la{\ja (pdf)--> 無料ソフトウェア<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(muryō-sofutouea)*|
+| ka | 格鲁吉亚语 |<!--(pdf)\la{\ka(pdf)--> თავისუფალი პროგრამები <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(tavisupali programebi)* | <!--(pdf)\la{\ka (pdf)--> უფასო პროგრამები<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(upaso programebi)* |
+| ko | 韩语 | <!--(pdf)\la{\ko (pdf)--> 자유 소프트웨어<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(ja-yu software)* |
| lt | 立陶宛语 | laisva programinė įranga | nemokama programinė įranga |
| lv | 拉脱维亚语 | brīva programmatūra | bezmaksas programmatūra |
-| mk | 马其顿语 | ![fs-translations/mk-libre](fs-translations/mk-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(sloboden softver)* |![fs-translations/mk-gratis](fs-translations/mk-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(besplaten softver)*|
-| ml | 马拉雅拉姆语 | ![fs-translations/ml-libre](fs-translations/ml-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(svatantrasophṯṯveyar)* | ![fs-translations/ml-gratis](fs-translations/ml-gratis.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(soujanyasophṯṯveyar)* |
+| mk | 马其顿语 | слободен софтвер <!--(pdf-newline)--><br> *(sloboden softver)* |бесплатен софтвер <!--(pdf-newline)--><br> *(besplaten softver)*|
+| ml | 马拉雅拉姆语 | <!--(pdf)\la{\ml \small (pdf)--> സ്വതന്ത്രസോഫ്റ്റ്‌വെയര്‍<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(svatantrasophṯṯveyar)* | <!--(pdf)\la{\ml \small (pdf)-->സൗജന്യസോഫ്റ്റ്‌വെയര്‍<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(soujanyasophṯṯveyar)* |
| ms | 马来语 | perisian bebas |
| nl | 荷兰语 | vrije software | gratis software |
| no | 挪威语 | fri programvare |
| pl | 波兰语 | wolne oprogramowanie | darmowe oprogramowanie|
| pt | 葡萄牙语 | software livre |
| ro | 罗马尼亚语 | programe libere | programe gratuite |
-| ru | 俄语 | ![fs-translations/ru-libre](fs-translations/ru-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(svobodnie programmi)* | ![fs-translations/ru-gratis](fs-translations/ru-gratis.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(besplatnie programmi)* |
+| ru | 俄语 | свободные программы <!--(pdf-newline)--><br> *(svobodnie programmi)* | бесплатные программы<!--(pdf-newline)--><br> *(besplatnie programmi)* |
| sc | 撒丁语 | software liberu |
-| si | 僧伽罗语 |![fs-translations/si-libre](fs-translations/si-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(nidahas mṛdukāṅga)* |
+| si | 僧伽罗语 | <!--(pdf)\la{\si (pdf)--> නිදහස් මෘදුකාංග<!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(nidahas mṛdukāṅga)* |
| sk | 斯洛伐克语 | slobodný softvér |
| sl | 斯洛文尼亚语 | prosto programje |
| sq | 阿尔巴尼亚语 | software i lirë | software falas |
-| sr | 塞尔维亚 | ![fs-translations/sr-libre](fs-translations/sr-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> *或* slobodni softver |![fs-translations/sr-gratis](fs-translations/sr-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> *或* besplatni softver |
+| sr | 塞尔维亚 | слободни софтвер *或* slobodni softver | бесплатни софтвер *或* besplatni softver |
| sv | 瑞典语 | fri programvara *或* fri mjukvara |
| sw | 斯瓦希里语 | software huru *或* programu huru za kompyuta |
-| ta | 泰米尔文 | ![fs-translations/ta-libre](fs-translations/ta-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(kaṭṭaṟṟa meṉpoñaḷ)* | ![fs-translations/ta-gratis](fs-translations/ta-gratis.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(illavasa menporul)* |
-| th | 泰语 | ![fs-translations/th-libre](fs-translations/th-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(sofotwerseri)* |
+| ta | 泰米尔文 | <!--(pdf)\la{\ta (pdf)--> கட்டற்ற மென்பொருள் <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(kaṭṭaṟṟa meṉpoñaḷ)* | <!--(pdf)\la{\ta (pdf)--> இலவச மென்பொருள் <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(illavasa menporul)* |
+| th | 泰语 | <!--(pdf)\la{\th (pdf)--> ซอฟต์แวร์เสรี <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(sofotwerseri)* |
| tl | 他加禄语(菲律宾)| malayang software |
| tr | 土耳其语 | özgür yazilim |
-| uk | 乌克兰语 | ![fs-translations/uk-libre](fs-translations/uk-libre.svg)<!--(used-by-pdf){ width=120px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(vil’ne prohramne zabezpechennja)*|
-| ur | 乌尔都语 | ![fs-translations/ur-libre](fs-translations/ur-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(azad software)* | ![fs-translations/ur-gratis](fs-translations/ur-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(muft software)* |
-| vi | 越南语 | ![fs-translations/vi-libre](fs-translations/vi-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> |
-| zh-cn | 中文(简体) |![fs-translations/zh-cn-libre](fs-translations/zh-cn-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(zi-you ruan-jian)*|![fs-translations/zh-cn-gratis](fs-translations/zh-cn-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(mian-fei ruan-jian)* |
-| zh-tw | 中文(繁体) |![fs-translations/zh-tw-libre](fs-translations/zh-tw-libre.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(zih-yo)* | ![fs-translations/zh-tw-gratis](fs-translations/zh-tw-gratis.svg)<!--(used-by-pdf){ width=100px }(used-by-pdf)--> <!--(pdf-newline)--><br> *(mien-fei)*|
+| uk | 乌克兰语 | вільне програмне забезпечення <!--(pdf-newline)--><br> *(vil’ne prohramne zabezpechennja)*|
+| ur | 乌尔都语 | <!--(pdf)\la{\ur ویئر سافٹ آزاد \iffalse (pdf)--> آزاد سافٹ ویئر <!--(pdf)\fi}(pdf)--> <!--(pdf-newline)--><br> *(azad software)* | <!--(pdf)\la{\ur ویئر سافٹ مفت\iffalse (pdf)--> مفت سافٹ ویئر <!--(pdf) \fi}(pdf)--> <!--(pdf-newline)--><br> *(muft software)* |
+| vi | 越南语 | phần mềm tự do |
+| zh-cn | 中文(简体) | 自由软件 <!--(pdf-newline)--><br> *(zi-you ruan-jian)*| 免费软件 <!--(pdf-newline)--><br> *(mian-fei ruan-jian)* |
+| zh-tw | 中文(繁体) |<!--(pdf)\la{\zhtw (pdf)--> 自由軟體 <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(zih-yo)* | <!--(pdf)\la{\zhtw (pdf)--> 免費軟體 <!--(pdf)}(pdf)--> <!--(pdf-newline)--><br> *(mien-fei)*|
| zu | 祖鲁语 | isoftware ekhululekile |
diff --git a/docs/appendix-c.md b/docs/appendix-c.md
index 9876fb4..91d2d64 100644
--- a/docs/appendix-c.md
+++ b/docs/appendix-c.md
@@ -8,7 +8,7 @@
*译者注:读者可下载 Musescore 格式的乐谱文件[^apc-1],通过自由的乐谱软件 Musescore[^apc-2] 聆听。*
-![自由软件之歌乐谱](song-book-jutta-scrunch-crop-zh.svg)<!--(used-by-pdf){ width=100% }(used-by-pdf)-->
+![自由软件之歌乐谱](song-book-jutta-scrunch-crop-zh.svg)<!--(pdf){ width=100% }(pdf)-->
[^apc-1]: 乐谱文件下载:<https://github.com/beijinglug/fsfs-zh/blob/master/docs/song-book-jutta-scrunch-crop-zh.mscx>
diff --git a/docs/categories.md b/docs/categories.md
index 1e49a61..14f576c 100644
--- a/docs/categories.md
+++ b/docs/categories.md
@@ -4,7 +4,7 @@
> 参见《应避免使用(或慎用)的词语,由于它们是不公正的或者引起混淆的》一文。
-![自由与非自由软件的分类](category.svg)<!--(used-by-pdf){ width=90% }(used-by-pdf)-->
+![自由与非自由软件的分类](category.svg)<!--(pdf){ width=90% }(pdf)-->
> 本图最初由 Chao-Kuei 创作并且经过其他人的更新,解释了不同类别的软件之间的区别。现有它的矢量图版,位于<http://gnu.org/philosophy/category.svg>以及 XFig 格式版本,位于<http://gnu.org/philosophy/category.fig>。本图采用 GNU 通用公共许可证(GNU GPL)2.0 或更高版本、GNU 自由文档许可证(GNU FDL)1.2 或更高版本、或者创作共用-署名-相同方式共享(CC BY-SA)许可证 2.0 或更高版本。
diff --git a/install.latex.ubuntu.sh b/install.latex.ubuntu.sh
index 707364c..cc37c6a 100755
--- a/install.latex.ubuntu.sh
+++ b/install.latex.ubuntu.sh
@@ -1,5 +1,6 @@
sudo apt-get -y install texlive-xetex texlive-latex-recommended \
texlive-latex-extra texlive-lang-cjk texlive-fonts-recommended \
latex-cjk-chinese fonts-liberation latex-cjk-chinese fonts-noto-cjk \
- librsvg2-bin pdf2svg
+ librsvg2-bin pdf2svg fonts-noto
+sudo apt-get -y install fonts-noto-hinted
sudo fc-cache
diff --git a/pdf/template.tex b/pdf/template.tex
index e2b0a95..a5e1b2a 100644
--- a/pdf/template.tex
+++ b/pdf/template.tex
@@ -67,6 +67,8 @@ frame=tb,
framexleftmargin=20pt
}
+
+
\titleformat{\section}
{\color{colorsection}\normalfont\Large\bfseries}
{\color{colorsection}\thesection}{1em}{}
@@ -117,7 +119,29 @@ framexleftmargin=20pt
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% 使用 DejaVu Sans 显示 ⚠ ☢ ☠ ✔ 这四个 dingbats 字符
% http://tex.stackexchange.com/questions/23049/font-substitution-with-xelatex
+
+\newcommand\la[1]{{#1}}
\newfontfamily{\DingbatSubstFont}{DejaVu Sans}
+\newfontfamily{\ar}[Script=Arabic]{Noto Naskh Arabic}
+%\newfontfamily{\ar}{DejaVu Sans}
+\newfontfamily{\bg}{Noto Sans CJK SC}
+\newfontfamily{\bn}{Noto Sans Bengali}
+%\newfontfamily{\fa}{Noto Kufi Arabic}
+\newfontfamily{\fa}{DejaVu Sans}
+\newfontfamily{\he}{Noto Sans Hebrew}
+\newfontfamily{\hi}{Noto Sans Devanagari}
+\newfontfamily{\hy}{Noto Sans Armenian}
+\newCJKfontfamily{\ja}{Noto Sans CJK JP}
+\newfontfamily{\ka}{Noto Sans Georgian}
+\newCJKfontfamily{\ko}{Noto Sans CJK KR}
+%\newcommand\ko[0]{}
+\newfontfamily{\ml}{Noto Sans Malayalam}
+\newfontfamily{\si}{Noto Sans Sinhala}
+\newfontfamily{\ta}{Noto Sans Tamil}
+\newfontfamily{\th}{Noto Sans Thai}
+\newfontfamily{\ur}[Script=Arabic,Language=Urdu]{Noto Nastaliq Urdu}
+\newCJKfontfamily{\zhtw}{Noto Sans CJK TC}
+
\XeTeXinterchartokenstate=1
\newXeTeXintercharclass\DingbatSubst
\XeTeXcharclass"26A0=\DingbatSubst % ⚠