Skip to content

Instantly share code, notes, and snippets.

@exkuretrol
Created January 26, 2023 17:35
Show Gist options
  • Save exkuretrol/e178fefa4217f331f6c434d1713f8d50 to your computer and use it in GitHub Desktop.
Save exkuretrol/e178fefa4217f331f6c434d1713f8d50 to your computer and use it in GitHub Desktop.
適用於 windows ctex 的繁體中文字體庫。目前只有 XeLaTeX 可以編譯。
\ProvidesExplFile{ctex-fontset-windows-tc.def}{\ExplFileDate}{0.0.1}{\ExplFileDescription}
\ctex_fontset_case:nnn
{ }
{ }
{
\setCJKmainfont { MingLiU } [ BoldFont = Microsoft~JhengHei , ItalicFont = DFKai-SB ]
\setCJKsansfont { Microsoft~JhengHei } [ BoldFont = *~Bold ]
\setCJKmonofont { MingLiU~Regular }
\setCJKfamilyfont { ming } { MingLiU~Regular }
\setCJKfamilyfont { zhhei } { Microsoft~JhengHei }
\setCJKfamilyfont { zhkai } { DFKai-SB }
}
\NewDocumentCommand \ming { } { \CJKfamily { ming } }
\NewDocumentCommand \hei { } { \CJKfamily { zhhei } }
\NewDocumentCommand \kai { } { \CJKfamily { zhkai } }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment