This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| %!TEX program = xelatex | |
| \documentclass{article} | |
| \usepackage{polyglossia} | |
| \setmainlanguage{english} | |
| \setotherlanguage{korean} | |
| \newfontfamily\koreanfont{NanumMyeongjo}[Ligatures=TeX] | |
| \usepackage{ucharclasses} | |
| \setTransitionsForCJK{\begingroup\koreanfont | |
| \XeTeXlinebreaklocale"ko" | |
| \XeTeXlinebreakpenalty=50 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| % see http://www.ktug.org/xe/index.php?document_srl=214192 | |
| \def\dofirst#1{\dodofirst#1 \stopdofirst{} } | |
| \def\dodofirst#1 {% | |
| \ifx\stopdofirst#1% | |
| \unskip | |
| \else | |
| \in@{,#1,}{,a,am,an,of,for,in,on,the,to,with,}% | |
| \ifin@ | |
| \else | |
| \expandafter\DoFirst |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| readcsv = readcsv or {} | |
| local readcsv = readcsv | |
| local function readcsvlines (s, sep) | |
| sep = sep or ',' | |
| s = s .. "\n" | |
| s = s:gsub("[\r\n]+", "\n") -- unix newline | |
| local curr, t = 1, {{}} | |
| while true do | |
| local tt, i, a, c = t[#t], curr |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- | |
| -- This is file `luamplib.lua', | |
| -- generated with the docstrip utility. | |
| -- | |
| -- The original source files were: | |
| -- | |
| -- luamplib.dtx (with options: `lua') | |
| -- | |
| -- See source file 'luamplib.dtx' for licencing and contact information. | |
| -- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| \documentclass[a4paper]{article} | |
| \usepackage{fontspec, luacode, xcolor} | |
| %\setmainfont{HCR Batang LVT}[Script=Hangul, Language=Korean] | |
| \setmainfont{Linux Libertine O} | |
| %\setmainfont{TeX Gyre Pagella} | |
| %\setmainfont{Source Han Sans K}[Script=Hangul, Language=Korean] | |
| %\setmainfont{NanumMyeongjoOTF YetHangul}[Script=Hangul, Language=Korean] | |
| %\setmainfont{NanumBarunGothicOTF YetHangul}[Script=Hangul, Language=Korean] | |
| \pagestyle{myheadings} \markright{\footnotesize\fontname\font} | |
| \def\tickblue{{\color{blue}\vrule width1pt height.05pt depth.05pt}} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| \input luamplib.sty | |
| \def\mpcalc#1#2#3{% #1 control sequence | |
| % #2 math formular | |
| % #3 precision ( <= 1000 ) | |
| \begingroup | |
| \setbox0\hbox{% | |
| \mplibnumbersystem{decimal}% | |
| \mplibcode | |
| numberprecision := #3; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| \begingroup\expandafter\expandafter\expandafter\endgroup | |
| \expandafter\ifx\csname selectfont\endcsname\relax | |
| \edef\catcodeofatchar{\catcode`@=\the\catcode`@} | |
| \catcode`@=11 | |
| \newdimen\@tempdima \newdimen\@tempdimb | |
| \newcount\@tempcnta \newcount\@tempcntb | |
| \else | |
| \ProvidesPackage{fontglyphs}[2015/06/15 v0.1 Draw box of each and every glyphs in a truetype/opentype font] | |
| \fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env perl | |
| my @LC = map {$_ eq "-" ? "" : $_} qw( | |
| g kk n d tt r m b pp s ss - j jj ch k t p h | |
| ); | |
| my @MV = qw( | |
| a ae ya yae eo e yeo ye o wa wae oe yo u wo we wi yu eu ui i | |
| ); | |
| my @TC = map {$_ eq "-" ? "" : $_} qw( | |
| - G kk ks n nj nh D R lG lm lB ls lt lp lh m B ps s ss ng j ch k t p h |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| luatexbase.provides_module( | |
| { | |
| name = 'drawcharbox', | |
| date = '2011/05/20', | |
| version = 0.2, | |
| description = 'draw char box for each char', | |
| author = 'Dohyun Kim', | |
| license = 'Public Domain', | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| luatexbase.provides_module({ | |
| name = 'colorVerb', | |
| date = '2011/01/20', | |
| version = 0.1, | |
| description = 'Colorize Commands/Braces/Brackets in Verbatim', | |
| author = 'Dohyun Kim', | |
| license = 'Public Domain', | |
| }) | |
| colorVerb = colorVerb or {} |