asciidoctor-pdf-linewrap-ja 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5a7dfa5b6776ad065bbafbd6d8fee5646a6d3253
4
- data.tar.gz: e41ffa2997d3a2b28e2822e14f9d699c2981bce0
3
+ metadata.gz: 106b114729d658fe2805aa3dad294cf5f8dbe202
4
+ data.tar.gz: e67e9a76a391a44ae716133c6344ddb241248bbf
5
5
  SHA512:
6
- metadata.gz: 5454dd3f9000df206d2514860db3bb5008c12ea60281a140d1ad9bf5514dc4b1739de4c0428ad4760b4e646f92ebdc2d5470cb76205668b840207bb797eb725f
7
- data.tar.gz: 80c7fc637804599b7555e9b4af486488994b9364faa7e74837d6d8600e377f0bc4e5fe4227ea59d34c912e30a511c7c35f22a22eac98ab582e8410216bf8fc21
6
+ metadata.gz: 9937982fe7976d50ff05ced68216195082107c38ba654550e32b9c138092221d8c69747ab254944d72fae30d53c502d026ad1c8eb7d063546d3965270ebfab2f
7
+ data.tar.gz: b1ad88372d54dc3a7c8e0e3c6b5060a384ddb8952d6bea581d43b6cd3963bc548e08d82eb662ac65cb1783bdfc19c326abcb5833fb320a8b9b5941f6f642924e
@@ -6,7 +6,7 @@ module Asciidoctor
6
6
 
7
7
  # 行頭禁則文字
8
8
  PROHIBIT_LINE_BREAK_BEFORE =
9
- '}〕〉》」』】〙〗〟⦆»' +
9
+ ')}〕〉》」』】〙〗〟⦆»' +
10
10
  'ゝゞーァィゥェォッャュョヮヵヶぁぃぅぇぉっゃゅょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇷ゚ㇺㇻㇼㇽㇾㇿ々〻' +
11
11
  'ァィゥェォッャュョ' +
12
12
  '‐゠〜~' +
@@ -15,14 +15,24 @@ module Asciidoctor
15
15
  '・' +
16
16
  '、。'
17
17
 
18
+ # 行頭禁則文字(半角)
19
+ PROHIBIT_LINE_BREAK_BEFORE_HALF_WIDTH =
20
+ ')]>}' +
21
+ '-=~' +
22
+ '?!'
23
+
18
24
  # 行末禁則文字
19
- PROHIBIT_LINE_BREAK_AFTER = '{〔〈《「『【〘〖〝⦅«'
25
+ PROHIBIT_LINE_BREAK_AFTER = '({〔〈《「『【〘〖〝⦅«'
26
+
27
+ # 行末禁則文字(半角)
28
+ PROHIBIT_LINE_BREAK_AFTER_HALF_WIDTH = '([<{'
20
29
 
21
30
  # 分離禁止文字
22
31
  PROHIBIT_DIVIDE = '…‥〳〴〵'
23
32
 
24
33
  # ゼロ幅スペース
25
34
  ZERO_WIDTH_SPACE = '{zwsp}'
35
+ # ZERO_WIDTH_SPACE = '★'
26
36
 
27
37
  def self.insert_zero_width_space(line)
28
38
 
@@ -60,11 +70,11 @@ module Asciidoctor
60
70
  end
61
71
 
62
72
  def self.prohibit_line_break_after?(ch)
63
- PROHIBIT_LINE_BREAK_AFTER.include?(ch)
73
+ PROHIBIT_LINE_BREAK_AFTER.include?(ch) || PROHIBIT_LINE_BREAK_AFTER_HALF_WIDTH.include?(ch)
64
74
  end
65
75
 
66
76
  def self.prohibit_line_break_before?(ch)
67
- ch == nil || PROHIBIT_LINE_BREAK_BEFORE.include?(ch)
77
+ ch == nil || PROHIBIT_LINE_BREAK_BEFORE.include?(ch) || PROHIBIT_LINE_BREAK_BEFORE_HALF_WIDTH.include?(ch)
68
78
  end
69
79
 
70
80
  def self.prohibit_divide?(ch, next_ch)
@@ -2,7 +2,7 @@ module Asciidoctor
2
2
  module Pdf
3
3
  module Linewrap
4
4
  module Ja
5
- VERSION = "0.2.0"
5
+ VERSION = "0.3.0"
6
6
  end
7
7
  end
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: asciidoctor-pdf-linewrap-ja
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - y.fukazawa
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-05-13 00:00:00.000000000 Z
11
+ date: 2018-06-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: asciidoctor-pdf