sealed trait Attr extends Attrs
Represents a single, atomic ANSI escape sequence that results in a
color, background or decoration being added to the output. May or may not
have an escape sequence (escapeOpt
), as some attributes (e.g. Bold.Off)
are not widely/directly supported by terminals and so fansi.Str supports them
by rendering a hard Attr.Reset and then re-rendering other Attrs that are
active.
Many of the codes were stolen shamelessly from
http://misc.flogisoft.com/bash/tip_colors_and_formatting
- Alphabetic
- By Inheritance
- Attr
- Attrs
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Abstract Value Members
- abstract def applyMask: Long
Which bits of the Str.State integer these Attrs will set to
1
when it is applied - abstract def escapeOpt: Option[String]
escapeOpt the actual ANSI escape sequence corresponding to this Attr
- abstract def name: String
- abstract def resetMask: Long
Which bits of the Str.State integer these Attrs will override when it is applied
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##(): Int
- Definition Classes
- AnyRef → Any
- def ++(other: Attrs): Attrs
Combine this fansi.Attr with one or more other fansi.Attrs so they can be passed around together
Combine this fansi.Attr with one or more other fansi.Attrs so they can be passed around together
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def apply(s: Str): Str
Apply these Attrs to the given fansi.Str, making it take effect across the entire length of that string.
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def attrs: Seq[Attr]
- def clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws(classOf[java.lang.CloneNotSupportedException])
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- def transform(state: State): Long
Apply the current Attrs to the Str.State integer, modifying it to represent the state after all changes have taken effect
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws(classOf[java.lang.InterruptedException])