chinese_convt 0.0.5 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +16 -31
- data/chinese_convt.gemspec +2 -2
- data/lib/chinese_convert/zh_convt +35 -1
- data/lib/chinese_convert/zh_convt.rb +9 -11
- data/test/test_chinese_convt.rb +7 -5
- metadata +3 -3
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
#
|
1
|
+
#Chinese_Convt
|
2
2
|
|
3
3
|
[RubyGems](http://rubygems.org/gems/chinese_convt)
|
4
4
|
|
@@ -10,10 +10,10 @@
|
|
10
10
|
將簡體中文轉換為繁體中文,或反之將繁體中文轉為簡體中文,亦可考慮中港台三地不同用詞習慣而作轉換。
|
11
11
|
|
12
12
|
例:
|
13
|
-
(
|
14
|
-
(
|
15
|
-
(台灣)
|
16
|
-
(
|
13
|
+
(简体)干部一干人等干事不干不净 <=> (繁體)幹部一干人等幹事不乾不淨
|
14
|
+
(中国)触摸屏取代鼠标对互联网的影响 => (台灣)觸控螢幕取代滑鼠對網際網路的影響
|
15
|
+
(台灣)線上辭典查詢達文西密碼 => (中国)在线词典查找达芬奇密码
|
16
|
+
(中国)嘴里吃着金鎗鱼三明治 => (香港)嘴裏吃着吞拿魚三文治
|
17
17
|
|
18
18
|
|
19
19
|
## Installation
|
@@ -22,32 +22,17 @@
|
|
22
22
|
|
23
23
|
|
24
24
|
## Usage
|
25
|
-
|
26
|
-
|
25
|
+
####convert string to Traditional Chinese - 轉換至繁體中文
|
26
|
+
Chinese.zh2tra( str )
|
27
27
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
Chinese.zh2sim( str )
|
35
|
-
|
36
|
-
|
37
|
-
convert string to Traditional Chinese of Taiwan
|
38
|
-
將字串轉換至台灣繁體中文
|
39
|
-
|
40
|
-
Chinese.zh2tw( str )
|
41
|
-
|
42
|
-
|
43
|
-
convert string to Traditional Chinese of Hong Kong
|
44
|
-
將字串轉換至香港繁體中文
|
45
|
-
|
46
|
-
Chinese.zh2hk( str )
|
47
|
-
|
48
|
-
|
49
|
-
convert string to Simplified Chinese of China
|
50
|
-
將字串轉換至中國簡體中文
|
28
|
+
####convert string to Simplified Chinese - 轉換至简体中文
|
29
|
+
Chinese.zh2sim( str )
|
30
|
+
|
31
|
+
####convert string to Traditional Chinese of Taiwan - 轉換至台灣繁體中文
|
32
|
+
Chinese.zh2tw( str )
|
51
33
|
|
52
|
-
|
34
|
+
####convert string to Traditional Chinese of Hong Kong - 轉換至香港繁體中文
|
35
|
+
Chinese.zh2hk( str )
|
53
36
|
|
37
|
+
####convert string to Simplified Chinese of China - 轉換至中国简体中文
|
38
|
+
Chinese.zh2cn( str )
|
data/chinese_convt.gemspec
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'chinese_convt'
|
3
|
-
s.version = '0.0
|
4
|
-
s.date = '2012-
|
3
|
+
s.version = '0.1.0'
|
4
|
+
s.date = '2012-09-22'
|
5
5
|
s.summary = "Traditional and Simplified Chinese conversion~~"
|
6
6
|
s.description = "Conversion between Traditional and Simplified Chinese. furthermore, adjusting phrases to conform in Taiwan or Hong Kong or China."
|
7
7
|
s.authors = ["xxxooo"]
|