martile 0.1.25 → 0.1.26

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: b0361a32eae512f26928818c9c8daa48ebef6b10
4
- data.tar.gz: b606844ed4c5cfba46800b200989517dc58f5aa2
3
+ metadata.gz: 3a886f82c2bff38a89cd3f9359f3d12dd28cddfa
4
+ data.tar.gz: 29c17fc6058147279d46b8be5b6fb824724c60b2
5
5
  SHA512:
6
- metadata.gz: c63c7282c1fa1841feeeaddb65170aa9117b66d67b73921a9e2362ae63d01ed29eda7fb49378eedc98e23314f621a6eac1d721c1ff46c9cf50a5901030906ebc
7
- data.tar.gz: 74195998ec5f28bec48dd0e3fb4cb1905979afc8b96fe62433cf1158f4c47a0491d9cb3dfdcf38010ab7759467e5758c465c86391bd9b5a20d1dc72accda51ae
6
+ metadata.gz: ab7d032ac774a73891a69224952be3ca1740a59bb7f9aaac77222850b68ef8849df37627c9690d953d085468f2c3551d589351fdda0dfdd10edb3b0c1da2434d
7
+ data.tar.gz: 06ff6985bfd449d0693a8d5c4b612c803866a7e52df4a0610756a1df738948f3faffa98300db51f42d1237e25a0cbc85bc9974c2139125066bfbd740761e2fe5
checksums.yaml.gz.sig CHANGED
Binary file
data.tar.gz.sig CHANGED
Binary file
data/lib/martile.rb CHANGED
@@ -8,6 +8,7 @@ require 'dynarex'
8
8
  require 'rdiscount'
9
9
 
10
10
 
11
+ # feature: 31-Mar-2014: Added an _underline_ feature.
11
12
  # bug fix: 01-Mar-2014: A Dynarex_to_table statement between 2 HTML blocks
12
13
  # is now handled properly.
13
14
  # bug fix: 01-Mar-2014: Multiple pre tags within a string can now be handled
@@ -62,7 +63,9 @@ class Martile
62
63
  #puts 's5 :' + s5.inspect
63
64
  s6 = filter_out_html(s5, :table_to_html)
64
65
  #puts 's6 : ' + s6.inspect
65
- @to_html = s6
66
+ s7 = filter_out_html(s6, :underline)
67
+ #puts 's7 : ' + s7.inspect
68
+ @to_html = s7
66
69
  end
67
70
 
68
71
  private
@@ -171,12 +174,16 @@ class Martile
171
174
  end
172
175
  end
173
176
  end
174
-
175
- Rexle.new(a).xml pretty: true, declaration: false
176
-
177
+ puts 'a = ' + a.inspect
178
+ r = Rexle.new(a).xml pretty: true, declaration: false
179
+ puts 'r : ' + r.inspect
180
+ r
177
181
  end
178
182
  return s
179
183
  end
180
184
 
185
+ def underline(s)
186
+ s.gsub(/_[^_]+_/){|x| "<span class='underline'>%s</span>" % x[1..-2]}
187
+ end
181
188
 
182
189
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: martile
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.25
4
+ version: 0.1.26
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -31,7 +31,7 @@ cert_chain:
31
31
  YF3JmVOebtMx3b9sXkLX1YyX0fsg59FXvg9CVfAoaG6qjG2Y/okBwMSqqMLQiiao
32
32
  aRfEuwOkM9Z+zA==
33
33
  -----END CERTIFICATE-----
34
- date: 2014-03-01 00:00:00.000000000 Z
34
+ date: 2014-03-31 00:00:00.000000000 Z
35
35
  dependencies:
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: rexle-builder
metadata.gz.sig CHANGED
Binary file