fillable-pdf-th 1.0.0 → 1.0.1

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
  SHA256:
3
- metadata.gz: '0883aae0f2aa55f745ae1a862fd387900434694853fb0b5420742fcb140697b0'
4
- data.tar.gz: 948d65d76a5fcf0a4cd11d7db614e46675841913e04d2c69709332da2af7c990
3
+ metadata.gz: b2dab2de8e322ae58fc8caf400a2b5f18e66bf51a6ec87ce54fa2f9b2175e72d
4
+ data.tar.gz: f59dfab7a5d1bc7e4345b07c351a680ca626e57f0f6ae28163e5bf8811ff7b75
5
5
  SHA512:
6
- metadata.gz: 782a06991cf25df8a9506fa2a1b748c3cc327f653ad993c71f414e2c16b5ed875ae566b97c31248cc1e1ff8cc415257bd9d8d52e0424081612ca3e1e75a3798c
7
- data.tar.gz: 845ac00ff2db6fa63d9fbb98b382a47b9382ab5439a9c94cc9e2f140a9d0e7e5e1df701c4791eaf7cdb16580b51badd7923eb412e7974f8c97bdd41ff3ea803e
6
+ metadata.gz: 1159e931fa9ef4a0e23268eea1228f1606fb6b1bdca0454050c51f2dcf0892e243d35dce898c3dd3b8661e07ec35bd174f5a5a1da7860aa4cb8afe227c1988f1
7
+ data.tar.gz: 58eb4bf392f70fcf83e5f5fbfa8088a4eece102e692223306a4847ad25d3dd8d4098cb6869b02f85d11f2957e2acd6878aff2121cb3ac47bf47d1c556138207e
data/.rubocop.yml CHANGED
@@ -13,7 +13,7 @@ Layout/SpaceInsideHashLiteralBraces:
13
13
 
14
14
  Metrics/LineLength:
15
15
  Exclude:
16
- - fillable-pdf.gemspec
16
+ - fillable-pdf-th.gemspec
17
17
  Max: 120
18
18
 
19
19
  Naming/AccessorMethodName:
data/README.md CHANGED
@@ -14,7 +14,7 @@ FillablePDF is an extremely simple and lightweight utility that bridges iText an
14
14
 
15
15
  Add this line to your application's Gemfile:
16
16
 
17
- gem 'fillable-pdf'
17
+ gem 'fillable-pdf-th'
18
18
 
19
19
  And then execute:
20
20
 
@@ -22,12 +22,12 @@ And then execute:
22
22
 
23
23
  Or install it yourself as:
24
24
 
25
- gem install fillable-pdf
25
+ gem install fillable-pdf-th
26
26
 
27
27
  If you are using this gem in a script, you need to require it manually:
28
28
 
29
29
  ```ruby
30
- require 'fillable-pdf'
30
+ require 'fillable-pdf-th'
31
31
  ```
32
32
 
33
33
  ## Usage
@@ -35,10 +35,10 @@ require 'fillable-pdf'
35
35
  First of all, you should open a fillable PDF file:
36
36
 
37
37
  ```ruby
38
- pdf = FillablePDF.new 'input.pdf'
38
+ pdf = FillablePDFTH.new 'input.pdf'
39
39
  ```
40
40
 
41
- An instance of `FillablePDF` has the following methods at its disposal:
41
+ An instance of `FillablePDFTH` has the following methods at its disposal:
42
42
 
43
43
  ```ruby
44
44
  fillable-pdf
@@ -148,10 +148,10 @@ pdf.save_as('output.pdf', flatten: true)
148
148
  The following example [example.rb](example/run.rb) and the input file [input.pdf](example/input.pdf) are located in the `test` directory. It uses all of the methods that are described above and generates the output files [output.pdf](example/output.pdf) and [output.flat.pdf](example/output.flat.pdf).
149
149
 
150
150
  ```ruby
151
- require 'fillable-pdf'
151
+ require 'fillable-pdf-th'
152
152
 
153
153
  # opening a fillable PDF
154
- pdf = FillablePDF.new('input.pdf')
154
+ pdf = FillablePDFTH.new('input.pdf')
155
155
 
156
156
  # total number of fields
157
157
  if pdf.any_fields?
@@ -210,7 +210,7 @@ puts "Signatory: #{pdf.field(:first_name)} #{pdf.field(:last_name)}"
210
210
  pdf.save_as('output.pdf')
211
211
 
212
212
  # saving another copy of the filled out PDF in another file and making it non-editable
213
- pdf = FillablePDF.new('output.pdf')
213
+ pdf = FillablePDFTH.new('output.pdf')
214
214
  pdf.save_as 'output.flat.pdf', flatten: true
215
215
  ```
216
216
 
data/bin/console CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
3
  require 'bundler/setup'
4
- require 'fillable-pdf'
4
+ require 'fillable-pdf-th'
5
5
 
6
6
  # You can add fixtures and/or initialization code here to make experimenting
7
7
  # with your gem easier. You can also use a different console, if you like.
@@ -1,10 +1,10 @@
1
1
  lib = File.expand_path('lib', __dir__)
2
2
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
- require 'fillable-pdf/version'
3
+ require 'fillable-pdf-th/version'
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = 'fillable-pdf-th'
7
- spec.version = FillablePDF::VERSION
7
+ spec.version = FillablePDFTH::VERSION
8
8
  spec.authors = ['Swiftlet']
9
9
  spec.email = ['swiftlet.dev@gmail.com']
10
10
 
data/lib/field.rb CHANGED
@@ -1,4 +1,4 @@
1
- require_relative 'fillable-pdf/itext'
1
+ require_relative 'fillable-pdf-th/itext'
2
2
 
3
3
  class Field
4
4
  class << self
@@ -1,8 +1,8 @@
1
- require_relative 'fillable-pdf/itext'
1
+ require_relative 'fillable-pdf-th/itext'
2
2
  require_relative 'field'
3
3
  require 'securerandom'
4
4
 
5
- class FillablePDF
5
+ class FillablePDFTH
6
6
  # required Java imports
7
7
  BYTE_STREAM = Rjb.import 'com.itextpdf.io.source.ByteArrayOutputStream'
8
8
  PDF_READER = Rjb.import 'com.itextpdf.kernel.pdf.PdfReader'
File without changes
@@ -0,0 +1,3 @@
1
+ class FillablePDFTH
2
+ VERSION = '1.0.1'
3
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fillable-pdf-th
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Swiftlet
@@ -92,9 +92,9 @@ files:
92
92
  - fillable-pdf-th.gemspec
93
93
  - lib/default-font/angsana_new.ttf
94
94
  - lib/field.rb
95
- - lib/fillable-pdf.rb
96
- - lib/fillable-pdf/itext.rb
97
- - lib/fillable-pdf/version.rb
95
+ - lib/fillable-pdf-th.rb
96
+ - lib/fillable-pdf-th/itext.rb
97
+ - lib/fillable-pdf-th/version.rb
98
98
  homepage: https://github.com/swiftlet-dev/fillable-pdf-th
99
99
  licenses:
100
100
  - MIT
@@ -1,3 +0,0 @@
1
- class FillablePDF
2
- VERSION = '1.0.0'
3
- end