Module: core.excolors — IPython 2.3.1 documentation

### Navigation

- index
- modules |
- modules |
- next |
- previous |
- home|
- search|
- documentation »
- The IPython API »

# Module: `core.excolors`

Color schemes for exception handling code in IPython.

## 1 Function

`IPython.core.excolors.` `exception_colors`()

  Return a color table with fields for exception reporting.

  The table is an instance of ColorSchemeTable with schemes added for ‘Linux’, ‘LightBG’ and ‘NoColor’ and fields for exception handling filled in.

  Examples:

      >>> ec = exception_colors()
      >>> ec.active_scheme_name
      ''
      >>> print(ec.active_colors)
      None

  Now we activate a color scheme: >>> ec.set_active_scheme(‘NoColor’) >>> ec.active_scheme_name ‘NoColor’ >>> sorted(ec.active_colors.keys()) [‘Normal’, ‘caret’, ‘em’, ‘excName’, ‘filename’, ‘filenameEm’, ‘line’, ‘lineno’, ‘linenoEm’, ‘name’, ‘nameEm’, ‘normalEm’, ‘topline’, ‘vName’, ‘val’, ‘valEm’]

### Navigation

- index
- modules |
- modules |
- next |
- previous |
- home|
- search|
- documentation »
- The IPython API »