Math Text Transform
===================


A simple crate that provides functions to map a greek letter, latin
letter, or a decimal digit to a certain variant from the mathematical
alphanumeric symbols Unicode block (U+1D400âU+1D7FF). We also provide
convenience string methods that maps each character in a string to the
variant (or leaves it alone if there is none).
Supported variants are:
* đđ¨đĨđ (bold)
* đđĄđđđđ (italic)
* đđđđ
đđđđđđ (bold italic)
* đđēđđ-đđžđđđŋ (sans-serif)
* đđŽđģđ-đđ˛đŋđļđŗ đ¯đŧđšđą (sans-serif bold)
* đ´đĸđ¯đ´-đ´đĻđŗđĒđ§ đĒđĩđĸđđĒđ¤ (sans-serif italic)
* đ¨đđŖđ¨-đ¨đđ§đđ đđ¤đĄđ đđŠđđĄđđ (sans-serif bold italic)
* đđ¸đđžđ
đ (script)
* đĢđ¸đĩđ đŧđŦđģđ˛đšđŊ (bold script)
* đŖđ¯đđ¨đąđ˛đ¯ (fraktur)
* đđđđ đđđđđđđ (bold fraktur)
* đđđđđđđđđ (monospace)
* đđ đĻđđđ-đ¤đĨđŖđĻđđ (double-struck)
Install
-------
Add this to your `Cargo.toml`:
```toml
[dependencies]
math-text-transform = "*"
```
Usage
-----
```rust
extern crate math_text_transform;
use math_text_transform::MathTextTransform;
assert_eq!("Bold".to_math_bold(), "đđ¨đĨđ");
assert_eq!("ÎŖÎąÎŊĪ-ÎŖÎĩĪΚĪ-ÎÎŋÎģδ".to_math_sans_serif_bold(), "đ¨đ°đŧđ-đ¨đ´đđ¸đ
-đđžđēđŗ");
assert_eq!("Double-struck 123".to_math_double_struck(), "đģđ đĻđđđ-đ¤đĨđŖđĻđđ đđđ");
```
Documentation
-------------
https://runarberg.github.com/math-text-transform
CLI utility
-----------
If you are for some reason only interested in the CLI utility
you can install with:
```bash
$ git clone https://github.com/runarberg/math-text-transform.git
$ cd math-text-transform
$ cargo build --release
$ [sudo] ln -s $(pwd)/target/release/math-text-transform /usr/local/bin/math-text-transform
```
And use like so:
```bash
math-text-transform <variant> <text>
```
Text can also be supplied through the standard input.
### Examples
```bash
$ math-text-transform -bf-it Bold-Italic
đŠđđđ
-đ°đđđđđ
```