Skip to content
/ ruby-unf Public
forked from knu/ruby-unf

A wrapper library to bring Unicode Normalization Form support to Ruby/JRuby

License

Notifications You must be signed in to change notification settings

tnir/ruby-unf

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ruby-unf

Synopsis

  • A wrapper library to bring Unicode Normalization Form support to Ruby/JRuby

Description

  • Uses unf_ext on CRuby and java.text.Normalizer on JRuby.

  • Normalizes UTF-8 strings into and from NFC, NFD, NFKC or NFKD

      # For bulk conversion
      normalizer = UNF::Normalizer.instance
      a_bunch_of_strings.map! { |string|
        normalizer.normalize(string, :nfc) #=> string in NFC
      }
    
      # Class method
      UNF::Normalizer.normalize(string, :nfc)
    
      # Instance methods of String
      string.to_nfc
    

Installation

gem install unf

License

Copyright (c) 2011, 2012, 2013 Akinori MUSHA

Licensed under the 2-clause BSD license. See LICENSE for details.

About

A wrapper library to bring Unicode Normalization Form support to Ruby/JRuby

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Languages

  • Ruby 100.0%