This PR updates humanfriendly from 4.12.1 to 4.16.1.
Changelog
### 4.16.1
```
------------------------------
Yet another ANSI to HTML improvement: Emit an ANSI reset code before emitting
ANSI escape sequences that change styles, so that previously activated styles
don't inappropriately "leak through" to the text that follows.
.. _Release 4.16.1: https://github.com/xolox/python-humanfriendly/compare/4.16...4.16.1
```
### 4.16
```
----------------------------
More HTML to ANSI improvements:
- Added ``humanfriendly.text.compact_empty_lines()`` function.
- Enable optional ``html_to_ansi(data[, callback])`` argument.
- Added a code sample and screenshot to the ``HTMLConverter`` documentation.
- Emit vertical whitespace for block tags like ``<div>``, ``<p>`` and ``<pre>``
and post-process the generated output in ``__call__()`` to compact empty lines.
- Don't pre-process preformatted text using the user defined text callback.
- Improve robustness against malformed HTML (previously an ``IndexError`` would
be raised when a closing ``</a>`` tag was encountered without a corresponding
opening ``<a>`` tag).
- Emit an ANSI reset code when ``HTMLConverter.close()`` is called and a style
is still active (improves robustness against malformed HTML).
.. _Release 4.16: https://github.com/xolox/python-humanfriendly/compare/4.15.1...4.16
```
### 4.15.1
```
------------------------------
Bug fixes for HTML to ANSI conversion.
HTML entities were being omitted from conversion because I had neglected to
define the ``handle_charref()`` and ``handle_entityref()`` methods (whose
definitions are so conveniently given in the documentation of the
``HTMLParser`` class 😇).
.. _Release 4.15.1: https://github.com/xolox/python-humanfriendly/compare/4.15...4.15.1
```
### 4.15
```
----------------------------
Added the ``ansi_to_html()`` function which is a shortcut for the
``HTMLConverter`` class that's based on ``html.parser.HTMLParser``.
This new functionality converts HTML with simple text formatting tags like
``<b>`` for bold, ``<i>`` for italic, ``<u>`` for underline, ``<span>`` for
colors, etc. to text with ANSI escape sequences.
I'm still working on that awesome new project, this functionality was born
there but seemed like a useful addition to the ``humanfriendly`` package, given
the flexibility that this provides 😇.
.. _Release 4.15: https://github.com/xolox/python-humanfriendly/compare/4.14...4.15
```
### 4.14
```
----------------------------
Support for 24-bit (RGB) terminal colors. Works by accepting a tuple or
list with three integers representing an RGB (red, green, blue) color.
.. _Release 4.14: https://github.com/xolox/python-humanfriendly/compare/4.13...4.14
```
### 4.13
```
----------------------------
Support for *italic* text rendering on the terminal.
I'm working on an awesome new project that's almost ready to publish, but then
I noticed that I couldn't render italic text on the terminal using the
humanfriendly package. I checked and sure enough my terminal supported it just
fine, so I didn't see any reason not to fix this now 😇.
.. _Release 4.13: https://github.com/xolox/python-humanfriendly/compare/4.12.1...4.13
```
Links
- PyPI: https://pypi.org/project/humanfriendly
- Changelog: https://pyup.io/changelogs/humanfriendly/
- Docs: https://humanfriendly.readthedocs.io
This PR updates humanfriendly from 4.12.1 to 4.16.1.
Changelog
### 4.16.1 ``` ------------------------------ Yet another ANSI to HTML improvement: Emit an ANSI reset code before emitting ANSI escape sequences that change styles, so that previously activated styles don't inappropriately "leak through" to the text that follows. .. _Release 4.16.1: https://github.com/xolox/python-humanfriendly/compare/4.16...4.16.1 ``` ### 4.16 ``` ---------------------------- More HTML to ANSI improvements: - Added ``humanfriendly.text.compact_empty_lines()`` function. - Enable optional ``html_to_ansi(data[, callback])`` argument. - Added a code sample and screenshot to the ``HTMLConverter`` documentation. - Emit vertical whitespace for block tags like ``<div>``, ``<p>`` and ``<pre>`` and post-process the generated output in ``__call__()`` to compact empty lines. - Don't pre-process preformatted text using the user defined text callback. - Improve robustness against malformed HTML (previously an ``IndexError`` would be raised when a closing ``</a>`` tag was encountered without a corresponding opening ``<a>`` tag). - Emit an ANSI reset code when ``HTMLConverter.close()`` is called and a style is still active (improves robustness against malformed HTML). .. _Release 4.16: https://github.com/xolox/python-humanfriendly/compare/4.15.1...4.16 ``` ### 4.15.1 ``` ------------------------------ Bug fixes for HTML to ANSI conversion. HTML entities were being omitted from conversion because I had neglected to define the ``handle_charref()`` and ``handle_entityref()`` methods (whose definitions are so conveniently given in the documentation of the ``HTMLParser`` class 😇). .. _Release 4.15.1: https://github.com/xolox/python-humanfriendly/compare/4.15...4.15.1 ``` ### 4.15 ``` ---------------------------- Added the ``ansi_to_html()`` function which is a shortcut for the ``HTMLConverter`` class that's based on ``html.parser.HTMLParser``. This new functionality converts HTML with simple text formatting tags like ``<b>`` for bold, ``<i>`` for italic, ``<u>`` for underline, ``<span>`` for colors, etc. to text with ANSI escape sequences. I'm still working on that awesome new project, this functionality was born there but seemed like a useful addition to the ``humanfriendly`` package, given the flexibility that this provides 😇. .. _Release 4.15: https://github.com/xolox/python-humanfriendly/compare/4.14...4.15 ``` ### 4.14 ``` ---------------------------- Support for 24-bit (RGB) terminal colors. Works by accepting a tuple or list with three integers representing an RGB (red, green, blue) color. .. _Release 4.14: https://github.com/xolox/python-humanfriendly/compare/4.13...4.14 ``` ### 4.13 ``` ---------------------------- Support for *italic* text rendering on the terminal. I'm working on an awesome new project that's almost ready to publish, but then I noticed that I couldn't render italic text on the terminal using the humanfriendly package. I checked and sure enough my terminal supported it just fine, so I didn't see any reason not to fix this now 😇. .. _Release 4.13: https://github.com/xolox/python-humanfriendly/compare/4.12.1...4.13 ```Links
- PyPI: https://pypi.org/project/humanfriendly - Changelog: https://pyup.io/changelogs/humanfriendly/ - Docs: https://humanfriendly.readthedocs.io