introduced: 24-bit color support, detected by
term.number_of_colors == 1 << 24, and 24-bit color foreground method
color_rgb()and background method
on_color_rgb(), as well as 676 common X11 color attribute names are now possible, such as
move_right()which are strings that move the cursor one cell in the respective direction, are now also callables for moving n cells to the given direction, such as
ValueError: I/O operation on closed fileon
sys.stdinin multiprocessing environments, where the keyboard wouldn’t work, anyway.
bugfix: prevent error condition,
ValueError: underlying buffer has been detachedin rare conditions where sys.__stdout__ has been detached in test frameworks. #126.
FormattingOtherStringmay be pickled.
UTF-8for keyboard if input encoding cannot be determined.
dimare no longer “compoundable” with colors, such as in phrase
Terminal.blue_subscript('a'). These attributes are not typically supported, anyway. Use Unicode text or 256 or 24-bit color codes instead.
deprecated: additional key names, such as
KEY_TAB, are no longer “injected” into the curses module namespace.
deprecated: using argument
kbhit(), behavior is as though such value is always True since 1.9.
bugfix: Now imports on 3.10+
bugfix: Fix detection of shift+arrow keys when using tmux. #178.
blessed.sequences.measure_lengthfunction superseded by
deprecated: warnings about “binary-packed capabilities” are no longer emitted on strange terminal types, making best effort.
bugfix: length of simple SGR reset sequence
\x1b[mwas not correctly determined on all terminal types, #45.
_intr_continuearguments introduced in 1.8 are now marked deprecated in 1.10: beginning with python 3.5, the default behavior is as though this argument is always True, PEP-475, blessed does the same.
'tparm() returned NULL': this occurs on win32 or other platforms using a limited curses implementation, such as PDCurses, where
curses.tparm()is not implemented, or no terminal capability database is available.
bugfix: translate keypad application keys correctly.
enhancement: no longer depend on the ‘2to3’ tool for python 3 support.
cnorm(hide_cursor, normal_hide) to work with terminal-type ansi by emulating support by proxy.
enhancement: new public attribute:
kind: the very same as given
Terminal.__init__.kindkeyword argument. Or, when not given, determined by and equivalent to the
enhancement: export keyboard-read function as public method
getch(), so that it may be overridden by custom terminal implementers.
vpa(move_x, move_y) to work on tmux(1) or screen(1) by emulating support by proxy.
enhancement: better support for detecting the length or sequences of externally-generated ecma-48 codes when using
locale.getpreferredencoding()returns empty string or an encoding that is not valid for
codecs.getincrementaldecoder, fallback to ASCII and emit a warning.
bugfix: allow ~.inkey and related to be called without a keyboard.
sys.stdoutis not a tty, making
\x1bOH(KEY_HOME) was incorrectly mapped as KEY_LEFT.
inkey(), which will return one or more characters received by the keyboard as a unicode sequence, with additional attributes
name. This allows application keys (such as the up arrow, or home key) to be detected. Optional value
timeoutallows for timed poll.
wrap()method. Allows text containing sequences to be word-wrapped without breaking mid-sequence, honoring their printable width.
strip(), strips all sequences and whitespace.
strip_seqs()strip only sequences.
bugfix: cannot call
curses.setupterm()more than once per process (from
Terminal.__init__()): Previously, blessed pretended to support several instances of different Terminal
kind, but was actually using the
kindspecified by the first instantiation of
Terminal. A warning is now issued. Although this is misbehavior is still allowed, a
warnings.WarningMessageis now emitted to notify about subsequent terminal misbehavior.
bugfix: allow unsupported terminal capabilities to be callable just as supported capabilities, so that the return value of
color(n) may be called on terminals without color capabilities.
bugfix: for terminals without underline, such as vt220,
'text' + term.normal. Now it emits only
enhancement: some attributes are now properties, raise exceptions when assigned.
enhancement: pypy is now a supported python platform implementation.
enhancement: removed pokemon
enhancement: do not ignore
curses.errorexceptions, unhandled curses errors are legitimate errors and should be reported as a bug.
enhancement: converted nose tests to pytest, merged travis and tox.
enhancement: pytest fixtures, paired with a new
@as_subprocessdecorator are used to test a multitude of terminal types.
enhancement: test accessories
@as_subprocessresolves various issues with different terminal types that previously went untested.
deprecation: python2.5 is no longer supported (as tox does not supported).
Clean up fabfile, removing the redundant
Add Travis support.
python setup.py testwork without spurious errors on 2.6.
Work around a tox parsing bug in its config file.
Make context managers clean up after themselves even if there’s an exception (Vitja Makarov #29 <https://github.com/erikrose/blessings/pull/29>).
Parameterizing a capability no longer crashes when there is no tty (<Vitja Makarov #31 <https://github.com/erikrose/blessings/pull/31>)
Add syntactic sugar for cursor visibility control and single-space-movement capabilities.
location()context manager for restoring cursor position after a series of manual movements.
Fix a bug in which
location()that wouldn’t do anything when passed zeros.
Allow tests to be run with
python setup.py test.
number_of_colors, which tells you how many colors the terminal supports.
on_color(n) callable to wrap a string, like the named colors can. Also, make them both fall back to the
setbcapabilities (like the named colors do) if the termcap entries for
setabare not available.
colorto act as an unparametrized string, not just a callable.
Made caching simpler and slightly more efficient.
Updated docs to reflect that terminal addressing (as in
location()) is 0-based.
Added support for Python 3! We need 3.2.3 or greater, because the curses library couldn’t decide whether to accept strs or bytes before that (https://bugs.python.org/issue10570).
Everything that comes out of the library is now unicode. This lets us support Python 3 without making a mess of the code, and Python 2 should continue to work unless you were testing types (and badly). Please file a bug if this causes trouble for you.
Changed to the MIT License for better world domination.
Added Sphinx docs.
Added nicely named attributes for colors.
Introduced compound formatting.
Added wrapper behavior for styling and colors.
Let you force capabilities to be non-empty, even if the output stream is not a terminal.
is_a_ttyto determine whether the output stream is a terminal.
Sugared the remaining interesting string capabilities.
location()to operate on just an x or y coordinate.
Extracted Blessed from nose-progressive.