Module:ábḫ-ipa: Difference between revisions

Jump to navigation Jump to search
No edit summary
No edit summary
Line 92: Line 92:
pos = 0
pos = 0
for i,val in ipairs(stresses) do
for i,val in ipairs(stresses) do
if mw.ustring.match(val, "[ˈ]") then
if mw.ustring.match(val, "ˈ") then
pos = i
pos = i
end
end
Line 103: Line 103:
if mw.ustring.match(val, "[%.]") and (i ~= syllables) then
if mw.ustring.match(val, "[%.]") and (i ~= syllables) then
if (i - pos) % 2 == 0 then
if (i - pos) % 2 == 0 then
table.insert(newStresses, "[ˌ]")
table.insert(newStresses, "ˌ")
else
else
if not (mw.ustring.match(result[1], "[%.]") and (i == 1)) then
if not (mw.ustring.match(result[1], "[%.]") and (i == 1)) then