Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/huonw/unicode_names

char <-> Unicode character name
https://github.com/huonw/unicode_names

Last synced: 8 days ago
JSON representation

char <-> Unicode character name

Awesome Lists containing this project

README

        

# unicode_names

[![Build Status](https://travis-ci.org/huonw/unicode_names.png)](https://travis-ci.org/huonw/unicode_names) [![Coverage Status](https://coveralls.io/repos/huonw/unicode_names/badge.svg)](https://coveralls.io/r/huonw/unicode_names)

Time and memory efficiently mapping characters to and from their
Unicode 7.0 names, at runtime and compile-time.

```rust
extern crate unicode_names;

fn main() {
println!("☃ is called {}", unicode_names::name('☃')); // SNOWMAN
println!("{} is happy", unicode_names::character("white smiling face")); // ☺
// (NB. case insensitivity)
}
```

The maps are compressed using similar tricks to Python's `unicodedata`
module, although those here are about 70KB (12%) smaller.

[**Documentation**](http://huonw.github.io/unicode_names/unicode_names)