Module:qay-pron: Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
Line 14: Line 14:
local export = {}
local export = {}


local consonants = "[pbmvstdnrɾlkɡŋhxçʤʧjwçx]"
local consonants = "[pbmvstdnrɾlkɡŋhxçʤʧjwçx2]"
local front = "iɪeɛ"
local front = "iɪeɛ"
local back = "oɔu"
local back = "oɔu"
local vowels = "[a" .. front .. back .. "ː´ˌ]"
local vowels = "[a" .. front .. back .. "ː´2]"


local function laxen(v)
local function laxen(v)
Line 37: Line 37:


local first_rules = {
local first_rules = {
{"n(·?)([kg])", "ŋ%1%2"}, {"ŋg", "ŋ"}, {"c", "ʧ"}, {"j", "ʤ"}, {"y", "j"}, {"g", "ɡ"}, {"%-$", ""}, {"^,", "ˌ"},
{"n(·?)([kg])", "ŋ%1%2"}, {"ŋg", "ŋ"}, {"c", "ʧ"}, {"j", "ʤ"}, {"y", "j"}, {"g", "ɡ"}, {"%-$", ""},
-- Long vowels
-- Long vowels
{"ā", "aː"},  {"ē", "eː"}, {"ī", "iː"}, {"ō", "oː"}, {"ū", "uː"},
{"ā", "aː"},  {"ē", "eː"}, {"ī", "iː"}, {"ō", "oː"}, {"ū", "uː"},
Line 67: Line 67:


local function syllabify(word)
local function syllabify(word)
word = gsub(word, "2", "ˌ")
word = gsub(word, "(ː)(" .. vowels .. ")", "%1·%2")
word = gsub(word, "(ː)(" .. vowels .. ")", "%1·%2")
word = gsub(word, "(" .. consonants .. "*)(" .. vowels .. "*)", "%1%2·")
word = gsub(word, "(" .. consonants .. "*)(" .. vowels .. "*)", "%1%2·")

Navigation menu