Browse Source

Fix transposable_node in case all attributes are not there.

pull/290/head 2.0.10
Florian Mounier 9 years ago
parent
commit
ba2f32d00b
  1. 8
      docs/changelog.rst
  2. 2
      pygal/__init__.py
  3. 9
      pygal/svg.py

8
docs/changelog.rst

@ -2,11 +2,17 @@
Changelog
=========
2.0.10
======
* Fix transposable_node in case all attributes are not there. (thanks @yobuntu).
2.0.9
=====
* Add `dynamic_print_values` to show print_values on legend hover. (#279)
* Fix unparse_color for python 3.5+ compatibility (thanks felixonmars, sjourdois)
* Fix unparse_color for python 3.5+ compatibility (thanks @felixonmars, @sjourdois)
* Process major labels as labels. (#263)
* Fix labels rotation > 180 (#257)
* Fix secondary axis

2
pygal/__init__.py

@ -24,7 +24,7 @@ and the maps extensions namespace module.
"""
__version__ = '2.0.9'
__version__ = '2.0.10'
import pkg_resources
import sys

9
pygal/svg.py

@ -205,7 +205,14 @@ class Svg(object):
for key1, key2 in (('x', 'y'), ('width', 'height'), ('cx', 'cy')):
attr1 = extras.get(key1, None)
attr2 = extras.get(key2, None)
extras[key1], extras[key2] = attr2, attr1
if attr2:
extras[key1] = attr2
elif attr1:
del extras[key1]
if attr1:
extras[key2] = attr1
elif attr2:
del extras[key2]
return self.node(parent, tag, attrib, **extras)
def serie(self, serie):

Loading…
Cancel
Save