------------------
* webhelpers.constants:
- Fix spelling of Massachusetts.
* webhelpers.feedgenerator:
- Sync with Django rev 11910. This adds GeoRSS and makes the API more
extensible, as well as fixing a few bugs.
(Re-added the Atom1 'published' property.)
(The 'generator' and 'source' properties were lost, but they weren't
working correctly anyway.)
GeoRSS usage: use the Geo\* classes and add ``geometry=(lat, lon)`` to
each news item. Other shapes and a (not yet implemented) Geometry class are
allowed; see the source.
* webhelpers.html:
- New ``HTML.cdata()`` method for producing "<!![CDATA[ ... ]]>" sections.
- The basic tag builders (``HTML.a()`` and ``HTML.tag("a")``) now have a
``_nl`` arg which, if true, inserts a newline between content elements
and at the end of the tag for readability. Example::
HTML.a("A", "B", href="/") => '<a href="/">AB</a>'
HTML.a("A", "B", href="/", _nl=True) => '<a href="/">\nA\nB\n</a>\n'
This does not affect HTML attributes nor the higher-level tag helpers.
The exact spacing is subject to change. The tag building code has been
refactored to accommodate this.
* webhelpers.html.tags:
- ``form()`` puts its hidden "_method" field in a '<div style="display:none">'
to conform to XHTML syntax. The style prevents the div from being displayed
or affecting the layout. A new arg ``hidden_fields`` may be a dict or
iterable of additional hidden fields, which will be added to the div.
- Set magic ID attribute in ``hidden`` helper to match behavior of the other
tag helpers.
- ``image()`` can now calculate the width and height automatically
from an image file, using either the PIL algorithm or the pure Python
algorithm in ``webhelpers.media``. It also logs the dimensions to the
debug log for troubleshooting.
* webhelpers.html.tools:
- Reimplement ``highlight()`` using the HTML builder. New arguments add
flexibility. Deprecate the ``highlighter`` argument, which creates tags
via string interpolation.
- Fixed ``auto_link()`` to parse slash characters in query string.
Patch by hanula; Bitbucket issue 10.
- Fix HTML overescaping and underescaping in auto_link(). Patch by Marius
Gedminas. A parsing bug remains:
http://pylonshq.com/project/pylonshq/ticket/657
* webhelpers.markdown / webhelpers.html.converters:
- ``webhelpers.markdown`` will not be upgraded to the version 2 series but
will remain at 1.7. Users who want the latest bugfixes and extensions
should download the full Markdown package or the alternative Markdown2
from PyPI.
- The ``markdown()`` helper in
``webhelpers.html.converters`` now has support for external Markdown
implementations. You can pass a specific module via the ``markdown``
argument, otherwise it will attempt to import ``markdown`` or fall back
to ``webhelpers.markdown``.
- To see which version is autoloaded,
call ``_get_markdown_module()`` and inspect the ``.__file__``,
``.version``, and/or ``.version_info`` attributes of the return value.
* webhelpers.media:
- Bugfix in ``get_dimensions_pil``.
* webhelpers.paginate:
- Change for SQLAlchemy 0.6. (bug 11)
* webhelpers.pylonslib:
- Fix HTML overescaping. Patch by Marius Gedminas.