Class: Kramdown::ANSI::Width::Token
- Inherits:
-
Data
- Object
- Data
- Kramdown::ANSI::Width::Token
- Defined in:
- lib/kramdown/ansi/width.rb
Overview
A frozen data record for a single token in the truncate scan.
type is :esc (ANSI escape, zero display width) or
:txt (visible character, display width from
Unicode::DisplayWidth).
value is the raw matched substring.
length is the display width in terminal columns (0 for escapes).
Instance Attribute Summary collapse
-
#length ⇒ Object
readonly
Returns the value of attribute length.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Attribute Details
#length ⇒ Object (readonly)
Returns the value of attribute length
106 107 108 |
# File 'lib/kramdown/ansi/width.rb', line 106 def length @length end |
#type ⇒ Object (readonly)
Returns the value of attribute type
106 107 108 |
# File 'lib/kramdown/ansi/width.rb', line 106 def type @type end |
#value ⇒ Object (readonly)
Returns the value of attribute value
106 107 108 |
# File 'lib/kramdown/ansi/width.rb', line 106 def value @value end |