hgmnz/truncate_html — pull request #58 by nisanth074 (2014-12-26 19:39:20+00:00)
Title: Support for non alphabetical unicode characters

Hi,

I've added support for some non alphabetical unicode characters like currency characters, math characters, symbols etc.

Previously, non alphabetical unicode characters were gobbled up
```
[2] pry(main)> utf8_html
=> "＋
ー
〜
＝
─
a　(with double-byte space)
￥
＆
％
＃
＄
！
？
＞＜
・
／
「」
＠
、。"
[3] pry(main)> TruncateHtml::HtmlTruncator.new(TruncateHtml::HtmlString.new(utf8_html), length: 1000).truncate
=> "
ー
〜
a(with double-byte space)
＆
％
＃
！
？
・
／
「」
＠
、。"
```
Now
```
[2] pry(main)> utf8_html
=> "＋
ー
〜
＝
─
a　(with double-byte space)
￥
＆
％
＃
＄
！
？
＞＜
・
／
「」
＠
、。"
[3] pry(main)> TruncateHtml::HtmlTruncator.new(TruncateHtml::HtmlString.new(utf8_html), length: 1000).truncate
=> "＋
ー
〜
＝
─
a　(with double-byte space)
￥
＆
％
＃
＄
！
？
＞＜
・
／
「」
＠
、。"
```