python-prompt-toolkit v0.55 Release Notes

Release Date: 2016-01-03 // over 8 years ago
  • ๐Ÿ†• New features:

    • Implemented bracketed paste mode. (This allows much faster pasting, as well as pasting without going into paste mode. This makes sure that indentation in ptpython for instance is kept correctly.)
    • โž• Added support for italic output and blink. (For terminals that support it.)
    • Added get_horizontal_scroll, get_vertical_scroll and always_hide_cursor parameters to Window.
    • ๐Ÿ”จ Refactoring of the posix event loop. Better scheduling of all tasks/FDs to avoid starvation. (Everything should feel more responsive in high CPU situations.)
    • 0๏ธโƒฃ Added get_default_char function to TokenListControl.
    • AppendAutoSuggestion now accepts a token parameter.
    • ๐Ÿ‘Œ Support for ansi color names in styles.
    • Accept get_width/get_height parameters in Float.
    • โž• Added Output.write_raw and accept 'raw' parameter in CommandLineInterface.stdout_proxy.
    • ๐Ÿ‘ Better caching of tokens in TokenListControl.
    • โž• Add mouse support to TokenListControl.
    • Display "Window too small" when the window becomes too small.
    • โž• Added 'bell' function to Output.
    • Accept weights in HSplit/VSplit.
    • โž• Added Registry.remove_binding method to dynamically remove key bindings.
    • Added focus_on_click parameter to BufferControl.
    • Introduced BufferMapping class as a wrapper around the buffers dictionary. This one also contains the focus stack.
    • ๐Ÿ‘Œ Improved 'v' and 'V' key bindings. Allow switching between line and character selection modes.
    • โž• Added layout.highlighters. A new, much faster way to do selection and search highlighting.
    • ๐Ÿ‘‰ Make search_state dynamic for key bindings.
    • โž• Added 'sentence' option to WordCompleter.
    • ๐ŸŽ Cache Document.lines for better performance.
    • Implementation of BLOCK selections. (Cut, copy, paste.)
    • Accept a 'reserve_space_for_menu' parameter in the shortcuts. (This is an integer.)
    • ๐Ÿ‘Œ Support for 24bit true color on vt100 terminals.
    • โž• Added CommandLineInterface.on_invalidate event.
    • ๐Ÿ”– Added version to init.py.

    ๐Ÿ›  Fixes:

    • Always show cursor in the 'done' state.
    • ๐Ÿ‘ Allow HSplit to have zero children.
    • ๐Ÿ›  Bugfix for handling of backslash on Windows with some non-us keyboards. (Ptpython issue #28.)
    • Never render characters outside the visible screen region.
    • ๐Ÿ›  Fix in WordCompleter. When case insensitive and input contained uppercase.
    • Highlight search match when the cursor is at any position on the match. (not just the beginning.)

    Backwards-incompatible changes: (Most changes will probably not have an impact on external applications.)

    • ๐Ÿ’… Change in the Style API. This allows caching of Attrs in renderer and faster rendering. (Style now has a get_attrs_for_token instead of a get_token_to_attributes_dict method.)
    • โœ‚ Removed DefaultStyle. Created PygmentsStyle.from_defaults class method instead.
    • โœ‚ Removed AbortAction.IGNORE. This was ambiguous.
    • Accept 'cli' parameter in 'walk' and 'find_window_for_buffer_name'.
    • The focus stack is now stored in BufferMapping.
    • ViStateFilter and KeyBindingManager now accept a get_vi_state callable instead of vi_state itself. (This way a key bindings registry becomes stateless.)
    • ๐Ÿ—„ HighlightSearchProcessor and HighlightSelectionProcessor became deprecated. (Use highlighters instead.)