Class: String
- Inherits:
-
Object
- Object
- String
- Defined in:
- lib/notroff/text.rb,
lib/notroff/string_extensions.rb
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#indent_depth ⇒ Object
Return the number of leading blanks.
- #old_double_equals ⇒ Object
- #to_text ⇒ Object
Instance Method Details
#==(other) ⇒ Object
63 64 65 66 |
# File 'lib/notroff/text.rb', line 63 def ==(other) return self == other.string if other.kind_of?(Text) old_double_equals(other) end |
#indent_depth ⇒ Object
Return the number of leading blanks
3 4 5 |
# File 'lib/notroff/string_extensions.rb', line 3 def indent_depth /^ */.match(self).to_s.size end |
#old_double_equals ⇒ Object
61 |
# File 'lib/notroff/text.rb', line 61 alias_method :old_double_equals, :'==' |