dohliam / xsampa

X-SAMPA to IPA converter
https://dohliam.github.io/xsampa/
MIT License
25 stars 3 forks source link

Support Alternate IPA symbols? #1

Open llfkj opened 7 years ago

llfkj commented 7 years ago

I'm currently scraping and converting IPA characters in the wild into X-SAMPA and back.

According to https://en.wikipedia.org/wiki/X-SAMPA (citing wikipedia. I'm sorry :), there are a few other symbols in common use for two of the IPA characters: ᵿ (= ʊ̈ or ʉ̞) and ᵻ (= ɪ̈ or ɨ̞) . I added them to a piece of my code (which I had based on the tables in conv.js) to make the parsing more robust.

In case you want to do the same, here's something pastable (python format, sorry)

  [
    "ɪ̈",
    "I\\"
  ],
  [
    "ɨ̞",
    "I\\"
  ],
  [
    "ᵻ",
    "I\\"
  ],
  [
    "ʊ̈",
    "U\\"
  ],
  [
    "ʉ̞",
    "U\\"
  ],
  [
    "ᵿ",
    "U\\"
  ]
dohliam commented 7 years ago

Thanks for this, I hadn't seen these before! Since it seems like they're a part of X-SAMPA I'll go ahead and add them to conv.js to make it more complete. Let me know if you come across any other missing symbols!