summaryrefslogtreecommitdiff
path: root/tex/context/base/sort-lan.lua
diff options
context:
space:
mode:
authorMarius <mariausol@gmail.com>2011-02-11 13:40:18 +0200
committerMarius <mariausol@gmail.com>2011-02-11 13:40:18 +0200
commitab6d8e11ebd76ab61d2b451d1c8c7be0a7ccf4bc (patch)
tree0df795b7ac40a06a7c6e825a28346c72b4dddd73 /tex/context/base/sort-lan.lua
parent50888f059727e2f5857de552691eadce571db57f (diff)
downloadcontext-ab6d8e11ebd76ab61d2b451d1c8c7be0a7ccf4bc.tar.gz
beta 2011.02.11 12:23
Diffstat (limited to 'tex/context/base/sort-lan.lua')
-rw-r--r--tex/context/base/sort-lan.lua18
1 files changed, 17 insertions, 1 deletions
diff --git a/tex/context/base/sort-lan.lua b/tex/context/base/sort-lan.lua
index 8137bac13..44b92d2b0 100644
--- a/tex/context/base/sort-lan.lua
+++ b/tex/context/base/sort-lan.lua
@@ -10,7 +10,7 @@ if not modules then modules = { } end modules ['sort-lan'] = {
-- Gesang. However this is a quite adapted and reformatted variant
-- so it needs some checking.
-local utfchar = utf.char
+local utfchar, utfbyte = utf.char, utf.byte
local sorters = sorters
local definitions = sorters.definitions
local replacementoffset = sorters.constants.replacementoffset
@@ -857,3 +857,19 @@ definitions["et"] = {
"t", "u", "v", "w", "õ", "ä", "ö", "ü", "x", "y",
}
}
+
+--- Korean
+
+local first = languages.firstcharacters.korean
+
+function firstofsplit(entries,split)
+ first = first or languages.firstcharacters.korean
+ local entry = split and split[1] or ""
+ local entry = utfchar(first(utfbyte(entry)))
+ local tag = entry
+ return entry, tag
+end
+
+definitions["kr"] = {
+ firstofsplit = firstofsplit,
+}