pdf-reader-turtletext 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG CHANGED
@@ -1,4 +1,8 @@
1
- Version 0.2.0 Release: n/a
1
+ Version 0.2.1 Release: n/a
2
+ ==================================================
3
+ * fix row sorting for Rubinius 1.8 mode
4
+
5
+ Version 0.2.0 Release: 31st July 2012
2
6
  ==================================================
3
7
  * add bounding_box / textangle semantics
4
8
  * improve documentation
@@ -57,9 +57,9 @@ class PDF::Reader::Turtletext
57
57
  if y_index
58
58
  row_content = output[y_index].last
59
59
  row_content += new_row_content
60
- output[y_index] = [matching_y,row_content]
60
+ output[y_index] = [matching_y,row_content.sort{|a,b| a.first <=> b.first }]
61
61
  else
62
- output << [matching_y,new_row_content]
62
+ output << [matching_y,new_row_content.sort{|a,b| a.first <=> b.first }]
63
63
  end
64
64
  end
65
65
  output
@@ -91,10 +91,10 @@ class PDF::Reader::Turtletext
91
91
  row = []
92
92
  text_row.each do |x,element|
93
93
  if x >= xmin && x<= xmax
94
- row << [x,element]
94
+ row << element
95
95
  end
96
96
  end
97
- box << row.sort{|a,b| a.first <=> b.first }.map(&:last) unless row.empty?
97
+ box << row unless row.empty?
98
98
  end
99
99
  end
100
100
  box
@@ -4,7 +4,7 @@ module PDF
4
4
  class Version
5
5
  MAJOR = 0
6
6
  MINOR = 2
7
- PATCH = 0
7
+ PATCH = 1
8
8
 
9
9
  STRING = [MAJOR, MINOR, PATCH].compact.join('.')
10
10
  end
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "pdf-reader-turtletext"
8
- s.version = "0.2.0"
8
+ s.version = "0.2.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Paul Gallagher"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pdf-reader-turtletext
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -13,7 +13,7 @@ date: 2012-07-31 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: pdf-reader
16
- requirement: &70218189955060 !ruby/object:Gem::Requirement
16
+ requirement: &70339095317400 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - =
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 1.1.1
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70218189955060
24
+ version_requirements: *70339095317400
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: bundler
27
- requirement: &70218189954360 !ruby/object:Gem::Requirement
27
+ requirement: &70339095316760 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ~>
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 1.1.4
33
33
  type: :development
34
34
  prerelease: false
35
- version_requirements: *70218189954360
35
+ version_requirements: *70339095316760
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: jeweler
38
- requirement: &70218189953580 !ruby/object:Gem::Requirement
38
+ requirement: &70339095315980 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ~>
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: 1.6.4
44
44
  type: :development
45
45
  prerelease: false
46
- version_requirements: *70218189953580
46
+ version_requirements: *70339095315980
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: rake
49
- requirement: &70218189953020 !ruby/object:Gem::Requirement
49
+ requirement: &70339095315380 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ~>
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: 0.9.2.2
55
55
  type: :development
56
56
  prerelease: false
57
- version_requirements: *70218189953020
57
+ version_requirements: *70339095315380
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: rspec
60
- requirement: &70218189952200 !ruby/object:Gem::Requirement
60
+ requirement: &70339095314600 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ~>
@@ -65,10 +65,10 @@ dependencies:
65
65
  version: 2.8.0
66
66
  type: :development
67
67
  prerelease: false
68
- version_requirements: *70218189952200
68
+ version_requirements: *70339095314600
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rdoc
71
- requirement: &70218189951400 !ruby/object:Gem::Requirement
71
+ requirement: &70339095313760 !ruby/object:Gem::Requirement
72
72
  none: false
73
73
  requirements:
74
74
  - - ~>
@@ -76,10 +76,10 @@ dependencies:
76
76
  version: '3.11'
77
77
  type: :development
78
78
  prerelease: false
79
- version_requirements: *70218189951400
79
+ version_requirements: *70339095313760
80
80
  - !ruby/object:Gem::Dependency
81
81
  name: prawn
82
- requirement: &70218189950700 !ruby/object:Gem::Requirement
82
+ requirement: &70339095313100 !ruby/object:Gem::Requirement
83
83
  none: false
84
84
  requirements:
85
85
  - - ~>
@@ -87,10 +87,10 @@ dependencies:
87
87
  version: 0.12.0
88
88
  type: :development
89
89
  prerelease: false
90
- version_requirements: *70218189950700
90
+ version_requirements: *70339095313100
91
91
  - !ruby/object:Gem::Dependency
92
92
  name: guard-rspec
93
- requirement: &70218189950100 !ruby/object:Gem::Requirement
93
+ requirement: &70339095312500 !ruby/object:Gem::Requirement
94
94
  none: false
95
95
  requirements:
96
96
  - - ~>
@@ -98,7 +98,7 @@ dependencies:
98
98
  version: 1.2.0
99
99
  type: :development
100
100
  prerelease: false
101
- version_requirements: *70218189950100
101
+ version_requirements: *70339095312500
102
102
  description: a library that can read structured and positional text from PDFs. Ideal
103
103
  for asembling structured data from invoices and the like.
104
104
  email: gallagher.paul@gmail.com