unicode-display_width 2.1.0 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/MIT-LICENSE.txt +1 -1
- data/README.md +5 -4
- data/data/display_width.marshal.gz +0 -0
- data/lib/unicode/display_width/constants.rb +2 -2
- metadata +5 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1fce5b196a16187b338dee6aaba7f4bf499bfc12eee213085c29296851671bc4
|
|
4
|
+
data.tar.gz: 4554e159dbc6242ab9e8e285282a6bb4361d715997df21ef81b1d9c90665b4cd
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 57824a99da0e7db191264802c8cd01e47319b1387643f4d2ea269a5ab86cfdd2c3d188bcdddc71d56c3cecfd1538940bc68b7d870f424e39cf1d9849cf8123d1
|
|
7
|
+
data.tar.gz: 655e5048a23f2576e076511d267cf5df7e382c7531e9f1e954c05e3aea5fbbf3975c1af6b4b7fadc4c433283a96afeb02e5621ca925af4bda605d9a6e3ffafeb
|
data/CHANGELOG.md
CHANGED
data/MIT-LICENSE.txt
CHANGED
data/README.md
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Determines the monospace display width of a string in Ruby. Implementation based on [EastAsianWidth.txt](https://www.unicode.org/Public/UNIDATA/EastAsianWidth.txt) and other data, 100% in Ruby. It does not rely on the OS vendor (like [wcwidth()](https://github.com/janlelis/wcswidth-ruby)) to provide an up-to-date method for measuring string width.
|
|
4
4
|
|
|
5
|
-
Unicode version: **
|
|
5
|
+
Unicode version: **15.0.0** (September 2022)
|
|
6
6
|
|
|
7
|
-
Supported Rubies: **3.0**, **2.7**
|
|
7
|
+
Supported Rubies: **3.1**, **3.0**, **2.7**
|
|
8
8
|
|
|
9
9
|
Old Rubies which might still work: **2.6**, **2.5**, **2.4**, **2.3**, **2.2**, **2.1**, **2.0**, **1.9**
|
|
10
10
|
|
|
@@ -44,7 +44,7 @@ X | (user defined) | Overwrites any other values
|
|
|
44
44
|
2 | `"\u{2E3A}"` | TWO-EM DASH
|
|
45
45
|
3 | `"\u{2E3B}"` | THREE-EM DASH
|
|
46
46
|
0 | General Categories: Mn, Me, Cf (non-arabic) | Excludes ARABIC format characters
|
|
47
|
-
0 | `"\u{1160}".."\u{11FF}"` | HANGUL JUNGSEONG
|
|
47
|
+
0 | `"\u{1160}".."\u{11FF}"`, `"\u{D7B0}".."\u{D7FF}"` | HANGUL JUNGSEONG
|
|
48
48
|
0 | `"\u{2060}".."\u{206F}"`, `"\u{FFF0}".."\u{FFF8}"`, `"\u{E0000}".."\u{E0FFF}"` | Ignorable ranges
|
|
49
49
|
2 | East Asian Width: F, W | Full-width characters
|
|
50
50
|
2 | `"\u{3400}".."\u{4DBF}"`, `"\u{4E00}".."\u{9FFF}"`, `"\u{F900}".."\u{FAFF}"`, `"\u{20000}".."\u{2FFFD}"`, `"\u{30000}".."\u{3FFFD}"` | Full-width ranges
|
|
@@ -148,12 +148,13 @@ Replace "一" with the actual string to measure
|
|
|
148
148
|
- JavaScript: https://github.com/mycoboco/wcwidth.js
|
|
149
149
|
- C: https://www.cl.cam.ac.uk/~mgk25/ucs/wcwidth.c
|
|
150
150
|
- C for Julia: https://github.com/JuliaLang/utf8proc/issues/2
|
|
151
|
+
- Golang: https://github.com/rivo/uniseg
|
|
151
152
|
|
|
152
153
|
See [unicode-x](https://github.com/janlelis/unicode-x) for more Unicode related micro libraries.
|
|
153
154
|
|
|
154
155
|
## Copyright & Info
|
|
155
156
|
|
|
156
|
-
- Copyright (c) 2011, 2015-
|
|
157
|
+
- Copyright (c) 2011, 2015-2022 Jan Lelis, https://janlelis.com, released under the MIT
|
|
157
158
|
license
|
|
158
159
|
- Early versions based on runpaint's unicode-data interface: Copyright (c) 2009 Run Paint Run Run
|
|
159
160
|
- Unicode data: https://www.unicode.org/copyright.html#Exhibit1
|
|
Binary file
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
module Unicode
|
|
4
4
|
class DisplayWidth
|
|
5
|
-
VERSION = "2.
|
|
6
|
-
UNICODE_VERSION = "
|
|
5
|
+
VERSION = "2.3.0"
|
|
6
|
+
UNICODE_VERSION = "15.0.0"
|
|
7
7
|
DATA_DIRECTORY = File.expand_path(File.dirname(__FILE__) + "/../../../data/")
|
|
8
8
|
INDEX_FILENAME = DATA_DIRECTORY + "/display_width.marshal.gz"
|
|
9
9
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: unicode-display_width
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.3.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jan Lelis
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2022-09-14 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rspec
|
|
@@ -38,7 +38,7 @@ dependencies:
|
|
|
38
38
|
- - "~>"
|
|
39
39
|
- !ruby/object:Gem::Version
|
|
40
40
|
version: '13.0'
|
|
41
|
-
description: "[Unicode
|
|
41
|
+
description: "[Unicode 15.0.0] Determines the monospace display width of a string
|
|
42
42
|
using EastAsianWidth.txt, Unicode general category, and other data."
|
|
43
43
|
email:
|
|
44
44
|
- hi@ruby.consulting
|
|
@@ -65,6 +65,7 @@ metadata:
|
|
|
65
65
|
changelog_uri: https://github.com/janlelis/unicode-display_width/blob/master/CHANGELOG.md
|
|
66
66
|
source_code_uri: https://github.com/janlelis/unicode-display_width
|
|
67
67
|
bug_tracker_uri: https://github.com/janlelis/unicode-display_width/issues
|
|
68
|
+
rubygems_mfa_required: 'true'
|
|
68
69
|
post_install_message:
|
|
69
70
|
rdoc_options: []
|
|
70
71
|
require_paths:
|
|
@@ -80,7 +81,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
80
81
|
- !ruby/object:Gem::Version
|
|
81
82
|
version: '0'
|
|
82
83
|
requirements: []
|
|
83
|
-
rubygems_version: 3.
|
|
84
|
+
rubygems_version: 3.3.7
|
|
84
85
|
signing_key:
|
|
85
86
|
specification_version: 4
|
|
86
87
|
summary: Determines the monospace display width of a string in Ruby.
|