IPython Documentation

Table Of Contents

Previous topic

Module: html.widgets.widget_selectioncontainer

Next topic

Module: kernel.adapter

This Page

Module: html.widgets.widget_string

String class.

Represents a unicode string using a widget.

4 Classes

class IPython.html.widgets.widget_string.HTML(value=None, **kwargs)

Bases: IPython.html.widgets.widget_string._String

Renders the string value as HTML.

class IPython.html.widgets.widget_string.Latex(value=None, **kwargs)

Bases: IPython.html.widgets.widget_string._String

Renders math inside the string value as Latex (requires $ $ or $$ $$ and similar latex tags).

class IPython.html.widgets.widget_string.Textarea(value=None, **kwargs)

Bases: IPython.html.widgets.widget_string._String

Multiline text area widget.

class IPython.html.widgets.widget_string.Text(*args, **kwargs)

Bases: IPython.html.widgets.widget_string._String

Single line textbox widget.

__init__(*args, **kwargs)
on_submit(callback, remove=False)

(Un)Register a callback to handle text submission.

Triggered when the user clicks enter.


callback: callable

Will be called with exactly one argument: the Widget instance

remove: bool (optional)

Whether to unregister the callback