mne.viz.ui_events.publish#

mne.viz.ui_events.publish(fig, event, *, verbose=None)[source]#

Publish an event to all subscribers of the figure’s channel.

The figure’s event channel and all linked event channels are searched for subscribers to the given event. Each subscriber had provided a callback function when subscribing, so we call that.

Parameters:
figmatplotlib.figure.Figure | Figure3D

The figure that publishes the event.

eventUIEvent

Event to publish.

verbosebool | str | int | None

Control verbosity of the logging output. If None, use the default verbosity level. See the logging documentation and mne.verbose() for details. Should only be passed as a keyword argument.

Examples using mne.viz.ui_events.publish#

Using the event system to link figures

Using the event system to link figures