Class: RubyXL::Text
- Inherits:
-
OOXMLObject
- Object
- OOXMLObject
- RubyXL::Text
- Defined in:
- lib/rubyXL/objects/text.rb
Overview
Instance Method Summary collapse
Methods included from OOXMLObjectInstanceMethods
#==, included, #index_in_collection, #initialize, #write_xml
Instance Method Details
#before_write_xml ⇒ Object
14 15 16 17 |
# File 'lib/rubyXL/objects/text.rb', line 14 def before_write_xml self.xml_space = (value.is_a?(String) && ((value =~ /\A\s/) || (value =~ /\s\Z/) || value.include?("\n"))) ? 'preserve' : nil true end |
#to_s ⇒ Object
19 20 21 |
# File 'lib/rubyXL/objects/text.rb', line 19 def to_s value.to_s end |