IPython Documentation

Table Of Contents

Previous topic

Module: qt.console.rich_ipython_widget

Next topic

Module: qt.inprocess

This Page


This documentation is for an old version of IPython. You can find docs for newer versions here.

Module: qt.console.styles

Style utilities, templates, and defaults for syntax highlighting widgets.

5 Functions


Convert a hex color to rgb integer tuple.


Check whether a color is ‘dark’.

Currently, this is simply whether the luminance is <50%


Guess whether the background of the style with name ‘stylename’ counts as ‘dark’.


Construct the keys to be used building the base stylesheet from a templatee.

IPython.qt.console.styles.sheet_from_template(name, colors='lightbg')

Use one of the base templates, and set bg/fg/select colors.