Modul:User:Şêr/xwendin
Xuyakirin
Belgekirina modulê[biafirîne]
local export = {}
--local m_IPA = require("Module:IPA")
--local lang = require("Module:languages").getByCode("ku")
local letters1_phonemes = {
["a"] = "a",
["b"] = "b",
["c"] = "d͡ʒ",
["ç"] = "t͡ʃ",
["d"] = "d",
["e"] = "ɛ",
["ê"] = "eː",
["f"] = "f",
["g"] = "ɡ",
["h"] = "h",
["i"] = "ɯ",
["î"] = "iː",
["j"] = "ʒ",
["k"] = "k",
["l"] = "l",
["m"] = "m",
["n"] = "n",
["o"] = "o",
["p"] = "p",
["q"] = "q",
["r"] = "r",
["s"] = "s",
["ş"] = "ʃ",
["t"] = "t",
["u"] = "u",
["û"] = "uː",
["v"] = "v",
["w"] = "w",
["x"] = "χ",
["y"] = "j",
["z"] = "z"
}
letters3_phonemes= {
["xwa"] = "χua",
["xwe"] = "χuɛ",
["xwê"] = "χueː",
["xwî"] = "χuiː"
}
local function IPA_word(word)
-- Make everything lowercase so we don't have to deal with case differences
word = mw.ustring.lower(word)
word = mw.ustring.gsub(word, '...', letters3_phonemes)
word = mw.ustring.gsub(word, '.', letters1_phonemes)
ipa = word
-- Add default stress mark if not present
if not mw.ustring.find(ipa, "ˈ") then
ipa = "ˈ" .. ipa
end
return ipa
end
function export.IPA(frame)
local words = {}
for _, word in ipairs(frame:getParent().args) do
table.insert(words, word)
end
if #words == 0 then
words = {mw.title.getCurrentTitle().text}
end
end
return export