Module:rhymes: Difference between revisions

Jump to navigation Jump to search
ਕੋਈ ਸੋਧ ਸਾਰ ਨਹੀਂ
No edit summary
No edit summary
Line 17: Line 17:
function de_onset(ipa)
function de_onset(ipa)
ipa = mw.ustring.gsub(ipa, "[ˈˌ]", "")
ipa = mw.ustring.gsub(ipa, "[ˈˌ]", "")
ipa = mw.ustring.gsub(ipa, "^[^" .. V .. "]+", "")
mw.log(ipa)
ipa = mw.ustring.gsub(ipa, "^[" .. V .. "][̥̊]", "")
while true do
if mw.ustring.find(ipa, "^[" .. V .. "]̯") then
ipa = mw.ustring.sub(ipa, 3)
elseif mw.ustring.find(ipa, "^[" .. V .. "]") or mw.ustring.find(ipa, "^%S̩") then
break
else
ipa = mw.ustring.sub(ipa, 2)
end
mw.log(ipa)
end
return ipa
return ipa
end
end

Navigation menu