Warning
This documentation covers a development version of IPython. The development version may differ significantly from the latest stable release.
Important
This documentation covers IPython versions 6.0 and higher. Beginning with version 6.0, IPython stopped supporting compatibility with Python versions lower than 3.3 including all versions of Python 2.7.
If you are looking for an IPython version compatible with Python 2.7, please use the IPython 5.x LTS release and refer to its documentation (LTS is the long term support release).
Module: terminal.shortcuts.filters
¶
Filters restricting scope of IPython Terminal shortcuts.
1 Class¶
- class IPython.terminal.shortcuts.filters.PassThrough¶
Bases:
Filter
A filter allowing to implement pass-through behaviour of keybindings.
Prompt toolkit key processor dispatches only one event per binding match, which means that adding a new shortcut will suppress the old shortcut if the keybindings are the same (unless one is filtered out).
To stop a shortcut binding from suppressing other shortcuts: - add the
pass_through
filter to list of filter, and - callpass_through.reply(event)
in the shortcut handler.- __init__()¶
13 Functions¶
- IPython.terminal.shortcuts.filters.has_focus(value: str | Buffer | UIControl | Container | MagicContainer)¶
Wrapper around has_focus adding a nice
__name__
to tester function
- IPython.terminal.shortcuts.filters.ebivim() bool ¶
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.
- IPython.terminal.shortcuts.filters.supports_suspend() bool ¶
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.
- IPython.terminal.shortcuts.filters.auto_match() bool ¶
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.
- IPython.terminal.shortcuts.filters.all_quotes_paired(quote, buf)¶
- IPython.terminal.shortcuts.filters.following_text(pattern)¶
- IPython.terminal.shortcuts.filters.not_inside_unclosed_string() bool ¶
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.
- IPython.terminal.shortcuts.filters.readline_like_completions() bool ¶
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.
- IPython.terminal.shortcuts.filters.is_windows_os() bool ¶
Turn any callable into a Filter. The callable is supposed to not take any arguments.
This can be used as a decorator:
@Condition def feature_is_active(): # `feature_is_active` becomes a Filter. return True
- Parameters:
func – Callable which takes no inputs and returns a boolean.