obf 0.9.8.22 → 0.9.8.23

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/obf/pdf.rb +6 -2
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 634ef9637b8b8a49071e2bd8b51dd0e72b1a51893ef72c1c747ba25f27874001
4
- data.tar.gz: b5d17a2f08e2894bb67f8e8fcd8f7be4c23d3a17d0326e9d06e87853f3861730
3
+ metadata.gz: 3bd7e8028db1c87b73a5e2f828dac8b4e7982d71513e397021c7ae499fd0c633
4
+ data.tar.gz: ede0d55b1e4069c4e311492b0a72a3e76eaa98427b3d71872b64c89a8757794d
5
5
  SHA512:
6
- metadata.gz: 5cd0d799df8d154d55bd8c2616320ff449965ab797afc54785b6d28bc44a4371d7289564596219636339b74fa3078130f9bf6579a4607f1ebb41262520b341aa
7
- data.tar.gz: 48d255a567dee72f2eb8f13a1f635842a3bfb0ad894ce4c67413e2a97b4930d090cd383d004c3bc96e548c9af9778c463657bbbff1f03e075ce381801c409606
6
+ metadata.gz: 05337e4a5c9e1b32854b35dd782a1570e877adca12804fec6ef91a8e1e19a5e207cd3e858fff26d02caee1de7e3e2319e0d0b293f1d4c1b72a2b58a781e3ea69
7
+ data.tar.gz: 813b1ec4c0cd3c58ffc0594f23b57d79beaf30079eb4b28f04ce6151c36de3a46102d5f331db1047be3cfc2a58700721c9c6b8ad2114b397d4794d0ecc489ef1
data/lib/obf/pdf.rb CHANGED
@@ -56,7 +56,7 @@ module OBF::PDF
56
56
  pdf.font_families['Arial'] = {
57
57
  normal: {font: 'Arial', file: File.expand_path('../../Arial.ttf', __FILE__)}
58
58
  }
59
- pdf.fallback_fonts = ['TimesNewRoman', 'THFahKwangBold', 'MiedingerBook']
59
+ pdf.fallback_fonts = ['TimesNewRoman', 'THFahKwangBold', 'MiedingerBook', 'Arial']
60
60
 
61
61
  font = opts['font'] if opts['font'] && File.exists?(opts['font'])
62
62
  if font && File.exists?(font)
@@ -161,7 +161,11 @@ module OBF::PDF
161
161
  if !options['headerless']
162
162
  header_height = 80
163
163
  pdf.bounding_box([0, doc_height], :width => doc_width, :height => header_height) do
164
- pdf.font('Arial')
164
+ begin
165
+ pdf.font('Arial')
166
+ rescue => e
167
+ pdf.font(File.expand_path('../../Arial.ttf', __FILE__)) rescue nil
168
+ end
165
169
  pdf.line_width = 2
166
170
  pdf.font_size 16
167
171
  pdf.fill_color "eeeeee"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: obf
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.8.22
4
+ version: 0.9.8.23
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Whitmer