Module: Prawn::Markup::Processor::Text
- Included in:
- Prawn::Markup::Processor
- Defined in:
- lib/prawn/markup/processor/text.rb
Class Method Summary collapse
Instance Method Summary collapse
- #end_a ⇒ Object (also: #end_link)
- #end_b ⇒ Object (also: #end_strong)
- #end_i ⇒ Object (also: #end_em)
- #end_strikethrough ⇒ Object (also: #end_s, #end_strike, #end_del)
- #end_sub ⇒ Object
- #end_sup ⇒ Object
- #end_u ⇒ Object
- #start_a ⇒ Object (also: #start_link)
- #start_b ⇒ Object (also: #start_strong)
- #start_i ⇒ Object (also: #start_em)
- #start_strikethrough ⇒ Object (also: #start_s, #start_strike, #start_del)
- #start_sub ⇒ Object
- #start_sup ⇒ Object
- #start_u ⇒ Object
Class Method Details
.prepended(base) ⇒ Object
6 7 8 9 10 11 |
# File 'lib/prawn/markup/processor/text.rb', line 6 def self.prepended(base) base.known_elements.push( 'a', 'b', 'strong', 'i', 'em', 'u', 'strikethrough', 'strike', 's', 'del', 'sub', 'sup' ) end |
Instance Method Details
#end_a ⇒ Object Also known as: end_link
18 19 20 |
# File 'lib/prawn/markup/processor/text.rb', line 18 def end_a append_text('</link>') end |
#end_b ⇒ Object Also known as: end_strong
28 29 30 |
# File 'lib/prawn/markup/processor/text.rb', line 28 def end_b append_text('</b>') end |
#end_i ⇒ Object Also known as: end_em
38 39 40 |
# File 'lib/prawn/markup/processor/text.rb', line 38 def end_i append_text('</i>') end |
#end_strikethrough ⇒ Object Also known as: end_s, end_strike, end_del
58 59 60 |
# File 'lib/prawn/markup/processor/text.rb', line 58 def end_strikethrough append_text('</strikethrough>') end |
#end_sub ⇒ Object
69 70 71 |
# File 'lib/prawn/markup/processor/text.rb', line 69 def end_sub append_text('</sub>') end |
#end_sup ⇒ Object
77 78 79 |
# File 'lib/prawn/markup/processor/text.rb', line 77 def end_sup append_text('</sup>') end |
#end_u ⇒ Object
47 48 49 |
# File 'lib/prawn/markup/processor/text.rb', line 47 def end_u append_text('</u>') end |
#start_a ⇒ Object Also known as: start_link
13 14 15 |
# File 'lib/prawn/markup/processor/text.rb', line 13 def start_a append_text("<link href=\"#{current_attrs['href']}\">") end |
#start_b ⇒ Object Also known as: start_strong
23 24 25 |
# File 'lib/prawn/markup/processor/text.rb', line 23 def start_b append_text('<b>') end |
#start_i ⇒ Object Also known as: start_em
33 34 35 |
# File 'lib/prawn/markup/processor/text.rb', line 33 def start_i append_text('<i>') end |
#start_strikethrough ⇒ Object Also known as: start_s, start_strike, start_del
51 52 53 |
# File 'lib/prawn/markup/processor/text.rb', line 51 def start_strikethrough append_text('<strikethrough>') end |
#start_sub ⇒ Object
65 66 67 |
# File 'lib/prawn/markup/processor/text.rb', line 65 def start_sub append_text('<sub>') end |
#start_sup ⇒ Object
73 74 75 |
# File 'lib/prawn/markup/processor/text.rb', line 73 def start_sup append_text('<sup>') end |
#start_u ⇒ Object
43 44 45 |
# File 'lib/prawn/markup/processor/text.rb', line 43 def start_u append_text('<u>') end |