All Projects → dohliam → xsampa

dohliam / xsampa

Licence: MIT license
X-SAMPA to IPA converter

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects
CSS
56736 projects

Projects that are alternatives of or similar to xsampa

Ec2 Spot Converter
A tool to convert AWS EC2 instances back and forth between On-Demand and Spot billing models.
Stars: ✭ 108 (+440%)
Mutual labels:  converter, conversion
fp-units
An FP-oriented library to easily convert CSS units.
Stars: ✭ 18 (-10%)
Mutual labels:  converter, conversion
Hrconvert2
A self-hosted, drag-and-drop, & nosql file conversion server that supports 62x file formats.
Stars: ✭ 132 (+560%)
Mutual labels:  converter, conversion
Remarshal
Convert between CBOR, JSON, MessagePack, TOML, and YAML
Stars: ✭ 421 (+2005%)
Mutual labels:  converter, conversion
BlocksConverter
A PocketMine-MP plugin allows you to convert Minecraft PC maps to MCPE/Bedrock maps or vice-versa.
Stars: ✭ 47 (+135%)
Mutual labels:  converter, conversion
Oas Kit
Convert Swagger 2.0 definitions to OpenAPI 3.0 and resolve/validate/lint
Stars: ✭ 516 (+2480%)
Mutual labels:  converter, conversion
cpc
Text calculator with support for units and conversion
Stars: ✭ 89 (+345%)
Mutual labels:  converter, conversion
dftools
Tools for Star Wars: Dark Forces assets.
Stars: ✭ 18 (-10%)
Mutual labels:  converter, conversion
vectorexpress-api
Vector Express is a free service and API for converting, analyzing and processing vector files.
Stars: ✭ 66 (+230%)
Mutual labels:  converter, conversion
caffe weight converter
Caffe-to-Keras weight converter. Can also export weights as Numpy arrays for further processing.
Stars: ✭ 68 (+240%)
Mutual labels:  converter, conversion
Length.js
📏 JavaScript library for length units conversion.
Stars: ✭ 292 (+1360%)
Mutual labels:  converter, conversion
discoursegraphs
linguistic converter / merging tool for multi-level annotated corpora. graph-based (using Python and NetworkX).
Stars: ✭ 47 (+135%)
Mutual labels:  converter, conversion
sublime-atomizr
Convert Sublime Text completions into Atom (or Visual Studio Code) snippets, and vice versa.
Stars: ✭ 12 (-40%)
Mutual labels:  converter, conversion
Unitsnet
Makes life working with units of measurement just a little bit better.
Stars: ✭ 641 (+3105%)
Mutual labels:  converter, conversion
quill-markdown-toolbar
A Quill.js module for converting markdown text to rich text format
Stars: ✭ 13 (-35%)
Mutual labels:  converter, conversion
Kepubify
Fast, standalone EPUB to KEPUB converter CLI app / library (and a few other utilities).
Stars: ✭ 225 (+1025%)
Mutual labels:  converter, conversion
bitsnpicas
Bits'N'Picas - Bitmap & Emoji Font Creation & Conversion Tools
Stars: ✭ 171 (+755%)
Mutual labels:  converter, conversion
bank2ynab
Easily convert and import your bank's statements into YNAB. This project consolidates other conversion efforts into one universal tool.
Stars: ✭ 197 (+885%)
Mutual labels:  converter, conversion
csv2html
Convert CSV files to HTML tables
Stars: ✭ 64 (+220%)
Mutual labels:  converter, conversion
qTsConverter
A simple tool to convert qt translation file (ts) to other format (xlsx / csv) and vice versa
Stars: ✭ 26 (+30%)
Mutual labels:  converter, conversion

xsampa.js - X-SAMPA to IPA conversion in the browser

Xsampa.js converts X-SAMPA text into equivalent Unicode IPA symbols. It has no dependencies and should work in any browser with JavaScript enabled. It is designed to work locally and does not require access to a command-line or an internet connection. It also has a handy API allowing you to get arbitrary IPA text by linking directly to an X-SAMPA string in the URL.

The main purpose of xsampa.js is to allow easy input of IPA without the need to install any special software, input methods, or command-line tools, and in circumstances where it may not be possible to get online. It also makes it easy to input IPA on mobile devices like phones where this would otherwise be difficult without special software.

Usage

To start converting X-SAMPA text immediately, just open up xsampa.js in your browser and start typing. Text entered into the input box will be automatically converted to its equivalent IPA as you type.

If you can't remember how to type a particular IPA symbol in X-SAMPA, there is a handy pop-up guide containing all the symbols and their equivalents which you can access by just hovering your mouse over the "X-SAMPA Guide" button in the middle of the page.

Note: You do not need to enclose the X-SAMPA text in square brackets or slashes. For instance, the text Ig"z{mp@l will be rendered as ɪɡˈzæmpəl, [Ig"z{mp@l] will turn into [ɪɡˈzæmpəl], and /Ig"z{mp@l/ will be converted to /ɪɡˈzæmpəl/.

Access keys

The input and output boxes can be accessed using keyboard access keys for convenience:

  • Modifier key + i: Input box
  • Modifier key + o: Output box

The modifier keys you need to press will differ depending on which browser and operating system you are using. See below for a list of common access keys for different browsers.

  • Chrome: Alt (*nix & Windows) or Ctrl + ⌥ Opt (Mac)
  • Firefox: Alt + Shift (*nix & Windows) or Ctrl + ⌥ Opt (Mac)
  • IE: Alt
  • Konqueror: Ctrl
  • Opera: Alt (*nix & Windows) or Ctrl + ⌥ Opt (Mac)
  • Safari: Alt (*nix & Windows) or Ctrl + ⌥ Opt (Mac)

A more complete list of modifier keys can be found here.

API

The converter can be accessed by typing X-SAMPA text directly after a question mark (?) appended to the end of the file url. For example, to convert the string [aI p_hi: eI] into IPA, you can use a link like this:

https://dohliam.github.io/xsampa/?[aI p_hi: eI]

You can see what it looks like [here](https://dohliam.github.io/xsampa/?[aI p_hi: eI]). You should see text [aɪ pʰiː eɪ] appear in the text output box, as well as in the HTML output area at the bottom of the screen. Here is an example in SVG format of what the text should look like.

Download

You can clone this repository or download a zip file of the contents and begin using it right away.

Alternatively, you can download the demo which is a single html page that has been compiled automatically from the various source files and contains everything needed to run the converter. To do this, just go to https://dohliam.github.io/xsampa and use the "Save page" or "Save page as..." function in your browser to save the page to your computer.

Why?

Because I needed something that did this.

Hasn't this been done before?

Yes. X-SAMPA to IPA conversion is a long-solved problem and there are a wide variety of tools that already do this very nicely. For example, if you are using Moodle, there is an IPA filter that will convert X-SAMPA into IPA. There is nothing innovative about the conversion itself either, since it involves nothing more than a straightforward search-and-replace of each of the unique X-SAMPA symbols into IPA.

So, to be clear, what I was looking for already existed -- just not in the specific configuration I needed, and under a free license, and also accessible offline without running a local server.

To do

  • Button to switch conversion to IPA => X-SAMPA

License

MIT -- see LICENSE file for details.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].