summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Gesang <pgesang@ix.urz.uni-heidelberg.de>2010-03-13 19:53:00 +0100
committerPhilipp Gesang <pgesang@ix.urz.uni-heidelberg.de>2010-03-13 19:53:00 +0100
commitd247af02a8c4b4d5d943dcc1db48a9af7631e324 (patch)
tree9e5d03013fc1e3388c2f8e44b5cbfbec2df4c7b0
parent10fbdbe67bd39609bf58408bdd582478dccccff6 (diff)
downloadtransliterator-d247af02a8c4b4d5d943dcc1db48a9af7631e324.tar.gz
Fixed loading bug.
-rw-r--r--tex/context/third/transliterator/t-transliterator.mkiv34
-rw-r--r--tex/context/third/transliterator/trans_tables_scntfc.lua4
2 files changed, 19 insertions, 19 deletions
diff --git a/tex/context/third/transliterator/t-transliterator.mkiv b/tex/context/third/transliterator/t-transliterator.mkiv
index 474af75..b27f62e 100644
--- a/tex/context/third/transliterator/t-transliterator.mkiv
+++ b/tex/context/third/transliterator/t-transliterator.mkiv
@@ -17,7 +17,7 @@
\startmodule[transliterator]
\unprotect
-
+\ctxloadluafile{trans_tables_iso9.lua}{}
%D Use the Transliterator by adding \type{\usemodule[transliterator]} somewhere
%D before \type{\starttext}. Adjust the Transliterator through the
%D \type{\setuptransliterate} command. As a first argument it accepts a set of
@@ -199,12 +199,12 @@ end
\startluacode
function translit.show_all_tabs ()
- dofile "trans_tables_iso9.lua"
- dofile "trans_tables_trsc.lua"
- dofile "trans_tables_scntfc.lua"
- dofile "trans_tables_trsc.lua"
- dofile "trans_tables_glag.lua"
- dofile "trans_tables_gr.lua"
+ environment.loadluafile ("trans_tables_iso9")
+ environment.loadluafile ("trans_tables_trsc")
+ environment.loadluafile ("trans_tables_scntfc")
+ environment.loadluafile ("trans_tables_trsc")
+ environment.loadluafile ("trans_tables_glag")
+ environment.loadluafile ("trans_tables_gr")
translit.gen_rules_en()
translit.gen_rules_de()
-- Output all translation tables that are registered within translit.tables.
@@ -228,7 +228,7 @@ function translit.transliterate (method, text)
method == "ru_old" or
method == "all"
then
- dofile "trans_tables_iso9.lua"
+ environment.loadluafile ("trans_tables_iso9")
text = translit.iso9 (method, text)
elseif method == "ru_transcript_de" or
method == "ru_transcript_de_exp" or -- experimental lpeg
@@ -237,18 +237,18 @@ function translit.transliterate (method, text)
method == "ru_cz" or
method == "ocs_cz"
then
- dofile "trans_tables_trsc.lua"
+ environment.loadluafile ("trans_tables_trsc")
text = translit.transcript (method, text)
elseif method == "iso9_ocs" or
method == "ocs" or
method == "ocs_gla"
then
- dofile "trans_tables_scntfc.lua"
+ environment.loadluafile ("trans_tables_scntfc")
text = translit.scientific (method, text)
elseif method == "gr" or
method == "gr_n"
then
- dofile "trans_tables_gr.lua"
+ environment.loadluafile ("trans_tables_gr")
text = translit.dogreek (method, text)
end
context (text)
@@ -265,12 +265,12 @@ end
%D \type{\showOneTranslitTab{#1}}.
\define[1]\showOneTranslitTab{%
\ctxlua{
- dofile "trans_tables_iso9.lua"
- dofile "trans_tables_trsc.lua"
- dofile "trans_tables_scntfc.lua"
- dofile "trans_tables_trsc.lua"
- dofile "trans_tables_glag.lua"
- dofile "trans_tables_gr.lua"
+ environment.loadluafile ("trans_tables_iso9")
+ environment.loadluafile ("trans_tables_trsc")
+ environment.loadluafile ("trans_tables_scntfc")
+ environment.loadluafile ("trans_tables_trsc")
+ environment.loadluafile ("trans_tables_glag")
+ environment.loadluafile ("trans_tables_gr")
translit.gen_rules_en()
translit.gen_rules_de()
translit.show_tab(#1)
diff --git a/tex/context/third/transliterator/trans_tables_scntfc.lua b/tex/context/third/transliterator/trans_tables_scntfc.lua
index bf9a510..d42a970 100644
--- a/tex/context/third/transliterator/trans_tables_scntfc.lua
+++ b/tex/context/third/transliterator/trans_tables_scntfc.lua
@@ -213,7 +213,7 @@ function translit.scientific (mode, text)
local scientific_parser
if mode == ("iso9_ocs") then
- dofile "trans_tables_iso9.lua"
+ environment.loadluafile("trans_tables_iso9.lua")
translit.add_table( cyr,
translit.ru_upp,
translit.ru_low,
@@ -243,7 +243,7 @@ function translit.scientific (mode, text)
scientific_parser = Cs((p_cyruk + p_cyr + utfchar)^0)
elseif mode == ("ocs_gla") then
- dofile "trans_tables_glag.lua"
+ environment.loadluafile( "trans_tables_glag.lua")
translit.add_table( cyr, translit.ocs_gla_low, translit.ocs_gla_upp )
p_cyr = Cs(utfchar) / cyr
scientific_parser = Cs((p_cyr + utfchar)^0)