Class: Sablon::Content::WordML
- Inherits:
-
Struct
- Object
- Struct
- Sablon::Content::WordML
show all
- Includes:
- Sablon::Content
- Defined in:
- lib/sablon/content.rb
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
make, register, remove, wrap
Instance Attribute Details
#xml ⇒ Object
Returns the value of attribute xml
67
68
69
|
# File 'lib/sablon/content.rb', line 67
def xml
@xml
end
|
Class Method Details
.id ⇒ Object
69
|
# File 'lib/sablon/content.rb', line 69
def self.id; :word_ml end
|
.wraps?(value) ⇒ Boolean
70
|
# File 'lib/sablon/content.rb', line 70
def self.wraps?(value) false end
|
Instance Method Details
#append_to(paragraph, display_node) ⇒ Object
72
73
74
75
76
77
|
# File 'lib/sablon/content.rb', line 72
def append_to(paragraph, display_node)
Nokogiri::XML.fragment(xml).children.reverse.each do |child|
paragraph.add_next_sibling child
end
paragraph.remove
end
|