summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua')
-rw-r--r--Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua15
1 files changed, 6 insertions, 9 deletions
diff --git a/Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua b/Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua
index 825089802af..cecd60c1331 100644
--- a/Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua
+++ b/Master/texmf-dist/tex/generic/context/luatex/luatex-languages.lua
@@ -6,10 +6,6 @@ if not modules then modules = { } end modules ['luatex-languages'] = {
license = "see context related readme files"
}
-if context then
- os.exit()
-end
-
-- We borrow from ConTeXt.
languages = languages or { }
@@ -21,18 +17,19 @@ function languages.loadpatterns(tag)
loaded[tag] = 0
local filename = kpse.find_file("lang-" .. tag .. ".lua")
if not filename or filename == "" then
- logs.report("languages","unknown language file for '%s'",tag)
+ texio.write("<unknown language file for: " .. tag .. ">")
else
local whatever = loadfile(filename)
if type(whatever) == "function" then
whatever = whatever()
if type(whatever) == "table" then
- logs.report("languages","loading language file for '%s'",tag)
+ texio.write("<language file: " .. tag .. ">")
local characters = whatever.patterns.characters or ""
local patterns = whatever.patterns.data or ""
local exceptions = whatever.exceptions.data or ""
for b in string.utfvalues(characters) do
- -- lang.sethjcode(b,b)
+ -- what about uppercase
+-- lang.sethjcode(b,b)
tex.setlccode(b,b)
end
local language = lang.new()
@@ -40,11 +37,11 @@ function languages.loadpatterns(tag)
lang.hyphenation(language, exceptions)
loaded[tag] = lang.id(language)
else
- logs.report("languages","invalid language table for '%s'",tag)
+ texio.write("<invalid language table: " .. tag .. ">")
os.exit()
end
else
- logs.report("languages","invalid language file for '%s'",tag)
+ texio.write("<invalid language file: " .. tag .. ">")
os.exit()
end
end