Module:Deranize: Difference between revisions

Fix tone marks with implicit o'aomo
(Only show word-initial o'aomo when necessary)
(Fix tone marks with implicit o'aomo)
Line 122: Line 122:
     if is_diphthong and reform then medial, final = v, "" end
     if is_diphthong and reform then medial, final = v, "" end
     local glyphs = {initial, tone, medial}
     local glyphs = {initial, tone, medial}
     if initial == ""
     if initial == "" and is_first_syllable then
      and is_first_syllable
       if (final == "" or (reform and is_diphthong))
       and (final == "" or (reform and is_diphthong))
        and coda == ""
      and coda == ""
        and (vowel_lookalikes[next_initial] or (reform and diphthong_lookalikes[next_initial])) then
      and (vowel_lookalikes[next_initial] or (reform and diphthong_lookalikes[next_initial])) then
        glyphs[1] = "'"
       glyphs[1] = "'"
       else
        glyphs[1] = ""
      end
     end
     end
     if not is_first_syllable then glyphs[2] = "" end
     if not is_first_syllable then glyphs[2] = "" end