Skip to content

Commit

Permalink
m
Browse files Browse the repository at this point in the history
  • Loading branch information
Willie169 committed Dec 29, 2024
1 parent a4de1d4 commit e4090ad
Show file tree
Hide file tree
Showing 4 changed files with 482 additions and 198 deletions.
167 changes: 167 additions & 0 deletions CJKFontSettingsGen.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,167 @@
#include<iostream>
#include<string>
#include <algorithm>
#include <cctype>
using namespace std;
class Latex {
public:
Latex() {}
const string cmain = "\\setCJKmainfont";
const string csans = "\\setCJKsansfont";
const string cmono = "\\setCJKmonofont";
const string nff = "\\newfontfamily\\customfont";
const string path = "Path=/usr/share/fonts/noto-cjk/,";
const string sansf = "NotoSans";
const string seriff = "NotoSerif";
const string monof = "NotoSansMonoCJK";
const string otf = ".otf";
const string cf = "\\ifnum\\value{CJKFonts}=";
const string cl ="\\ifnum\\value{CJKLanguage}=";
const string cn = "\\ifnum\\value{NotoCJKFamily}=";
const string el = "\\else";
const string cp = "}[";
const string end = "Ligatures=TeX]";
const string pre = "\\ifnum\\value{xeCJK}=1\n\\usepackage[CJKspace]{xeCJK}\n\\usepackage{zhnumber}\n\\ifnum\\value{ZhRenew}=1\n\\renewcommand{\\contentsname}{\\hfill\\text{目錄}\\hfill}\n\\else\\ifnum\\value{ZhRenew}=2\n\\renewcommand{\\contentsname}{\\hfill\\text{目录}\\hfill}\n\\fi\\fi\n\\ifnum\\value{CJKFonts}=0\\else\n";
string ulang[5]={"TC","SC","HK","JP","KR"};
string llang[5]={"tc","sc","hk","jp","kr"};
string fw[5]={"UprightFont","ItalicFont","BoldFont","BoldItalicFont","SmallCapsFont"};
string sansw[5]={"Regular","Medium","Bold","Black","DemiLight"};
string serifw[5]={"Regular","Medium","Bold","Black","Light"};
string monofwn[2]={"UprightFont","BoldFont"};
string monow[2]={"Regular","Bold"};
string sans(string lang){
string ret="{"+sansf+lang+cp+path;
for (int i=0; i<5; i++) ret+=fw[i]+"="+sansf+lang+"-"+sansw[i]+otf+",";
ret+=end;
return ret;
}
string serif(string lang){
string ret="{"+seriff+lang+cp+path;
for (int i=0; i<5; i++) ret+=fw[i]+"="+seriff+lang+"-"+serifw[i]+otf+",";
ret+=end;
return ret;
}
string mono(string lang){
string ret="{"+monof+lang+cp+path;
for (int i=0; i<2; i++) ret+=monofwn[i]+"="+monof+lang+"-"+monow[i]+otf+",";
ret+=end;
return ret;
}
string ssans(string lang){
string ret="{Sans"+lang+cp+path;
for (int i=0; i<5; i++) ret+=fw[i]+"="+sansf+lang+"-"+sansw[i]+otf+",";
ret+=end;
return ret;
}
string sserif(string lang){
string ret="{Serif"+lang+cp+path;
for (int i=0; i<5; i++) ret+=fw[i]+"="+seriff+lang+"-"+serifw[i]+otf+",";
ret+=end;
return ret;
}
string lsans(string lang){
string ret="{"+lang+cp+path;
for (int i=0; i<5; i++) ret+=fw[i]+"="+sansf+lang+"-"+sansw[i]+otf+",";
ret+=end;
return ret;
}
string lserif(string lang){
string ret="{"+lang+cp+path;
for (int i=0; i<5; i++) ret+=fw[i]+"="+seriff+lang+"-"+serifw[i]+otf+",";
ret+=end;
return ret;
}
string smono(string llang){
string ret="{Mono"+llang+cp+path;
string lang = llang;
transform(lang.begin(), lang.end(), lang.begin(), [](unsigned char c) { return tolower(c); });
for (int i=0; i<2; i++) ret+=monofwn[i]+"="+monof+lang+"-"+monow[i]+otf+",";
ret+=end;
return ret;
}
void yes() {
Latex latex=Latex();
cout << pre;
for (int i=0; i<5; i++) {
cout << cl+to_string(i+1)+"\n";
cout << cf+"1"+"\n";
cout << cmain << latex.sans(ulang[i]);
cout << csans << latex.serif(ulang[i]);
cout << cmono << latex.mono(llang[i]);
cout << "\n\\else";
cout << cf+"2"+"\n";
cout << cmain << latex.serif(ulang[i]);
cout << csans << latex.sans(ulang[i]);
cout << cmono << latex.mono(llang[i]);
cout << "\n\\else";
cout << cf+"3"+"\n";
cout << cmain << latex.sans(ulang[i]);
cout << cmono << latex.mono(llang[i]);
cout << "\n\\else";
cout << cf+"4"+"\n";
cout << cmain << latex.serif(ulang[i]);
cout << cmono << latex.mono(llang[i]);
cout << "\n\\else";
cout << cf+"5"+"\n";
cout << cmain << latex.sans(ulang[i]);
cout << csans << latex.serif(ulang[i]);
cout << "\n\\else";
cout << cf+"6"+"\n";
cout << cmain << latex.serif(ulang[i]);
cout << csans << latex.sans(ulang[i]);
cout << "\n\\else";
cout << cf+"7"+"\n";
cout << cmain << latex.sans(ulang[i]);
cout << "\n\\else";
cout << cf+"8"+"\n";
cout << cmain << latex.serif(ulang[i]);
cout << "\n\\fi\\fi\\fi\\fi\\fi\\fi\\fi\\fi";
if (i!=4) cout << "\\else\n";
}
cout << "\n\\fi\\fi\\fi\\fi\\fi\\fi\n";
cout << cn << "0\n";
cout << "\\else" << cn << "1\n";
for (int i=0; i<5; i++) {
cout << "\n" << nff << latex.ssans(ulang[i]);
cout << "\n" << nff << latex.lsans(ulang[i]);
cout << "\n" << nff << latex.sserif(ulang[i]);
cout << "\n" << nff << latex.smono(ulang[i]);
}
cout << "\\else" << cn << "2\n";
for (int i=0; i<5; i++) {
cout << "\n" << nff << latex.ssans(ulang[i]);
cout << "\n" << nff << latex.sserif(ulang[i]);
cout << "\n" << nff << latex.lserif(ulang[i]);
cout << "\n" << nff << latex.smono(ulang[i]);
}
cout << "\\else" << cn << "3\n";
for (int i=0; i<5; i++) {
cout << "\n" << nff << latex.ssans(ulang[i]);
cout << "\n" << nff << latex.sserif(ulang[i]);
cout << "\n" << nff << latex.smono(ulang[i]);
}
cout << "\\else" << cn << "4\n";
for (int i=0; i<5; i++) {
cout << "\n" << nff << latex.ssans(ulang[i]);
cout << "\n" << nff << latex.lsans(ulang[i]);
cout << "\n" << nff << latex.sserif(ulang[i]);
}
cout << "\\else" << cn << "5\n";
for (int i=0; i<5; i++) {
cout << "\n" << nff << latex.ssans(ulang[i]);
cout << "\n" << nff << latex.sserif(ulang[i]);
cout << "\n" << nff << latex.lserif(ulang[i]);
}
cout << "\\else" << cn << "6\n";
for (int i=0; i<5; i++) {
cout << "\n" << nff << latex.ssans(ulang[i]);
cout << "\n" << nff << latex.sserif(ulang[i]);
}
cout << "\n\\fi\\fi\\fi\\fi\\fi\\fi\\fi\\fi";
}
};
int main() {
Latex latex=Latex();
latex.yes();
return 0;
}
101 changes: 99 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,106 @@

## Introduction

This repository boasts a comprehensive and customizable LaTeX template, [`template.tex`](template.tex), which is designed for article and report documentclass, and for TC (Traditional Chinese Taiwan), SC (Simplified Chinese), HK (Traditional Chinese Hong Kong), JP (Japanese), KR (Korean), and Latin-script languages.
This repository boasts a comprehensive and customizable LaTeX template, [`template.tex`](template.tex), which is designed for article or report documentclass, TC (Traditional Chinese Taiwan), SC (Simplified Chinese), HK (Traditional Chinese Hong Kong), JP (Japanese), KR (Korean), and Latin-script languages, and with many commands and shorthands defined.

Instructions and customizable configurations of it is at the beginning of [`template.tex`](template.tex).
## Fonts

Fonts can be installed with:

```
mkdir -p /usr/share/fonts/opentype/stix
curl https://raw.githubusercontent.com/stipub/stixfonts/master/fonts/static_otf/STIXTwoMath-Regular.otf --output /usr/share/fonts/opentype/stix/STIXTwoMath-Regular.otf
mkdir /usr/share/fonts/noto-cjk
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-Thin.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-Thin.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-Light.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-DemiLight.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-DemiLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/TC/NotoSansTC-Black.otf --output /usr/share/fonts/noto-cjk/NotoSansTC-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-Thin.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-Thin.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-Light.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-DemiLight.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-DemiLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/SC/NotoSansSC-Black.otf --output /usr/share/fonts/noto-cjk/NotoSansSC-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-Thin.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-Thin.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-Light.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-DemiLight.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-DemiLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/HK/NotoSansHK-Black.otf --output /usr/share/fonts/noto-cjk/NotoSansHK-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-Thin.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-Thin.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-Light.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-DemiLight.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-DemiLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/JP/NotoSansJP-Black.otf --output /usr/share/fonts/noto-cjk/NotoSansJP-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-Thin.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-Thin.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-Light.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-DemiLight.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-DemiLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/SubsetOTF/KR/NotoSansKR-Black.otf --output /usr/share/fonts/noto-cjk/NotoSansKR-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-ExtraLight.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-ExtraLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-Light.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-SemiBold.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-SemiBold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/TC/NotoSerifTC-Black.otf --output /usr/share/fonts/noto-cjk/NotoSerifTC-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-ExtraLight.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-ExtraLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-Light.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-SemiBold.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-SemiBold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/SC/NotoSerifSC-Black.otf --output /usr/share/fonts/noto-cjk/NotoSerifSC-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-ExtraLight.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-ExtraLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-Light.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-SemiBold.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-SemiBold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/HK/NotoSerifHK-Black.otf --output /usr/share/fonts/noto-cjk/NotoSerifHK-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-ExtraLight.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-ExtraLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-Light.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-SemiBold.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-SemiBold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/JP/NotoSerifJP-Black.otf --output /usr/share/fonts/noto-cjk/NotoSerifJP-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-ExtraLight.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-ExtraLight.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-Medium.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-Medium.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-Light.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-Light.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-SemiBold.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-SemiBold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Serif/SubsetOTF/KR/NotoSerifKR-Black.otf --output /usr/share/fonts/noto-cjk/NotoSerifKR-Black.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKtc-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKtc-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKtc-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKtc-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKsc-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKsc-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKsc-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKsc-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKhk-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKhk-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKhk-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKhk-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKjp-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKjp-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKjp-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKjp-Bold.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKkr-Regular.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKkr-Regular.otf
curl https://raw.githubusercontent.com/notofonts/noto-cjk/main/Sans/Mono/NotoSansMonoCJKkr-Bold.otf --output /usr/share/fonts/noto-cjk/NotoSansMonoCJKkr-Bold.otf
fc-cache -fv
```

## Usage

Replace `\input{template.tex}` line in [document.tex](document.tex) with the actual path you downloaded the [template.tex](template.tex).

## CJKFontSettingsGen.cpp

[`CJKFontSettingsGen.cpp`](CJKFontSettingsGen.cpp) is a cpp program to generate the CJK font settings etc. LaTeX code, which is the 40 to 243 line of [`template.tex`](template.tex).

## License

Expand Down
Loading

0 comments on commit e4090ad

Please sign in to comment.