Skip to content

Text Colors and Attributes

Anton Shvetz edited this page Feb 20, 2016 · 3 revisions
  • $self->setForeground($color)

    Set foreground color to $color.

  • $self->setBackground($color)

    Set background color to $color.

  • $self->setColor($foreground, $background)

    Set both colors to $foreground and $background.

  • $self->setStandout($on)

    Set or clear standout mode depending on the value of $on switch.

  • $self->setUnderline($on)

    Set or clear underline mode depending on the value of $on switch.

  • $self->setReverse($on)

    Set or clear reverse mode depending on the value of $on switch.

  • $self->setBlink($on)

    Set or clear blink mode depending on the value of $on switch.h.

  • $self->setAttribute($attribute)

    Set or clear attributes mode depending on the value of $attribute mask. Valid masks are ATTR_NORMAL, ATTR_STANDOUT, ATTR_UNDERLINE, ATTR_REVERSE, ATTR_BLINK, ATTR_DIM, ATTR_BOLD, ATTR_ALTCHARSET, ATTR_INVISIBLE, ATTR_PROTECT.

Clone this wiki locally