Revision: 8883 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8883&view=rev Author: jswhit Date: 2011-01-04 20:36:21 +0000 (Tue, 04 Jan 2011)
Log Message: ----------- make celestial=True imply resolution=None, labelstyle="+/=" by default. Modified Paths: -------------- trunk/toolkits/basemap/lib/mpl_toolkits/basemap/__init__.py Modified: trunk/toolkits/basemap/lib/mpl_toolkits/basemap/__init__.py =================================================================== --- trunk/toolkits/basemap/lib/mpl_toolkits/basemap/__init__.py 2011-01-04 20:24:12 UTC (rev 8882) +++ trunk/toolkits/basemap/lib/mpl_toolkits/basemap/__init__.py 2011-01-04 20:36:21 UTC (rev 8883) @@ -257,6 +257,7 @@ ``N``, ``NW``, and ``W``. celestial use astronomical conventions for longitude (i.e. negative longitudes to the east of 0). Default False. + Implies ``resolution=None``. ax set default axes instance (default None - matplotlib.pyplot.gca() may be used to get the current axes instance). @@ -773,7 +774,10 @@ # set defaults for area_thresh. self.resolution = resolution - if area_thresh is None and resolution is not None: + # celestial=True implies resolution=None (no coastlines). + if self.celestial: + self.resolution=None + if area_thresh is None and self.resolution is not None: if resolution == 'c': area_thresh = 10000. elif resolution == 'l': @@ -857,7 +861,7 @@ # currently only used in is_land method. self.landpolygons=[] self.lakepolygons=[] - if resolution is not None and len(self.coastpolygons) > 0: + if self.resolution is not None and len(self.coastpolygons) > 0: #self.islandinlakepolygons=[] #self.lakeinislandinlakepolygons=[] x, y = zip(*self.coastpolygons) @@ -1840,6 +1844,9 @@ associated with each parallel. Deleting an item from the dictionary removes the corresponding parallel from the plot. """ + # if celestial=True, don't use "N" and "S" labels. + if labelstyle is None and self.celestial: + labelstyle="+/-" # get current axes instance (if none specified). ax = ax or self._check_ax() # don't draw meridians past latmax, always draw parallel at latmax. @@ -2135,6 +2142,9 @@ associated with each meridian. Deleting an item from the dictionary removes the correpsonding meridian from the plot. """ + # if celestial=True, don't use "E" and "W" labels. + if labelstyle is None and self.celestial: + labelstyle="+/-" # get current axes instance (if none specified). ax = ax or self._check_ax() # don't draw meridians past latmax, always draw parallel at latmax. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Matplotlib-checkins mailing list Matplotlib-checkins@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins