[Python-modules-commits] [python-mplexporter] 80/135: Changed format for acquiring props['fontsize'] for x/y axis objects.

Wolfgang Borgert debacle at moszumanska.debian.org
Tue Sep 23 21:19:06 UTC 2014


This is an automated email from the git hooks/post-receive script.

debacle pushed a commit to branch master
in repository python-mplexporter.

commit 59d155b679cde940576247f33cf21d8c366bf6a6
Author: theengineear <andseier at gmail.com>
Date:   Tue Mar 4 17:03:30 2014 -0800

    Changed format for acquiring props['fontsize'] for x/y axis objects.
    
    As per our messages on GitHub.
---
 mplexporter/utils.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/mplexporter/utils.py b/mplexporter/utils.py
index a9b8038..529eaa3 100644
--- a/mplexporter/utils.py
+++ b/mplexporter/utils.py
@@ -219,9 +219,9 @@ def get_axis_properties(axis):
     props['scale'] = axis.get_scale()
 
     # Get major tick label size (assumes that's all we really care about!)
-    sizes = [tick.get_fontsize() for tick in axis.get_ticklabels()]
-    if sizes[1:] == sizes[:-1]:
-        props['fontsize'] = sizes[0]
+    labels = axis.get_ticklabels()
+    if labels:
+        props['fontsize'] = labels[0].get_fontsize()
     else:
         props['fontsize'] = None
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/python-mplexporter.git



More information about the Python-modules-commits mailing list