From: <lee...@us...> - 2009-12-11 16:58:01
|
Revision: 8023 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8023&view=rev Author: leejjoon Date: 2009-12-11 16:57:53 +0000 (Fri, 11 Dec 2009) Log Message: ----------- add ArrowStyle |-| Modified Paths: -------------- trunk/matplotlib/examples/pylab_examples/fancyarrow_demo.py trunk/matplotlib/lib/matplotlib/patches.py Modified: trunk/matplotlib/examples/pylab_examples/fancyarrow_demo.py =================================================================== --- trunk/matplotlib/examples/pylab_examples/fancyarrow_demo.py 2009-12-11 16:57:46 UTC (rev 8022) +++ trunk/matplotlib/examples/pylab_examples/fancyarrow_demo.py 2009-12-11 16:57:53 UTC (rev 8023) @@ -4,7 +4,7 @@ styles = mpatches.ArrowStyle.get_styles() ncol=2 -nrow = len(styles) // ncol + 1 +nrow = (len(styles)+1) // ncol figheight = (nrow+0.5) fig1 = plt.figure(1, (4.*ncol/1.5, figheight/1.5)) fontsize = 0.2 * 70 @@ -15,13 +15,19 @@ ax.set_xlim(0, 4*ncol) ax.set_ylim(0, figheight) +def to_texstring(s): + s = s.replace("<", r"$<$") + s = s.replace(">", r"$>$") + s = s.replace("|", r"$|$") + return s + for i, (stylename, styleclass) in enumerate(sorted(styles.items())): x = 3.2 + (i//nrow)*4 y = (figheight - 0.7 - i%nrow) # /figheight p = mpatches.Circle((x, y), 0.2, fc="w") ax.add_patch(p) - ax.annotate(stylename, (x, y), + ax.annotate(to_texstring(stylename), (x, y), (x-1.2, y), #xycoords="figure fraction", textcoords="figure fraction", ha="right", va="center", Modified: trunk/matplotlib/lib/matplotlib/patches.py =================================================================== --- trunk/matplotlib/lib/matplotlib/patches.py 2009-12-11 16:57:46 UTC (rev 8022) +++ trunk/matplotlib/lib/matplotlib/patches.py 2009-12-11 16:57:53 UTC (rev 8023) @@ -3299,6 +3299,41 @@ _style_list["-["] = BracketB + class BarAB(_Bracket): + """ + An arrow with a bracket(]) at both ends. + """ + + def __init__(self, + widthA=1., angleA=None, + widthB=1., angleB=None): + """ + *widthA* + width of the bracket + + *lengthA* + length of the bracket + + *angleA* + angle between the bracket and the line + + *widthB* + width of the bracket + + *lengthB* + length of the bracket + + *angleB* + angle between the bracket and the line + """ + + super(ArrowStyle.BarAB, self).__init__(True, True, \ + widthA=widthA, lengthA=0, angleA=angleA, + widthB=widthB, lengthB=0, angleB=angleB) + + _style_list["|-|"] = BarAB + + class Simple(_Base): """ A simple arrow. Only works with a quadratic bezier curve. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jo...@us...> - 2009-12-13 12:06:16
|
Revision: 8026 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8026&view=rev Author: jouni Date: 2009-12-13 12:06:07 +0000 (Sun, 13 Dec 2009) Log Message: ----------- Address mathtext problem with non-BMP characters: http://thread.gmane.org/gmane.comp.python.matplotlib.general/19963/focus=19978 Modified Paths: -------------- trunk/matplotlib/doc/users/mathtext.rst trunk/matplotlib/lib/matplotlib/mathtext.py Modified: trunk/matplotlib/doc/users/mathtext.rst =================================================================== --- trunk/matplotlib/doc/users/mathtext.rst 2009-12-12 18:24:54 UTC (rev 8025) +++ trunk/matplotlib/doc/users/mathtext.rst 2009-12-13 12:06:07 UTC (rev 8026) @@ -23,6 +23,13 @@ customization variable ``mathtext.fontset`` (see :ref:`customizing-matplotlib`) +.. note:: + On `"narrow" <http://wordaligned.org/articles/narrow-python>`_ builds + of Python, if you use the STIX fonts you should also set + ``ps.fonttype`` and ``pdf.fonttype`` to 3 (the default), not 42. + Otherwise `some characters will not be visible + <http://thread.gmane.org/gmane.comp.python.matplotlib.general/19963/focus=19978>`_. + Here is a simple example:: # plain text Modified: trunk/matplotlib/lib/matplotlib/mathtext.py =================================================================== --- trunk/matplotlib/lib/matplotlib/mathtext.py 2009-12-12 18:24:54 UTC (rev 8025) +++ trunk/matplotlib/lib/matplotlib/mathtext.py 2009-12-13 12:06:07 UTC (rev 8026) @@ -82,6 +82,14 @@ TeX/Type1 symbol"""%locals() raise ValueError, message +def unichr_safe(index): + """Return the Unicode character corresponding to the index, +or the replacement character if this is a narrow build of Python +and the requested character is outside the BMP.""" + try: + return unichr(index) + except ValueError: + return unichr(0xFFFD) class MathtextBackend(object): """ @@ -321,7 +329,8 @@ def render_glyph(self, ox, oy, info): oy = self.height - oy + info.offset - thetext = unichr(info.num) + thetext = unichr_safe(info.num) + self.svg_glyphs.append( (info.font, info.fontsize, thetext, ox, oy, info.metrics)) @@ -351,7 +360,7 @@ def render_glyph(self, ox, oy, info): oy = self.height - oy + info.offset - thetext = unichr(info.num) + thetext = unichr_safe(info.num) self.glyphs.append( (info.font, info.fontsize, thetext, ox, oy)) @@ -379,7 +388,7 @@ def render_glyph(self, ox, oy, info): oy = oy - info.offset - self.height - thetext = unichr(info.num) + thetext = unichr_safe(info.num) self.glyphs.append( (info.font, info.fontsize, thetext, ox, oy)) @@ -997,7 +1006,7 @@ cached_font = self._get_font(i) glyphindex = cached_font.charmap.get(uniindex) if glyphindex is not None: - alternatives.append((i, unichr(uniindex))) + alternatives.append((i, unichr_safe(uniindex))) # The largest size of the radical symbol in STIX has incorrect # metrics that cause it to be disconnected from the stem. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <as...@us...> - 2009-12-15 02:57:56
|
Revision: 8034 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8034&view=rev Author: astraw Date: 2009-12-15 02:57:46 +0000 (Tue, 15 Dec 2009) Log Message: ----------- Add patch_artist kwarg to boxplot Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/examples/pylab_examples/boxplot_demo2.py trunk/matplotlib/lib/matplotlib/axes.py trunk/matplotlib/lib/matplotlib/pyplot.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-15 02:57:32 UTC (rev 8033) +++ trunk/matplotlib/CHANGELOG 2009-12-15 02:57:46 UTC (rev 8034) @@ -1,3 +1,6 @@ +2009-12-14 Add patch_artist kwarg to boxplot, but keep old default. + Convert boxplot_demo2.py to use the new patch_artist. - ADS + 2009-12-06 axes_grid: reimplemented AxisArtist with FloatingAxes support. Added new examples. - JJL Modified: trunk/matplotlib/examples/pylab_examples/boxplot_demo2.py =================================================================== --- trunk/matplotlib/examples/pylab_examples/boxplot_demo2.py 2009-12-15 02:57:32 UTC (rev 8033) +++ trunk/matplotlib/examples/pylab_examples/boxplot_demo2.py 2009-12-15 02:57:46 UTC (rev 8034) @@ -42,8 +42,8 @@ ax1 = fig.add_subplot(111) plt.subplots_adjust(left=0.075, right=0.95, top=0.9, bottom=0.25) -bp = plt.boxplot(data, notch=0, sym='+', vert=1, whis=1.5) -plt.setp(bp['boxes'], color='black') +bp = plt.boxplot(data, notch=0, sym='+', vert=1, whis=1.5, patch_artist=True) +plt.setp(bp['boxes'], edgecolor='black') plt.setp(bp['whiskers'], color='black') plt.setp(bp['fliers'], color='red', marker='+') @@ -64,25 +64,12 @@ medians = range(numBoxes) for i in range(numBoxes): box = bp['boxes'][i] - boxX = [] - boxY = [] - for j in range(5): - boxX.append(box.get_xdata()[j]) - boxY.append(box.get_ydata()[j]) - boxCoords = zip(boxX,boxY) - # Alternate between Dark Khaki and Royal Blue k = i % 2 - boxPolygon = Polygon(boxCoords, facecolor=boxColors[k]) - ax1.add_patch(boxPolygon) - # Now draw the median lines back over what we just filled in + # Set the box colors + box.set_facecolor(boxColors[k]) + # Now get the medians med = bp['medians'][i] - medianX = [] - medianY = [] - for j in range(2): - medianX.append(med.get_xdata()[j]) - medianY.append(med.get_ydata()[j]) - plt.plot(medianX, medianY, 'k') - medians[i] = medianY[0] + medians[i] = med.get_ydata()[0] # Finally, overplot the sample averages, with horixzontal alignment # in the center of each box plt.plot([np.average(med.get_xdata())], [np.average(data[i])], Modified: trunk/matplotlib/lib/matplotlib/axes.py =================================================================== --- trunk/matplotlib/lib/matplotlib/axes.py 2009-12-15 02:57:32 UTC (rev 8033) +++ trunk/matplotlib/lib/matplotlib/axes.py 2009-12-15 02:57:46 UTC (rev 8034) @@ -21,6 +21,7 @@ import matplotlib.legend as mlegend import matplotlib.lines as mlines import matplotlib.mlab as mlab +import matplotlib.path as mpath import matplotlib.patches as mpatches import matplotlib.spines as mspines import matplotlib.quiver as mquiver @@ -4892,12 +4893,12 @@ return (l0, caplines, barcols) def boxplot(self, x, notch=0, sym='b+', vert=1, whis=1.5, - positions=None, widths=None): + positions=None, widths=None, patch_artist=False): """ call signature:: boxplot(x, notch=0, sym='+', vert=1, whis=1.5, - positions=None, widths=None) + positions=None, widths=None, patch_artist=False) Make a box and whisker plot for each column of *x* or each vector in sequence *x*. The box extends from the lower to @@ -4905,6 +4906,8 @@ The whiskers extend from the box to show the range of the data. Flier points are those past the end of the whiskers. + *x* is an array or a sequence of vectors. + - *notch* = 0 (default) produces a rectangular box plot. - *notch* = 1 will produce a notched box plot @@ -4927,7 +4930,8 @@ each box. The default is 0.5, or ``0.15*(distance between extreme positions)`` if that is smaller. - *x* is an array or a sequence of vectors. + - *patch_artist* = False (default) produces boxes with the Line2D artist + - *patch_artist* = True produces boxes with the Patch artist Returns a dictionary mapping each component of the boxplot to a list of the :class:`matplotlib.lines.Line2D` @@ -5045,23 +5049,55 @@ med_x = [cap_x_min, cap_x_max] med_y = [med, med] + def to_vc(xs,ys): + # convert arguments to verts and codes + verts = [] + #codes = [] + for xi,yi in zip(xs,ys): + verts.append( (xi,yi) ) + verts.append( (0,0) ) # ignored + codes = [mpath.Path.MOVETO] + \ + [mpath.Path.LINETO]*(len(verts)-2) + \ + [mpath.Path.CLOSEPOLY] + return verts,codes + + def patch_list(xs,ys): + verts,codes = to_vc(xs,ys) + path = mpath.Path( verts, codes ) + patch = mpatches.PathPatch(path) + self.add_artist(patch) + return [patch] + # vertical or horizontal plot? if vert: def doplot(*args): return self.plot(*args) + def dopatch(xs,ys): + return patch_list(xs,ys) else: def doplot(*args): shuffled = [] for i in xrange(0, len(args), 3): shuffled.extend([args[i+1], args[i], args[i+2]]) return self.plot(*shuffled) + def dopatch(xs,ys): + xs,ys = ys,xs # flip X, Y + return patch_list(xs,ys) + if patch_artist: + median_color = 'k' + else: + median_color = 'r' + whiskers.extend(doplot(wisk_x, [q1, wisk_lo], 'b--', wisk_x, [q3, wisk_hi], 'b--')) caps.extend(doplot(cap_x, [wisk_hi, wisk_hi], 'k-', cap_x, [wisk_lo, wisk_lo], 'k-')) - boxes.extend(doplot(box_x, box_y, 'b-')) - medians.extend(doplot(med_x, med_y, 'r-')) + if patch_artist: + boxes.extend(dopatch(box_x, box_y)) + else: + boxes.extend(doplot(box_x, box_y, 'b-')) + medians.extend(doplot(med_x, med_y, median_color+'-')) fliers.extend(doplot(flier_hi_x, flier_hi, sym, flier_lo_x, flier_lo, sym)) Modified: trunk/matplotlib/lib/matplotlib/pyplot.py =================================================================== --- trunk/matplotlib/lib/matplotlib/pyplot.py 2009-12-15 02:57:32 UTC (rev 8033) +++ trunk/matplotlib/lib/matplotlib/pyplot.py 2009-12-15 02:57:46 UTC (rev 8034) @@ -1767,7 +1767,8 @@ # This function was autogenerated by boilerplate.py. Do not edit as # changes will be lost @autogen_docstring(Axes.boxplot) -def boxplot(x, notch=0, sym='b+', vert=1, whis=1.5, positions=None, widths=None, hold=None): +def boxplot(x, notch=0, sym='b+', vert=1, whis=1.5, positions=None, widths=None, + hold=None, patch_artist=False): ax = gca() # allow callers to override the hold state by passing hold=True|False washold = ax.ishold() @@ -1775,7 +1776,8 @@ if hold is not None: ax.hold(hold) try: - ret = ax.boxplot(x, notch, sym, vert, whis, positions, widths) + ret = ax.boxplot(x, notch, sym, vert, whis, positions, widths, + patch_artist=patch_artist) draw_if_interactive() finally: ax.hold(washold) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lee...@us...> - 2009-12-16 01:22:52
|
Revision: 8035 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8035&view=rev Author: leejjoon Date: 2009-12-16 01:22:41 +0000 (Wed, 16 Dec 2009) Log Message: ----------- support unsampled image for ps backend Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/backend_bases.py trunk/matplotlib/lib/matplotlib/backends/backend_mixed.py trunk/matplotlib/lib/matplotlib/backends/backend_ps.py trunk/matplotlib/lib/matplotlib/image.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-15 02:57:46 UTC (rev 8034) +++ trunk/matplotlib/CHANGELOG 2009-12-16 01:22:41 UTC (rev 8035) @@ -1,3 +1,5 @@ +2009-12-15 Add raw-image (unsampled) support for the ps backend. - JJL + 2009-12-14 Add patch_artist kwarg to boxplot, but keep old default. Convert boxplot_demo2.py to use the new patch_artist. - ADS Modified: trunk/matplotlib/lib/matplotlib/backend_bases.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backend_bases.py 2009-12-15 02:57:46 UTC (rev 8034) +++ trunk/matplotlib/lib/matplotlib/backend_bases.py 2009-12-16 01:22:41 UTC (rev 8035) @@ -340,6 +340,13 @@ """ return False + def option_scale_image(self): + """ + override this method for renderers that support arbitrary + scaling of image (most of the vector backend). + """ + return False + def draw_tex(self, gc, x, y, s, prop, angle, ismath='TeX!'): """ """ Modified: trunk/matplotlib/lib/matplotlib/backends/backend_mixed.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_mixed.py 2009-12-15 02:57:46 UTC (rev 8034) +++ trunk/matplotlib/lib/matplotlib/backends/backend_mixed.py 2009-12-16 01:22:41 UTC (rev 8035) @@ -59,7 +59,7 @@ get_texmanager get_text_width_height_descent new_gc open_group option_image_nocomposite points_to_pixels strip_math start_filter stop_filter draw_gouraud_triangle - draw_gouraud_triangles + draw_gouraud_triangles option_scale_image """.split() def _set_current_renderer(self, renderer): self._renderer = renderer Modified: trunk/matplotlib/lib/matplotlib/backends/backend_ps.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_ps.py 2009-12-15 02:57:46 UTC (rev 8034) +++ trunk/matplotlib/lib/matplotlib/backends/backend_ps.py 2009-12-16 01:22:41 UTC (rev 8035) @@ -380,8 +380,14 @@ """ return self.image_magnification - def draw_image(self, gc, x, y, im): + def option_scale_image(self): """ + ps backend support arbitrary scaling of image. + """ + return True + + def draw_image(self, gc, x, y, im, sx=None, sy=None): + """ Draw the Image instance into the current axes; x is the distance in pixels from the left hand side of the canvas and y is the distance from bottom @@ -400,9 +406,13 @@ imagecmd = "false 3 colorimage" hexlines = '\n'.join(self._hex_lines(bits)) - xscale, yscale = ( - w/self.image_magnification, h/self.image_magnification) - + if sx is None: + sx = 1./self.image_magnification + if sy is None: + sy = 1./self.image_magnification + + xscale, yscale = (w*sx, h*sy) + figh = self.height*72 #print 'values', origin, flipud, figh, h, y Modified: trunk/matplotlib/lib/matplotlib/image.py =================================================================== --- trunk/matplotlib/lib/matplotlib/image.py 2009-12-15 02:57:46 UTC (rev 8034) +++ trunk/matplotlib/lib/matplotlib/image.py 2009-12-16 01:22:41 UTC (rev 8035) @@ -127,21 +127,140 @@ def make_image(self, magnification=1.0): raise RuntimeError('The make_image method must be overridden.') + + def _get_unsampled_image(self, A, image_extents, viewlim): + """ + convert numpy array A with given extents ([x1, x2, y1, y2] in + data coordinate) into the Image, given the vielim (should be a + bbox instance). Image will be clipped if the extents is + significantly larger than the viewlim. + """ + xmin, xmax, ymin, ymax = image_extents + dxintv = xmax-xmin + dyintv = ymax-ymin + + # the viewport scale factor + sx = dxintv/viewlim.width + sy = dyintv/viewlim.height + numrows, numcols = A.shape[:2] + if sx > 2: + x0 = (viewim.x0-xmin)/dxintv * numcols + ix0 = max(0, int(x0 - self._filterrad)) + x1 = (viewlim.x1-xmin)/dxintv * numcols + ix1 = min(numcols, int(x1 + self._filterrad)) + xslice = slice(ix0, ix1) + xmin_old = xmin + xmin = xmin_old + ix0*dxintv/numcols + xmax = xmin_old + ix1*dxintv/numcols + dxintv = xmax - xmin + sx = dxintv/viewlim.width + else: + xslice = slice(0, numcols) + + if sy > 2: + y0 = (viewlim.y0-ymin)/dyintv * numrows + iy0 = max(0, int(y0 - self._filterrad)) + y1 = (viewlim.y1-ymin)/dyintv * numrows + iy1 = min(numrows, int(y1 + self._filterrad)) + if self.origin == 'upper': + yslice = slice(numrows-iy1, numrows-iy0) + else: + yslice = slice(iy0, iy1) + ymin_old = ymin + ymin = ymin_old + iy0*dyintv/numrows + ymax = ymin_old + iy1*dyintv/numrows + dyintv = ymax - ymin + sy = dyintv/self.axes.viewLim.height + else: + yslice = slice(0, numrows) + + if xslice != self._oldxslice or yslice != self._oldyslice: + self._imcache = None + self._oldxslice = xslice + self._oldyslice = yslice + + if self._imcache is None: + if self._A.dtype == np.uint8 and len(self._A.shape) == 3: + im = _image.frombyte(self._A[yslice,xslice,:], 0) + im.is_grayscale = False + else: + if self._rgbacache is None: + x = self.to_rgba(self._A, self._alpha) + self._rgbacache = x + else: + x = self._rgbacache + im = _image.fromarray(x[yslice,xslice], 0) + if len(self._A.shape) == 2: + im.is_grayscale = self.cmap.is_gray() + else: + im.is_grayscale = False + self._imcache = im + + if self.origin=='upper': + im.flipud_in() + else: + im = self._imcache + + return im, xmin, ymin, dxintv, dyintv, sx, sy + + + def _draw_unsampled_image(self, renderer, gc): + """ + draw unsampled image. The renderer should support a draw_image method + with scale parameter. + """ + im, xmin, ymin, dxintv, dyintv, sx, sy = \ + self._get_unsampled_image(self._A, self.get_extent(), self.axes.viewLim) + + if im is None: return # I'm not if this check is required. -JJL + + transData = self.axes.transData + xx1, yy1 = transData.transform_point((xmin, ymin)) + xx2, yy2 = transData.transform_point((xmin+dxintv, ymin+dyintv)) + + fc = self.axes.patch.get_facecolor() + bg = mcolors.colorConverter.to_rgba(fc, 0) + im.set_bg( *bg) + + # image input dimensions + im.reset_matrix() + numrows, numcols = im.get_size() + + im.resize(numcols, numrows) # just to create im.bufOut that is required by backends. There may be better solution -JJL + + sx = (xx2-xx1)/numcols + sy = (yy2-yy1)/numrows + im._url = self.get_url() + renderer.draw_image(gc, xx1, yy1, im, sx, sy) + + + def _check_unsampled_image(self, renderer): + """ + return True if the image is better to be drawn unsampled. + The derived class needs to override it. + """ + return False + @allow_rasterization def draw(self, renderer, *args, **kwargs): if not self.get_visible(): return if (self.axes.get_xscale() != 'linear' or self.axes.get_yscale() != 'linear'): warnings.warn("Images are not supported on non-linear axes.") - im = self.make_image(renderer.get_image_magnification()) - if im is None: - return - im._url = self.get_url() + l, b, widthDisplay, heightDisplay = self.axes.bbox.bounds gc = renderer.new_gc() gc.set_clip_rectangle(self.axes.bbox.frozen()) gc.set_clip_path(self.get_clip_path()) - renderer.draw_image(gc, l, b, im) + + if self._check_unsampled_image(renderer): + self._draw_unsampled_image(renderer, gc) + else: + im = self.make_image(renderer.get_image_magnification()) + if im is None: + return + im._url = self.get_url() + renderer.draw_image(gc, l, b, im) gc.restore() def contains(self, mouseevent): @@ -338,72 +457,9 @@ if self._A is None: raise RuntimeError('You must first set the image array or the image attribute') - xmin, xmax, ymin, ymax = self.get_extent() - dxintv = xmax-xmin - dyintv = ymax-ymin + im, xmin, ymin, dxintv, dyintv, sx, sy = \ + self._get_unsampled_image(self._A, self.get_extent(), self.axes.viewLim) - # the viewport scale factor - sx = dxintv/self.axes.viewLim.width - sy = dyintv/self.axes.viewLim.height - numrows, numcols = self._A.shape[:2] - if sx > 2: - x0 = (self.axes.viewLim.x0-xmin)/dxintv * numcols - ix0 = max(0, int(x0 - self._filterrad)) - x1 = (self.axes.viewLim.x1-xmin)/dxintv * numcols - ix1 = min(numcols, int(x1 + self._filterrad)) - xslice = slice(ix0, ix1) - xmin_old = xmin - xmin = xmin_old + ix0*dxintv/numcols - xmax = xmin_old + ix1*dxintv/numcols - dxintv = xmax - xmin - sx = dxintv/self.axes.viewLim.width - else: - xslice = slice(0, numcols) - - if sy > 2: - y0 = (self.axes.viewLim.y0-ymin)/dyintv * numrows - iy0 = max(0, int(y0 - self._filterrad)) - y1 = (self.axes.viewLim.y1-ymin)/dyintv * numrows - iy1 = min(numrows, int(y1 + self._filterrad)) - if self.origin == 'upper': - yslice = slice(numrows-iy1, numrows-iy0) - else: - yslice = slice(iy0, iy1) - ymin_old = ymin - ymin = ymin_old + iy0*dyintv/numrows - ymax = ymin_old + iy1*dyintv/numrows - dyintv = ymax - ymin - sy = dyintv/self.axes.viewLim.height - else: - yslice = slice(0, numrows) - - if xslice != self._oldxslice or yslice != self._oldyslice: - self._imcache = None - self._oldxslice = xslice - self._oldyslice = yslice - - if self._imcache is None: - if self._A.dtype == np.uint8 and len(self._A.shape) == 3: - im = _image.frombyte(self._A[yslice,xslice,:], 0) - im.is_grayscale = False - else: - if self._rgbacache is None: - x = self.to_rgba(self._A, self._alpha) - self._rgbacache = x - else: - x = self._rgbacache - im = _image.fromarray(x[yslice,xslice], 0) - if len(self._A.shape) == 2: - im.is_grayscale = self.cmap.is_gray() - else: - im.is_grayscale = False - self._imcache = im - - if self.origin=='upper': - im.flipud_in() - else: - im = self._imcache - fc = self.axes.patch.get_facecolor() bg = mcolors.colorConverter.to_rgba(fc, 0) im.set_bg( *bg) @@ -435,6 +491,15 @@ return im + def _check_unsampled_image(self, renderer): + """ + return True if the image is better to be drawn unsampled. + """ + if renderer.option_scale_image() and self.get_interpolation() == "nearest": + return True + else: + return False + def set_extent(self, extent): """ extent is data axes (left, right, bottom, top) for making image plots This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <as...@us...> - 2009-12-18 22:25:36
|
Revision: 8039 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8039&view=rev Author: astraw Date: 2009-12-18 22:25:26 +0000 (Fri, 18 Dec 2009) Log Message: ----------- bugfix: mlab.prctile handles even-length data Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/mlab.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-18 22:25:16 UTC (rev 8038) +++ trunk/matplotlib/CHANGELOG 2009-12-18 22:25:26 UTC (rev 8039) @@ -1,3 +1,6 @@ +2009-12-18 mlab.prctile handles even-length data, such that the median + is the mean of the two middle values. - ADS + 2009-12-15 Add raw-image (unsampled) support for the ps backend. - JJL 2009-12-14 Add patch_artist kwarg to boxplot, but keep old default. Modified: trunk/matplotlib/lib/matplotlib/mlab.py =================================================================== --- trunk/matplotlib/lib/matplotlib/mlab.py 2009-12-18 22:25:16 UTC (rev 8038) +++ trunk/matplotlib/lib/matplotlib/mlab.py 2009-12-18 22:25:26 UTC (rev 8039) @@ -904,19 +904,39 @@ the *p* percentage point in the sequence is returned. """ + # This implementation derived from scipy.stats.scoreatpercentile + def _interpolate(a, b, fraction): + """Returns the point at the given fraction between a and b, where + 'fraction' must be between 0 and 1. + """ + return a + (b - a)*fraction - x = np.array(x).ravel() # we need a copy - x.sort() - Nx = len(x) + scalar = True + if cbook.iterable(p): + scalar = False + per = np.array(p) + values = np.array(x).ravel() # copy + values.sort() - if not cbook.iterable(p): - return x[int(p*Nx/100.0)] + idxs = per /100. * (values.shape[0] - 1) + ai = idxs.astype(np.int) + bi = ai + 1 + frac = idxs % 1 - p = np.asarray(p)* Nx/100.0 - ind = p.astype(int) - ind = np.where(ind>=Nx, Nx-1, ind) - return x.take(ind) + # handle cases where attempting to interpolate past last index + cond = bi >= len(values) + if scalar: + if cond: + ai -= 1 + bi -= 1 + frac += 1 + else: + ai[cond] -= 1 + bi[cond] -= 1 + frac[cond] += 1 + return _interpolate(values[ai],values[bi],frac) + def prctile_rank(x, p): """ Return the rank for each element in *x*, return the rank This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <as...@us...> - 2009-12-18 22:25:43
|
Revision: 8040 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8040&view=rev Author: astraw Date: 2009-12-18 22:25:35 +0000 (Fri, 18 Dec 2009) Log Message: ----------- Don't limit notch size in boxplot to q1-q3 range Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/axes.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-18 22:25:26 UTC (rev 8039) +++ trunk/matplotlib/CHANGELOG 2009-12-18 22:25:35 UTC (rev 8040) @@ -1,3 +1,6 @@ +2009-12-18 Don't limit notch size in boxplot to q1-q3 range, as this + is effectively making the data look better than it is. - ADS + 2009-12-18 mlab.prctile handles even-length data, such that the median is the mean of the two middle values. - ADS Modified: trunk/matplotlib/lib/matplotlib/axes.py =================================================================== --- trunk/matplotlib/lib/matplotlib/axes.py 2009-12-18 22:25:26 UTC (rev 8039) +++ trunk/matplotlib/lib/matplotlib/axes.py 2009-12-18 22:25:35 UTC (rev 8040) @@ -5035,10 +5035,6 @@ else: notch_max = med + 1.57*iq/np.sqrt(row) notch_min = med - 1.57*iq/np.sqrt(row) - if notch_max > q3: - notch_max = q3 - if notch_min < q1: - notch_min = q1 # make our notched box vectors box_x = [box_x_min, box_x_max, box_x_max, cap_x_max, box_x_max, box_x_max, box_x_min, box_x_min, cap_x_min, box_x_min, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <he...@us...> - 2009-12-20 08:03:50
|
Revision: 8041 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8041&view=rev Author: heeres Date: 2009-12-20 08:03:40 +0000 (Sun, 20 Dec 2009) Log Message: ----------- mplot3d: fix axes juggle issue, fix ticks on end of axes range Modified Paths: -------------- trunk/matplotlib/examples/mplot3d/polys3d_demo.py trunk/matplotlib/examples/mplot3d/surface3d_demo3.py trunk/matplotlib/lib/mpl_toolkits/mplot3d/art3d.py trunk/matplotlib/lib/mpl_toolkits/mplot3d/axes3d.py trunk/matplotlib/lib/mpl_toolkits/mplot3d/axis3d.py Modified: trunk/matplotlib/examples/mplot3d/polys3d_demo.py =================================================================== --- trunk/matplotlib/examples/mplot3d/polys3d_demo.py 2009-12-18 22:25:35 UTC (rev 8040) +++ trunk/matplotlib/examples/mplot3d/polys3d_demo.py 2009-12-20 08:03:40 UTC (rev 8041) @@ -22,8 +22,11 @@ poly.set_alpha(0.7) ax.add_collection3d(poly, zs=zs, zdir='y') +ax.set_xlabel('X') ax.set_xlim3d(0, 10) +ax.set_ylabel('Y') ax.set_ylim3d(-1, 4) +ax.set_zlabel('Z') ax.set_zlim3d(0, 1) plt.show() Modified: trunk/matplotlib/examples/mplot3d/surface3d_demo3.py =================================================================== --- trunk/matplotlib/examples/mplot3d/surface3d_demo3.py 2009-12-18 22:25:35 UTC (rev 8040) +++ trunk/matplotlib/examples/mplot3d/surface3d_demo3.py 2009-12-20 08:03:40 UTC (rev 8041) @@ -23,8 +23,8 @@ surf = ax.plot_surface(X, Y, Z, rstride=1, cstride=1, facecolors=colors, linewidth=0, antialiased=False) -ax.set_zlim3d(-1.01, 1.01) -ax.w_zaxis.set_major_locator(LinearLocator(10)) +ax.set_zlim3d(-1, 1) +ax.w_zaxis.set_major_locator(LinearLocator(6)) ax.w_zaxis.set_major_formatter(FormatStrFormatter('%.03f')) plt.show() Modified: trunk/matplotlib/lib/mpl_toolkits/mplot3d/art3d.py =================================================================== --- trunk/matplotlib/lib/mpl_toolkits/mplot3d/art3d.py 2009-12-18 22:25:35 UTC (rev 8040) +++ trunk/matplotlib/lib/mpl_toolkits/mplot3d/art3d.py 2009-12-20 08:03:40 UTC (rev 8041) @@ -434,9 +434,26 @@ def juggle_axes(xs, ys, zs, zdir): """ - Reorder coordinates so that zdir + Reorder coordinates so that 2D xs, ys can be plotted in the plane + orthogonal to zdir. zdir is normally x, y or z. However, if zdir + starts with a '-' it is interpreted as a compensation for rotate_axes. """ if zdir == 'x': + return zs, xs, ys + elif zdir == 'y': + return xs, zs, ys + elif zdir[0] == '-': + return rotate_axes(xs, ys, zs, zdir) + else: + return xs, ys, zs + +def rotate_axes(xs, ys, zs, zdir): + """ + Reorder coordinates so that the axes are rotated with zdir along + the original z axis. Prepending the axis with a '-' does the + inverse transform, so zdir can be x, -x, y, -y, z or -z + """ + if zdir == 'x': return ys, zs, xs elif zdir == '-x': return zs, xs, ys Modified: trunk/matplotlib/lib/mpl_toolkits/mplot3d/axes3d.py =================================================================== --- trunk/matplotlib/lib/mpl_toolkits/mplot3d/axes3d.py 2009-12-18 22:25:35 UTC (rev 8040) +++ trunk/matplotlib/lib/mpl_toolkits/mplot3d/axes3d.py 2009-12-20 08:03:40 UTC (rev 8041) @@ -857,7 +857,7 @@ had_data = self.has_data() - jX, jY, jZ = art3d.juggle_axes(X, Y, Z, zdir) + jX, jY, jZ = art3d.rotate_axes(X, Y, Z, zdir) cset = Axes.contour(self, jX, jY, jZ, **kwargs) zdir = '-' + zdir Modified: trunk/matplotlib/lib/mpl_toolkits/mplot3d/axis3d.py =================================================================== --- trunk/matplotlib/lib/mpl_toolkits/mplot3d/axis3d.py 2009-12-18 22:25:35 UTC (rev 8040) +++ trunk/matplotlib/lib/mpl_toolkits/mplot3d/axis3d.py 2009-12-20 08:03:40 UTC (rev 8041) @@ -180,7 +180,7 @@ # filter locations here so that no extra grid lines are drawn interval = self.get_view_interval() majorLocs = [loc for loc in majorLocs if \ - interval[0] < loc < interval[1]] + interval[0] <= loc <= interval[1]] self.major.formatter.set_locs(majorLocs) majorLabels = [self.major.formatter(val, i) for i, val in enumerate(majorLocs)] This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <as...@us...> - 2009-12-21 00:47:06
|
Revision: 8044 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8044&view=rev Author: astraw Date: 2009-12-21 00:46:59 +0000 (Mon, 21 Dec 2009) Log Message: ----------- spines: default transform is in data units, add set_bounds() call Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/axes.py trunk/matplotlib/lib/matplotlib/spines.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-21 00:46:30 UTC (rev 8043) +++ trunk/matplotlib/CHANGELOG 2009-12-21 00:46:59 UTC (rev 8044) @@ -1,3 +1,6 @@ +2009-12-20 spines: put spines in data coordinates, add set_bounds() + call. -ADS + 2009-12-18 Don't limit notch size in boxplot to q1-q3 range, as this is effectively making the data look better than it is. - ADS Modified: trunk/matplotlib/lib/matplotlib/axes.py =================================================================== --- trunk/matplotlib/lib/matplotlib/axes.py 2009-12-21 00:46:30 UTC (rev 8043) +++ trunk/matplotlib/lib/matplotlib/axes.py 2009-12-21 00:46:59 UTC (rev 8044) @@ -2065,6 +2065,9 @@ other.figure.canvas is not None): other.figure.canvas.draw_idle() + for loc in ('bottom','top'): + self.spines[loc].set_bounds(xmin,xmax) + return xmin, xmax def get_xscale(self): @@ -2238,6 +2241,10 @@ if (other.figure != self.figure and other.figure.canvas is not None): other.figure.canvas.draw_idle() + + for loc in ('left','right'): + self.spines[loc].set_bounds(ymin,ymax) + return ymin, ymax def get_yscale(self): Modified: trunk/matplotlib/lib/matplotlib/spines.py =================================================================== --- trunk/matplotlib/lib/matplotlib/spines.py 2009-12-21 00:46:30 UTC (rev 8043) +++ trunk/matplotlib/lib/matplotlib/spines.py 2009-12-21 00:46:59 UTC (rev 8044) @@ -55,7 +55,7 @@ self.axis = None self.set_zorder(2.5) - self.set_transform(self.axes.transAxes) # default transform + self.set_transform(self.axes.transData) # default transform # Defer initial position determination. (Not much support for # non-rectangular axes is currently implemented, and this lets @@ -82,6 +82,7 @@ self._width = radius*2 self._height = radius*2 self._angle = 0 + self.set_transform(self.axes.transAxes) # circle drawn on axes transform def set_patch_line(self): """set the spine to be linear""" @@ -229,9 +230,9 @@ t = self.get_spine_transform() if self.spine_type in ['left','right']: t2 = mtransforms.blended_transform_factory(t, - self.axes.transAxes) + self.axes.transData) elif self.spine_type in ['bottom','top']: - t2 = mtransforms.blended_transform_factory(self.axes.transAxes, + t2 = mtransforms.blended_transform_factory(self.axes.transData, t) self.set_transform(t2) @@ -278,6 +279,19 @@ else: raise ValueError("unknown spine_transform type: %s"%what) + def set_bounds( self, low, high ): + v1 = self._path.vertices[:] # copy + assert v1.shape == (2,2), 'unexpected vertices shape' + if self.spine_type in ['left','right']: + v1[0,1] = low + v1[1,1] = high + elif self.spine_type in ['bottom','top']: + v1[0,0] = low + v1[1,0] = high + else: + raise ValueError('unable to set bounds for spine "%s"'%spine_type) + self._path.vertices = v1 # replace + @classmethod def linear_spine(cls, axes, spine_type, **kwargs): """ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <as...@us...> - 2009-12-21 03:50:07
|
Revision: 8048 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8048&view=rev Author: astraw Date: 2009-12-21 03:49:59 +0000 (Mon, 21 Dec 2009) Log Message: ----------- spines and ticks: implement smart bounds Modified Paths: -------------- trunk/matplotlib/examples/pylab_examples/spine_placement_demo.py trunk/matplotlib/lib/matplotlib/axis.py trunk/matplotlib/lib/matplotlib/spines.py Modified: trunk/matplotlib/examples/pylab_examples/spine_placement_demo.py =================================================================== --- trunk/matplotlib/examples/pylab_examples/spine_placement_demo.py 2009-12-21 02:24:14 UTC (rev 8047) +++ trunk/matplotlib/examples/pylab_examples/spine_placement_demo.py 2009-12-21 03:49:59 UTC (rev 8048) @@ -37,6 +37,8 @@ ax.spines['right'].set_color('none') ax.spines['bottom'].set_position('center') ax.spines['top'].set_color('none') +ax.spines['left'].set_smart_bounds(True) +ax.spines['bottom'].set_smart_bounds(True) ax.xaxis.set_ticks_position('bottom') ax.yaxis.set_ticks_position('left') @@ -47,6 +49,8 @@ ax.spines['right'].set_color('none') ax.spines['bottom'].set_position('zero') ax.spines['top'].set_color('none') +ax.spines['left'].set_smart_bounds(True) +ax.spines['bottom'].set_smart_bounds(True) ax.xaxis.set_ticks_position('bottom') ax.yaxis.set_ticks_position('left') @@ -57,6 +61,8 @@ ax.spines['right'].set_color('none') ax.spines['bottom'].set_position(('axes',0.1)) ax.spines['top'].set_color('none') +ax.spines['left'].set_smart_bounds(True) +ax.spines['bottom'].set_smart_bounds(True) ax.xaxis.set_ticks_position('bottom') ax.yaxis.set_ticks_position('left') @@ -67,15 +73,17 @@ ax.spines['right'].set_color('none') ax.spines['bottom'].set_position(('data',2)) ax.spines['top'].set_color('none') +ax.spines['left'].set_smart_bounds(True) +ax.spines['bottom'].set_smart_bounds(True) ax.xaxis.set_ticks_position('bottom') ax.yaxis.set_ticks_position('left') - # ---------------------------------------------------- def adjust_spines(ax,spines): for loc, spine in ax.spines.iteritems(): if loc in spines: spine.set_position(('outward',10)) # outward by 10 points + spine.set_smart_bounds(True) else: spine.set_color('none') # don't draw spine Modified: trunk/matplotlib/lib/matplotlib/axis.py =================================================================== --- trunk/matplotlib/lib/matplotlib/axis.py 2009-12-21 02:24:14 UTC (rev 8047) +++ trunk/matplotlib/lib/matplotlib/axis.py 2009-12-21 03:49:59 UTC (rev 8048) @@ -15,6 +15,7 @@ import matplotlib.ticker as mticker import matplotlib.transforms as mtransforms import matplotlib.units as munits +import numpy as np GRIDLINE_INTERPOLATION_STEPS = 180 @@ -539,6 +540,8 @@ #self.minor = dummy() self._autolabelpos = True + self._smart_bounds = False + self.label = self._get_label() self.labelpad = 5 self.offsetText = self._get_offset_text() @@ -737,6 +740,14 @@ bbox2 = mtransforms.Bbox.from_extents(0, 0, 0, 0) return bbox, bbox2 + def set_smart_bounds(self,value): + """set the axis to have smart bounds""" + self._smart_bounds = value + + def get_smart_bounds(self): + """get whether the axis has smart bounds""" + return self._smart_bounds + @allow_rasterization def draw(self, renderer, *args, **kwargs): 'Draw the axis lines, grid lines, tick lines and labels' @@ -746,7 +757,47 @@ if not self.get_visible(): return renderer.open_group(__name__) interval = self.get_view_interval() - for tick, loc, label in self.iter_ticks(): + tick_tups = [ t for t in self.iter_ticks()] + if self._smart_bounds: + # handle inverted limits + view_low, view_high = min(*interval), max(*interval) + data_low, data_high = self.get_data_interval() + if data_low > data_high: + data_low, data_high = data_high, data_low + locs = [ti[1] for ti in tick_tups] + locs.sort() + locs = np.array(locs) + if len(locs): + if data_low <= view_low: + # data extends beyond view, take view as limit + ilow = view_low + else: + # data stops within view, take best tick + cond = locs <= data_low + good_locs = locs[cond] + if len(good_locs) > 0: + # last tick prior or equal to first data point + ilow = good_locs[-1] + else: + # No ticks (why not?), take first tick + ilow = locs[0] + if data_high >= view_high: + # data extends beyond view, take view as limit + ihigh = view_high + else: + # data stops within view, take best tick + cond = locs >= data_high + good_locs = locs[cond] + if len(good_locs) > 0: + # first tick after or equal to last data point + ihigh = good_locs[0] + else: + # No ticks (why not?), take last tick + ihigh = locs[-1] + tick_tups = [ ti for ti in tick_tups + if (ti[1] >= ilow) and (ti[1] <= ihigh)] + + for tick, loc, label in tick_tups: if tick is None: continue if not mtransforms.interval_contains(interval, loc): continue tick.update_position(loc) Modified: trunk/matplotlib/lib/matplotlib/spines.py =================================================================== --- trunk/matplotlib/lib/matplotlib/spines.py 2009-12-21 02:24:14 UTC (rev 8047) +++ trunk/matplotlib/lib/matplotlib/spines.py 2009-12-21 03:49:59 UTC (rev 8048) @@ -59,6 +59,7 @@ self.set_transform(self.axes.transData) # default transform self._bounds = None # default bounds + self._smart_bounds = False # Defer initial position determination. (Not much support for # non-rectangular axes is currently implemented, and this lets @@ -78,6 +79,20 @@ # Note: This cannot be calculated until this is added to an Axes self._patch_transform = mtransforms.IdentityTransform() + def set_smart_bounds(self,value): + """set the spine and associated axis to have smart bounds""" + self._smart_bounds = value + + # also set the axis if possible + if self.spine_type in ('left','right'): + self.axes.yaxis.set_smart_bounds(value) + elif self.spine_type in ('top','bottom'): + self.axes.xaxis.set_smart_bounds(value) + + def get_smart_bounds(self): + """get whether the spine has smart bounds""" + return self._smart_bounds + def set_patch_circle(self,center,radius): """set the spine to be circular""" self._patch_type = 'circle' @@ -141,6 +156,26 @@ if self.axis is not None: self.axis.cla() + def is_frame_like(self): + """return True if directly on axes frame + + This is useful for determining if a spine is the edge of an + old style MPL plot. If so, this function will return True. + """ + self._ensure_position_is_set() + position = self._position + if cbook.is_string_like(position): + if position=='center': + position = ('axes',0.5) + elif position=='zero': + position = ('data',0) + assert len(position)==2, "position should be 2-tuple" + position_type, amount = position + if position_type=='outward' and amount == 0: + return True + else: + return False + def _adjust_location(self): """automatically set spine bounds to the view interval""" @@ -154,6 +189,61 @@ low,high = self.axes.viewLim.intervalx else: raise ValueError('unknown spine spine_type: %s'%self.spine_type) + + if self._smart_bounds: + # attempt to set bounds in sophisticated way + if low > high: + # handle inverted limits + low,high=high,low + + viewlim_low = low + viewlim_high = high + + del low, high + + if self.spine_type in ('left','right'): + datalim_low,datalim_high = self.axes.dataLim.intervaly + ticks = self.axes.get_yticks() + elif self.spine_type in ('top','bottom'): + datalim_low,datalim_high = self.axes.dataLim.intervalx + ticks = self.axes.get_xticks() + # handle inverted limits + ticks = list(ticks) + ticks.sort() + ticks = np.array(ticks) + if datalim_low > datalim_high: + datalim_low, datalim_high = datalim_high, datalim_low + + if datalim_low < viewlim_low: + # Data extends past view. Clip line to view. + low = viewlim_low + else: + # Data ends before view ends. + cond = (ticks <= datalim_low) & (ticks >= viewlim_low) + tickvals = ticks[cond] + if len(tickvals): + # A tick is less than or equal to lowest data point. + low = tickvals[-1] + else: + # No tick is available + low = datalim_low + low = max(low,viewlim_low) + + if datalim_high > viewlim_high: + # Data extends past view. Clip line to view. + high = viewlim_high + else: + # Data ends before view ends. + cond = (ticks >= datalim_high) & (ticks <= viewlim_high) + tickvals = ticks[cond] + if len(tickvals): + # A tick is greater than or equal to highest data point. + high = tickvals[0] + else: + # No tick is available + high = datalim_high + high = min(high,viewlim_high) + else: low,high = self._bounds @@ -316,11 +406,16 @@ raise ValueError("unknown spine_transform type: %s"%what) def set_bounds( self, low, high ): + """Set the bounds of the spine.""" if self.spine_type == 'circle': raise ValueError( 'set_bounds() method incompatible with circular spines') self._bounds = (low, high) + def get_bounds( self ): + """Get the bounds of the spine.""" + return self._bounds + @classmethod def linear_spine(cls, axes, spine_type, **kwargs): """ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lee...@us...> - 2009-12-22 19:49:58
|
Revision: 8051 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8051&view=rev Author: leejjoon Date: 2009-12-22 19:49:49 +0000 (Tue, 22 Dec 2009) Log Message: ----------- Fix cmap data for gist_earth_r, etc. Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/_cm.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-22 17:03:29 UTC (rev 8050) +++ trunk/matplotlib/CHANGELOG 2009-12-22 19:49:49 UTC (rev 8051) @@ -1,3 +1,5 @@ +2009-12-22 Fix cmap data for gist_earth_r, etc. -JJL + 2009-12-20 spines: put spines in data coordinates, add set_bounds() call. -ADS Modified: trunk/matplotlib/lib/matplotlib/_cm.py =================================================================== --- trunk/matplotlib/lib/matplotlib/_cm.py 2009-12-22 17:03:29 UTC (rev 8050) +++ trunk/matplotlib/lib/matplotlib/_cm.py 2009-12-22 19:49:49 UTC (rev 8051) @@ -1434,7 +1434,7 @@ (0.5490, 0.4719, 0.4719), (0.6980, 0.7176, 0.7176), (0.7882, 0.7553, 0.7553), -(1.0000, 0.9922, 0), +(1.0000, 0.9922, 0.9922), ), 'green': ( (0.0, 0.0, 0.0000), (0.0275, 0.0000, 0.0000), @@ -1458,7 +1458,7 @@ (0.9569, 0.8635, 0.8635), (0.9647, 0.8816, 0.8816), (0.9961, 0.9733, 0.9733), -(1.0000, 0.9843, 0), +(1.0000, 0.9843, 0.9843), ), 'blue': ( (0.0, 0.0, 0.0000), (0.0039, 0.1684, 0.1684), @@ -1470,7 +1470,7 @@ (0.5451, 0.3205, 0.3205), (0.7843, 0.3961, 0.3961), (0.8941, 0.6651, 0.6651), -(1.0000, 0.9843, 0), +(1.0000, 0.9843, 0.9843), )} _gist_gray_data = { @@ -1495,7 +1495,7 @@ (0.7922, 1.0000, 1.0000), (0.8471, 0.6218, 0.6218), (0.8980, 0.9235, 0.9235), -(1.0000, 0.9961, 0), +(1.0000, 0.9961, 0.9961), ), 'green': ( (0.0, 0.0, 0.0000), (0.0510, 0.3722, 0.3722), @@ -1516,9 +1516,9 @@ (0.7922, 0.0000, 0.0000), (0.8431, 0.1753, 0.1753), (0.8980, 0.5000, 0.5000), -(1.0000, 0.9725, 0), +(1.0000, 0.9725, 0.9725), ), 'blue': ( -(0.0, 0.0, 0.5020), +(0.0, 0.5020, 0.5020), (0.0510, 0.0222, 0.0222), (0.1098, 1.0000, 1.0000), (0.2039, 1.0000, 1.0000), @@ -1535,7 +1535,7 @@ (0.8000, 1.0000, 1.0000), (0.8431, 1.0000, 1.0000), (0.8980, 0.9341, 0.9341), -(1.0000, 0.9961, 0), +(1.0000, 0.9961, 0.9961), )} _gist_rainbow_data = ( @@ -1552,7 +1552,7 @@ _gist_stern_data = { 'red': ( (0.000, 0.000, 0.000), (0.0547, 1.000, 1.000), - (0.250, 0.027, 0.027), (0.2500, 0.250, 0.250), + (0.250, 0.027, 0.250), #(0.2500, 0.250, 0.250), (1.000, 1.000, 1.000)), 'green': ((0, 0, 0), (1, 1, 0)), 'blue': ( This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ef...@us...> - 2009-12-22 23:43:16
|
Revision: 8052 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8052&view=rev Author: efiring Date: 2009-12-22 23:43:09 +0000 (Tue, 22 Dec 2009) Log Message: ----------- pyplot.spy should set current image only if it is making an image Modified Paths: -------------- trunk/matplotlib/boilerplate.py trunk/matplotlib/lib/matplotlib/pyplot.py Modified: trunk/matplotlib/boilerplate.py =================================================================== --- trunk/matplotlib/boilerplate.py 2009-12-22 19:49:49 UTC (rev 8051) +++ trunk/matplotlib/boilerplate.py 2009-12-22 23:43:09 UTC (rev 8052) @@ -86,7 +86,7 @@ 'semilogx', 'semilogy', 'specgram', - 'spy', + #'spy', 'stem', 'step', 'vlines', @@ -111,7 +111,7 @@ 'pcolor' : 'sci(%(ret)s)', 'pcolormesh': 'sci(%(ret)s)', 'imshow' : 'sci(%(ret)s)', - 'spy' : 'sci(%(ret)s)', + #'spy' : 'sci(%(ret)s)', ### may return image or Line2D 'quiver' : 'sci(%(ret)s)', 'specgram' : 'sci(%(ret)s[-1])', Modified: trunk/matplotlib/lib/matplotlib/pyplot.py =================================================================== --- trunk/matplotlib/lib/matplotlib/pyplot.py 2009-12-22 19:49:49 UTC (rev 8051) +++ trunk/matplotlib/lib/matplotlib/pyplot.py 2009-12-22 23:43:09 UTC (rev 8052) @@ -1600,6 +1600,27 @@ addendum = docstring.Appender(msg, '\n\n') return lambda func: addendum(docstring.copy_dedent(base)(func)) + +# This function cannot be generated by boilerplate.py because it may +# return an image or a line. +@autogen_docstring(Axes.spy) +def spy(Z, precision=0, marker=None, markersize=None, aspect='equal', hold=None, **kwargs): + ax = gca() + # allow callers to override the hold state by passing hold=True|False + washold = ax.ishold() + + if hold is not None: + ax.hold(hold) + try: + ret = ax.spy(Z, precision, marker, markersize, aspect, **kwargs) + draw_if_interactive() + finally: + ax.hold(washold) + if isinstance(ret, cm.ScalarMappable): + sci(ret) + return ret + + ## Plotting part 2: autogenerated wrappers for axes methods ## # This function was autogenerated by boilerplate.py. Do not edit as @@ -2252,24 +2273,7 @@ sci(ret[-1]) return ret -# This function was autogenerated by boilerplate.py. Do not edit as -# changes will be lost -@autogen_docstring(Axes.spy) -def spy(Z, precision=0, marker=None, markersize=None, aspect='equal', hold=None, **kwargs): - ax = gca() - # allow callers to override the hold state by passing hold=True|False - washold = ax.ishold() - if hold is not None: - ax.hold(hold) - try: - ret = ax.spy(Z, precision, marker, markersize, aspect, **kwargs) - draw_if_interactive() - finally: - ax.hold(washold) - sci(ret) - return ret - # This function was autogenerated by boilerplate.py. Do not edit as # changes will be lost @autogen_docstring(Axes.stem) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ef...@us...> - 2009-12-28 00:25:32
|
Revision: 8054 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8054&view=rev Author: efiring Date: 2009-12-28 00:21:50 +0000 (Mon, 28 Dec 2009) Log Message: ----------- Line2D: simplify set_data functionality; recache only a coord. that was set. Modified Paths: -------------- trunk/matplotlib/examples/pylab_examples/clippedline.py trunk/matplotlib/lib/matplotlib/lines.py Modified: trunk/matplotlib/examples/pylab_examples/clippedline.py =================================================================== --- trunk/matplotlib/examples/pylab_examples/clippedline.py 2009-12-27 23:18:51 UTC (rev 8053) +++ trunk/matplotlib/examples/pylab_examples/clippedline.py 2009-12-28 00:21:50 UTC (rev 8054) @@ -1,6 +1,11 @@ """ Clip a line according to the current xlimits, and change the marker -style when zoomed in +style when zoomed in. + +It is not clear this example is still needed or valid; clipping +is now automatic for Line2D objects when x is sorted in +ascending order. + """ from matplotlib.lines import Line2D @@ -19,8 +24,7 @@ def set_data(self, *args, **kwargs): Line2D.set_data(self, *args, **kwargs) - if self._invalid: - self.recache() + self.recache() self.xorig = np.array(self._x) self.yorig = np.array(self._y) Modified: trunk/matplotlib/lib/matplotlib/lines.py =================================================================== --- trunk/matplotlib/lib/matplotlib/lines.py 2009-12-27 23:18:51 UTC (rev 8053) +++ trunk/matplotlib/lib/matplotlib/lines.py 2009-12-28 00:21:50 UTC (rev 8054) @@ -248,7 +248,8 @@ self._xorig = np.asarray([]) self._yorig = np.asarray([]) - self._invalid = True + self._invalidx = True + self._invalidy = True self.set_data(xdata, ydata) def contains(self, mouseevent): @@ -272,7 +273,7 @@ raise ValueError,"pick radius should be a distance" # Make sure we have data to plot - if self._invalid: + if self._invalidy or self._invalidx: self.recache() if len(self._xy)==0: return False,{} @@ -403,36 +404,28 @@ else: x, y = args - not_masked = 0 - if not ma.isMaskedArray(x): - x = np.asarray(x) - not_masked += 1 - if not ma.isMaskedArray(y): - y = np.asarray(y) - not_masked += 1 + self.set_xdata(x) + self.set_ydata(y) - if (not_masked < 2 or - (x is not self._xorig and - (x.shape != self._xorig.shape or np.any(x != self._xorig))) or - (y is not self._yorig and - (y.shape != self._yorig.shape or np.any(y != self._yorig)))): - self._xorig = x - self._yorig = y - self._invalid = True - def recache(self): - #if self.axes is None: print 'recache no axes' - #else: print 'recache units', self.axes.xaxis.units, self.axes.yaxis.units - if ma.isMaskedArray(self._xorig) or ma.isMaskedArray(self._yorig): - x = ma.asarray(self.convert_xunits(self._xorig), float) - y = ma.asarray(self.convert_yunits(self._yorig), float) - x = ma.ravel(x) - y = ma.ravel(y) + if self._invalidx: + xconv = self.convert_xunits(self._xorig) + if ma.isMaskedArray(self._xorig): + x = ma.asarray(xconv, float) + else: + x = np.asarray(xconv, float) + x = x.ravel() else: - x = np.asarray(self.convert_xunits(self._xorig), float) - y = np.asarray(self.convert_yunits(self._yorig), float) - x = np.ravel(x) - y = np.ravel(y) + x = self._x + if self._invalidy: + yconv = self.convert_yunits(self._yorig) + if ma.isMaskedArray(self._yorig): + y = ma.asarray(yconv, float) + else: + y = np.asarray(yconv, float) + y = y.ravel() + else: + y = self._y if len(x)==1 and len(y)>1: x = x * np.ones(y.shape, float) @@ -455,8 +448,7 @@ self._subslice = False if (self.axes and len(x) > 100 and self._is_sorted(x) and self.axes.name == 'rectilinear' and - self.axes.get_xscale() == 'linear' and - self.axes.get_yscale() == 'linear'): + self.axes.get_xscale() == 'linear'): self._subslice = True if hasattr(self, '_path'): interpolation_steps = self._path._interpolation_steps @@ -464,7 +456,8 @@ interpolation_steps = 1 self._path = Path(self._xy, None, interpolation_steps) self._transformed_path = None - self._invalid = False + self._invalidx = False + self._invalidy = False def _transform_path(self, subslice=None): # Masked arrays are now handled by the Path class itself @@ -482,7 +475,8 @@ ACCEPTS: a :class:`matplotlib.transforms.Transform` instance """ Artist.set_transform(self, t) - self._invalid = True + self._invalidx = True + self._invalidy = True def _is_sorted(self, x): "return true if x is sorted" @@ -491,7 +485,7 @@ @allow_rasterization def draw(self, renderer): - if self._invalid: + if self._invalidy or self._invalidx: self.recache() if self._subslice and self.axes: # Need to handle monotonically decreasing case also... @@ -619,7 +613,7 @@ """ if orig: return self._xorig - if self._invalid: + if self._invalidx: self.recache() return self._x @@ -632,7 +626,7 @@ """ if orig: return self._yorig - if self._invalid: + if self._invalidy: self.recache() return self._y @@ -641,7 +635,7 @@ Return the :class:`~matplotlib.path.Path` object associated with this line. """ - if self._invalid: + if self._invalidy or self._invalidx: self.recache() return self._path @@ -649,7 +643,7 @@ """ Return the *xy* data as a Nx2 numpy array. """ - if self._invalid: + if self._invalidy or self.invalidx: self.recache() return self._xy @@ -840,7 +834,8 @@ ACCEPTS: 1D array """ - self.set_data(x, self._yorig) + self._xorig = x + self._invalidx = True def set_ydata(self, y): """ @@ -848,7 +843,8 @@ ACCEPTS: 1D array """ - self.set_data(self._xorig, y) + self._yorig = y + self._invalidy = True def set_dashes(self, seq): """ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ds...@us...> - 2009-12-31 12:51:53
|
Revision: 8056 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8056&view=rev Author: dsdale Date: 2009-12-31 12:51:43 +0000 (Thu, 31 Dec 2009) Log Message: ----------- workaround for a regression in PyQt4-4.6.{0,1} Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-28 01:34:06 UTC (rev 8055) +++ trunk/matplotlib/CHANGELOG 2009-12-31 12:51:43 UTC (rev 8056) @@ -1,3 +1,5 @@ +2009-12-31 Commit a workaround for a regression in PyQt4-4.6.{0,1} - DSD + 2009-12-22 Fix cmap data for gist_earth_r, etc. -JJL 2009-12-20 spines: put spines in data coordinates, add set_bounds() Modified: trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py 2009-12-28 01:34:06 UTC (rev 8055) +++ trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py 2009-12-31 12:51:43 UTC (rev 8056) @@ -206,6 +206,22 @@ self._idle = True if d: QtCore.QTimer.singleShot(0, idle_draw) + +# XXX Hackish fix: There's a bug in PyQt. See this thread for details: +# http://old.nabble.com/Qt4-backend:-critical-bug-with-PyQt4-v4.6%2B-td26205716.html +# Once a release of Qt/PyQt is available without the bug, the version check +# below can be tightened further to only be applied in the necessary versions. +if Qt.PYQT_VERSION_STR.startswith('4.6'): + class FigureWindow(QtGui.QMainWindow): + def __init__(self): + super(FigureWindow, self).__init__() + def closeEvent(self, event): + super(FigureWindow, self).closeEvent(event) + self.emit(Qt.SIGNAL('destroyed()')) +else: + FigureWindow = QtGui.QMainWindow +# /end pyqt hackish bugfix + class FigureManagerQT( FigureManagerBase ): """ Public attributes @@ -220,7 +236,7 @@ if DEBUG: print 'FigureManagerQT.%s' % fn_name() FigureManagerBase.__init__( self, canvas, num ) self.canvas = canvas - self.window = QtGui.QMainWindow() + self.window = FigureWindow() self.window.setAttribute(QtCore.Qt.WA_DeleteOnClose) self.window.setWindowTitle("Figure %d" % num) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <md...@us...> - 2009-12-31 15:49:05
|
Revision: 8058 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8058&view=rev Author: mdboom Date: 2009-12-31 15:48:55 +0000 (Thu, 31 Dec 2009) Log Message: ----------- Merged revisions 8016,8036,8057 via svnmerge from https://matplotlib.svn.sf.net/svnroot/matplotlib/branches/v0_99_maint ........ r8016 | heeres | 2009-12-09 19:09:03 -0500 (Wed, 09 Dec 2009) | 2 lines Mplot3d: fix scatter3d markers bug ........ r8036 | jdh2358 | 2009-12-16 14:21:44 -0500 (Wed, 16 Dec 2009) | 1 line add mpl book to index sidebar ........ r8057 | mdboom | 2009-12-31 10:46:58 -0500 (Thu, 31 Dec 2009) | 2 lines [2916753] Wrong API signature- yscale ........ Modified Paths: -------------- trunk/matplotlib/doc/_templates/indexsidebar.html trunk/matplotlib/lib/matplotlib/pyplot.py Property Changed: ---------------- trunk/matplotlib/ trunk/matplotlib/doc/pyplots/README trunk/matplotlib/doc/sphinxext/gen_gallery.py trunk/matplotlib/doc/sphinxext/gen_rst.py trunk/matplotlib/examples/misc/multiprocess.py trunk/matplotlib/examples/mplot3d/contour3d_demo.py trunk/matplotlib/examples/mplot3d/contourf3d_demo.py trunk/matplotlib/examples/mplot3d/polys3d_demo.py trunk/matplotlib/examples/mplot3d/scatter3d_demo.py trunk/matplotlib/examples/mplot3d/surface3d_demo.py trunk/matplotlib/examples/mplot3d/wire3d_demo.py trunk/matplotlib/lib/matplotlib/sphinxext/mathmpl.py trunk/matplotlib/lib/matplotlib/sphinxext/only_directives.py trunk/matplotlib/lib/matplotlib/sphinxext/plot_directive.py trunk/matplotlib/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png Property changes on: trunk/matplotlib ___________________________________________________________________ Modified: svnmerge-integrated - /branches/mathtex:1-7263 /branches/v0_99_maint:1-8003 + /branches/mathtex:1-7263 /branches/v0_99_maint:1-8057 Modified: svn:mergeinfo - /branches/v0_91_maint:5753-5771 /branches/v0_98_5_maint:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint:5753-5771 /branches/v0_98_5_maint:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Modified: trunk/matplotlib/doc/_templates/indexsidebar.html =================================================================== --- trunk/matplotlib/doc/_templates/indexsidebar.html 2009-12-31 15:46:58 UTC (rev 8057) +++ trunk/matplotlib/doc/_templates/indexsidebar.html 2009-12-31 15:48:55 UTC (rev 8058) @@ -9,6 +9,12 @@ pathto('users/installing') }}">installing</a> </p> +<p>Sandro Tosi has a new book +<a href="http://www.packtpub.com/matplotlib-python-development/book">Matplotlib for python +developers</a> +also +at <a href="http://www.amazon.com/Matplotlib-Python-Developers-Sandro-Tosi/dp/1847197906">amazon</a>.</p> + <p>Build websites like matplotlib's, with <a href="http://sphinx.pocoo.org/">sphinx</a> and extensions for mpl plots, math, inheritance diagrams -- try Property changes on: trunk/matplotlib/doc/pyplots/README ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_98_5_maint/doc/pyplots/README:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/pyplots/README:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_98_5_maint/doc/pyplots/README:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/pyplots/README:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/doc/sphinxext/gen_gallery.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/_templates/gen_gallery.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_gallery.py:6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_gallery.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/doc/_templates/gen_gallery.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_gallery.py:6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_gallery.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/doc/sphinxext/gen_rst.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/examples/gen_rst.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_rst.py:6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_rst.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/doc/examples/gen_rst.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_rst.py:6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_rst.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/misc/multiprocess.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/misc/log.py:5753-5771 /branches/v0_98_5_maint/examples/misc/log.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/misc/multiprocess.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/misc/log.py:5753-5771 /branches/v0_98_5_maint/examples/misc/log.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/misc/multiprocess.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/mplot3d/contour3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/contour.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contour.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contour3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/mplot3d/contour.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contour.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contour3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/mplot3d/contourf3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/contourf.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contourf.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contourf3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/mplot3d/contourf.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contourf.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contourf3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/mplot3d/polys3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/polys.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/polys.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/polys3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/mplot3d/polys.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/polys.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/polys3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/mplot3d/scatter3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/scatter.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/scatter.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/scatter3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/mplot3d/scatter.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/scatter.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/scatter3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/mplot3d/surface3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/surface.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/surface.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/surface3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/mplot3d/surface.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/surface.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/surface3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/examples/mplot3d/wire3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/wire.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/wire.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/wire3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/examples/mplot3d/wire.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/wire.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/wire3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Modified: trunk/matplotlib/lib/matplotlib/pyplot.py =================================================================== --- trunk/matplotlib/lib/matplotlib/pyplot.py 2009-12-31 15:46:58 UTC (rev 8057) +++ trunk/matplotlib/lib/matplotlib/pyplot.py 2009-12-31 15:48:55 UTC (rev 8058) @@ -945,7 +945,7 @@ """ call signature:: - xscale(scale, **kwargs) + yscale(scale, **kwargs) Set the scaling for the y-axis: %(scale)s Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/mathmpl.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/mathmpl.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/mathmpl.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/mathmpl.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/doc/sphinxext/mathmpl.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/mathmpl.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/mathmpl.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/only_directives.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/only_directives.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/only_directives.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/only_directives.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/doc/sphinxext/only_directives.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/only_directives.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/only_directives.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/plot_directive.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/plot_directive.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/plot_directive.py:6920-6925,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/plot_directive.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_91_maint/doc/sphinxext/plot_directive.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/plot_directive.py:6920-6925,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/plot_directive.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 Property changes on: trunk/matplotlib/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_99_maint/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png:7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003 + /branches/v0_99_maint/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png:7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <md...@us...> - 2009-12-31 16:46:06
|
Revision: 8059 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8059&view=rev Author: mdboom Date: 2009-12-31 16:45:59 +0000 (Thu, 31 Dec 2009) Log Message: ----------- Add support for mathtext markers (thanks to tcb for original work) Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/examples/pylab_examples/line_styles.py trunk/matplotlib/lib/matplotlib/cbook.py trunk/matplotlib/lib/matplotlib/lines.py trunk/matplotlib/lib/matplotlib/text.py trunk/matplotlib/src/_path.cpp Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2009-12-31 15:48:55 UTC (rev 8058) +++ trunk/matplotlib/CHANGELOG 2009-12-31 16:45:59 UTC (rev 8059) @@ -1,3 +1,6 @@ +2009-12-31 Add support for using math text as marker symbols (Thanks to tcb) + - MGD + 2009-12-31 Commit a workaround for a regression in PyQt4-4.6.{0,1} - DSD 2009-12-22 Fix cmap data for gist_earth_r, etc. -JJL @@ -20,7 +23,7 @@ Added new examples. - JJL 2009-12-01 Applied Laurent Dufrechou's patch to improve blitting with - the qt4 backend - DSD + the qt4 backend - DSD 2009-11-13 The pdf backend now allows changing the contents of a pdf file's information dictionary via PdfPages.infodict. - JKS @@ -153,35 +156,35 @@ 2009-08-06 Tagging the 0.99.0 release at svn r7397 - JDH - * fixed an alpha colormapping bug posted on sf 2832575 + * fixed an alpha colormapping bug posted on sf 2832575 - * fix typo in axes_divider.py. use nanmin, nanmax in angle_helper.py + * fix typo in axes_divider.py. use nanmin, nanmax in angle_helper.py (patch by Christoph Gohlke) - * remove dup gui event in enter/leave events in gtk + * remove dup gui event in enter/leave events in gtk - * lots of fixes for os x binaries (Thanks Russell Owen) + * lots of fixes for os x binaries (Thanks Russell Owen) - * attach gtk events to mpl events -- fixes sf bug 2816580 + * attach gtk events to mpl events -- fixes sf bug 2816580 - * applied sf patch 2815064 (middle button events for wx) and + * applied sf patch 2815064 (middle button events for wx) and patch 2818092 (resize events for wx) - * fixed boilerplate.py so it doesn't break the ReST docs. + * fixed boilerplate.py so it doesn't break the ReST docs. - * removed a couple of cases of mlab.load + * removed a couple of cases of mlab.load - * fixed rec2csv win32 file handle bug from sf patch 2831018 + * fixed rec2csv win32 file handle bug from sf patch 2831018 - * added two examples from Josh Hemann: examples/pylab_examples/barchart_demo2.py + * added two examples from Josh Hemann: examples/pylab_examples/barchart_demo2.py and examples/pylab_examples/boxplot_demo2.py - * handled sf bugs 2831556 and 2830525; better bar error messages and + * handled sf bugs 2831556 and 2830525; better bar error messages and backend driver configs - * added miktex win32 patch from sf patch 2820194 + * added miktex win32 patch from sf patch 2820194 - * apply sf patches 2830233 and 2823885 for osx setup and 64 bit; thanks Michiel + * apply sf patches 2830233 and 2823885 for osx setup and 64 bit; thanks Michiel 2009-08-04 Made cbook.get_sample_data make use of the ETag and Last-Modified headers of mod_dav_svn. - JKS Modified: trunk/matplotlib/examples/pylab_examples/line_styles.py =================================================================== --- trunk/matplotlib/examples/pylab_examples/line_styles.py 2009-12-31 15:48:55 UTC (rev 8058) +++ trunk/matplotlib/examples/pylab_examples/line_styles.py 2009-12-31 16:45:59 UTC (rev 8059) @@ -17,19 +17,28 @@ except TypeError: pass -styles = linestyles + markers +styles = markers + [ + r'$\lambda$', + r'$\bowtie$', + r'$\circlearrowleft$', + r'$\clubsuit$', + r'$\checkmark$'] colors = ('b', 'g', 'r', 'c', 'm', 'y', 'k') +plt.figure(figsize=(8,8)) axisNum = 0 -for row in range(5): +for row in range(6): for col in range(5): axisNum += 1 - ax = plt.subplot(5, 5, axisNum) - style = styles[axisNum % len(styles) ] - color = colors[axisNum % len(colors) ] - plt.plot(t,s, style + color, markersize=10) + ax = plt.subplot(6, 5, axisNum) + color = colors[axisNum % len(colors)] + if axisNum < len(linestyles): + plt.plot(t, s, linestyles[axisNum], color=color, markersize=10) + else: + style = styles[(axisNum - len(linestyles)) % len(styles)] + plt.plot(t, s, linestyle='None', marker=style, color=color, markersize=10) ax.set_yticklabels([]) ax.set_xticklabels([]) Modified: trunk/matplotlib/lib/matplotlib/cbook.py =================================================================== --- trunk/matplotlib/lib/matplotlib/cbook.py 2009-12-31 15:48:55 UTC (rev 8058) +++ trunk/matplotlib/lib/matplotlib/cbook.py 2009-12-31 16:45:59 UTC (rev 8059) @@ -1676,8 +1676,17 @@ else: break +def is_math_text(s): + # Did we find an even number of non-escaped dollar signs? + # If so, treat is as math text. + s = unicode(s) + dollar_count = s.count(r'$') - s.count(r'\$') + even_dollars = (dollar_count > 0 and dollar_count % 2 == 0) + return even_dollars + + if __name__=='__main__': assert( allequal([1,1,1]) ) assert(not allequal([1,1,0]) ) Modified: trunk/matplotlib/lib/matplotlib/lines.py =================================================================== --- trunk/matplotlib/lib/matplotlib/lines.py 2009-12-31 15:48:55 UTC (rev 8058) +++ trunk/matplotlib/lib/matplotlib/lines.py 2009-12-31 16:45:59 UTC (rev 8059) @@ -12,7 +12,7 @@ import artist from artist import Artist from cbook import iterable, is_string_like, is_numlike, ls_mapper, dedent,\ -flatten +flatten, is_math_text from colors import colorConverter from path import Path from transforms import Affine2D, Bbox, TransformedPath, IdentityTransform @@ -20,6 +20,7 @@ from matplotlib import rcParams from artist import allow_rasterization from matplotlib import docstring +from matplotlib.font_manager import FontProperties # special-purpose marker identifiers: (TICKLEFT, TICKRIGHT, TICKUP, TICKDOWN, @@ -139,7 +140,7 @@ } filled_markers = ('o', '^', 'v', '<', '>', - 's', 'd', 'D', 'h', 'H', 'p', '*') + 's', 'd', 'D', 'h', 'H', 'p', '*') zorder = 2 validCap = ('butt', 'round', 'projecting') @@ -535,7 +536,7 @@ gc.set_foreground(self.get_markeredgecolor()) gc.set_linewidth(self._markeredgewidth) gc.set_alpha(self._alpha) - funcname = self._markers.get(self._marker, '_draw_nothing') + funcname = self._markerFunc if funcname != '_draw_nothing': tpath, affine = self._transformed_path.get_transformed_points_and_affine() if len(tpath.vertices): @@ -573,7 +574,8 @@ def get_markeredgecolor(self): if (is_string_like(self._markeredgecolor) and self._markeredgecolor == 'auto'): - if self._marker in self.filled_markers: + if (self._marker in self.filled_markers or + is_math_text(self._marker)): return 'k' else: return self._color @@ -774,6 +776,7 @@ 'None' nothing ' ' nothing '' nothing + '$...$' render the string using mathtext ========== ========================== @@ -782,16 +785,18 @@ | '<' | '>' | 'D' | 'H' | '^' | '_' | 'd' | 'h' | 'o' | 'p' | 's' | 'v' | 'x' | '|' | TICKUP | TICKDOWN | TICKLEFT | TICKRIGHT - | 'None' | ' ' | '' ] + | 'None' | ' ' | '' | '$...$'] """ - if marker not in self._markers: + if marker in self._markers: + self._marker = marker + self._markerFunc = self._markers[marker] + elif is_math_text(marker): + self._marker = marker + self._markerFunc = '_draw_mathtext_path' + else: #already handle ' ', '' in marker list verbose.report('Unrecognized marker style %s, %s' % (marker, type(marker))) - if marker in [' ','']: - marker = 'None' - self._marker = marker - self._markerFunc = self._markers[marker] def set_markeredgecolor(self, ec): """ @@ -867,6 +872,38 @@ def _draw_lines(self, renderer, gc, path, trans): self._lineFunc(renderer, gc, path, trans) + def _draw_mathtext_path(self, renderer, gc, path, trans): + """ + Draws mathtext markers '$...$' using TextPath object. + + Submitted by tcb + """ + from matplotlib.patches import PathPatch + from matplotlib.text import TextPath + + gc.set_snap(False) + + # again, the properties could be initialised just once outside + # this function + # Font size is irrelevant here, it will be rescaled based on + # the drawn size later + props = FontProperties(size=1.0) + text = TextPath(xy=(0,0), s=self.get_marker(), fontproperties=props, + usetex=rcParams['text.usetex']) + if len(text.vertices) == 0: + return + xmin, ymin = text.vertices.min(axis=0) + xmax, ymax = text.vertices.max(axis=0) + width = xmax - xmin + height = ymax - ymin + max_dim = max(width, height) + path_trans = Affine2D() \ + .translate(0.5 * -width, 0.5 * -height) \ + .scale((renderer.points_to_pixels(self.get_markersize()) / max_dim)) + + rgbFace = self._get_rgb_face() + renderer.draw_markers(gc, text, path_trans, path, trans, rgbFace) + def _draw_steps_pre(self, renderer, gc, path, trans): vertices = self._xy steps = ma.zeros((2*len(vertices)-1, 2), np.float_) @@ -1288,6 +1325,7 @@ self._linestyle = other._linestyle self._marker = other._marker + self._markerFunc = other._markerFunc self._drawstyle = other._drawstyle Modified: trunk/matplotlib/lib/matplotlib/text.py =================================================================== --- trunk/matplotlib/lib/matplotlib/text.py 2009-12-31 15:48:55 UTC (rev 8058) +++ trunk/matplotlib/lib/matplotlib/text.py 2009-12-31 16:45:59 UTC (rev 8059) @@ -997,13 +997,10 @@ """ # Did we find an even number of non-escaped dollar signs? # If so, treat is as math text. - dollar_count = s.count(r'$') - s.count(r'\$') - even_dollars = (dollar_count > 0 and dollar_count % 2 == 0) - if rcParams['text.usetex']: return s, 'TeX' - if even_dollars: + if cbook.is_math_text(s): return s, True else: return s.replace(r'\$', '$'), False Modified: trunk/matplotlib/src/_path.cpp =================================================================== --- trunk/matplotlib/src/_path.cpp 2009-12-31 15:48:55 UTC (rev 8058) +++ trunk/matplotlib/src/_path.cpp 2009-12-31 16:45:59 UTC (rev 8059) @@ -922,9 +922,13 @@ vertices = (PyArrayObject*)PyArray_FromObject (vertices_obj.ptr(), PyArray_DOUBLE, 1, 2); if (!vertices || - (PyArray_NDIM(vertices) == 2 && PyArray_DIM(vertices, 1) != 2) || - (PyArray_NDIM(vertices) == 1 && PyArray_DIM(vertices, 0) != 2)) + (PyArray_NDIM(vertices) == 2 && PyArray_DIM(vertices, 0) != 0 && + PyArray_DIM(vertices, 1) != 2) || + (PyArray_NDIM(vertices) == 1 && + PyArray_DIM(vertices, 0) != 2 && PyArray_DIM(vertices, 0) != 0)) + { throw Py::ValueError("Invalid vertices array."); + } transform = (PyArrayObject*) PyArray_FromObject (transform_obj.ptr(), PyArray_DOUBLE, 2, 2); @@ -979,7 +983,7 @@ vertex_in += stride0; } } - else + else if (PyArray_DIM(vertices, 0) != 0) { char* vertex_in = PyArray_BYTES(vertices); double* vertex_out = (double*)PyArray_DATA(result); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jd...@us...> - 2010-01-03 18:30:11
|
Revision: 8064 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8064&view=rev Author: jdh2358 Date: 2010-01-03 18:30:04 +0000 (Sun, 03 Jan 2010) Log Message: ----------- added qt4_editor dialog Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py trunk/matplotlib/setup.py Added Paths: ----------- trunk/matplotlib/lib/matplotlib/backends/qt4_editor/ trunk/matplotlib/lib/matplotlib/backends/qt4_editor/__init__.py trunk/matplotlib/lib/matplotlib/backends/qt4_editor/figureoptions.py trunk/matplotlib/lib/matplotlib/backends/qt4_editor/formlayout.py trunk/matplotlib/license/LICENSE_QT4_EDITOR Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-02 06:30:15 UTC (rev 8063) +++ trunk/matplotlib/CHANGELOG 2010-01-03 18:30:04 UTC (rev 8064) @@ -1,3 +1,5 @@ +2010-01-03 Added Pierre's qt4 formlayout editor and toolbar button - JDH + 2009-12-31 Add support for using math text as marker symbols (Thanks to tcb) - MGD Modified: trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py 2010-01-02 06:30:15 UTC (rev 8063) +++ trunk/matplotlib/lib/matplotlib/backends/backend_qt4.py 2010-01-03 18:30:04 UTC (rev 8064) @@ -12,6 +12,7 @@ from matplotlib.figure import Figure from matplotlib.mathtext import MathTextParser from matplotlib.widgets import SubplotTool +import matplotlib.backends.qt4_editor.figureoptions as figureoptions try: from PyQt4 import QtCore, QtGui, Qt @@ -330,10 +331,16 @@ a = self.addAction(self._icon('subplots.png'), 'Subplots', self.configure_subplots) a.setToolTip('Configure subplots') + + a = self.addAction(self._icon("qt4_editor_options.svg"), + 'Customize', self.edit_parameters) + a.setToolTip('Edit curves line and axes parameters') + a = self.addAction(self._icon('filesave.svg'), 'Save', self.save_figure) a.setToolTip('Save the figure') + self.buttons = {} # Add the x,y location widget at the right side of the toolbar @@ -352,6 +359,36 @@ # reference holder for subplots_adjust window self.adj_window = None + def edit_parameters(self): + allaxes = self.canvas.figure.get_axes() + if len(allaxes) == 1: + axes = allaxes[0] + else: + titles = [] + for axes in allaxes: + title = axes.get_title() + ylabel = axes.get_ylabel() + if title: + text = title + if ylabel: + text += ": "+ylabel + text += " (%s)" + elif ylabel: + text = "%s (%s)" % ylabel + else: + text = "%s" + titles.append(text % repr(axes)) + item, ok = QtGui.QInputDialog.getItem(self, 'Customize', + 'Select axes:', titles, + 0, False) + if ok: + axes = allaxes[titles.index(unicode(item))] + else: + return + + figureoptions.figure_edit(axes, self) + + def dynamic_update( self ): self.canvas.draw() Added: trunk/matplotlib/lib/matplotlib/backends/qt4_editor/figureoptions.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/qt4_editor/figureoptions.py (rev 0) +++ trunk/matplotlib/lib/matplotlib/backends/qt4_editor/figureoptions.py 2010-01-03 18:30:04 UTC (rev 8064) @@ -0,0 +1,154 @@ +# -*- coding: utf-8 -*- +# +# Copyright © 2009 Pierre Raybaut +# Licensed under the terms of the MIT License +# see the mpl licenses directory for a copy of the license + +"""Module that provides a GUI-based editor for matplotlib's figure options""" + +import os.path as osp + +import matplotlib.backends.qt4_editor.formlayout as formlayout +from PyQt4.QtGui import QIcon + +def get_icon(name): + import matplotlib + basedir = osp.join(matplotlib.rcParams['datapath'], 'images') + return QIcon(osp.join(basedir, name)) + +LINESTYLES = { + '-': 'Solid', + '--': 'Dashed', + '-.': 'DashDot', + ':': 'Dotted', + 'steps': 'Steps', + 'none': 'None', + } + +MARKERS = { + 'none': 'None', + 'o': 'circles', + '^': 'triangle_up', + 'v': 'triangle_down', + '<': 'triangle_left', + '>': 'triangle_right', + 's': 'square', + '+': 'plus', + 'x': 'cross', + '*': 'star', + 'D': 'diamond', + 'd': 'thin_diamond', + '1': 'tripod_down', + '2': 'tripod_up', + '3': 'tripod_left', + '4': 'tripod_right', + 'h': 'hexagon', + 'H': 'rotated_hexagon', + 'p': 'pentagon', + '|': 'vertical_line', + '_': 'horizontal_line', + '.': 'dots', + } + +COLORS = {'b': '#0000ff', 'g': '#00ff00', 'r': '#ff0000', 'c': '#ff00ff', + 'm': '#ff00ff', 'y': '#ffff00', 'k': '#000000', 'w': '#ffffff'} + +def col2hex(color): + """Convert matplotlib color to hex""" + return COLORS.get(color, color) + +def figure_edit(axes, parent=None): + """Edit matplotlib figure options""" + sep = (None, None) # separator + + has_curve = len(axes.get_lines()) > 0 + + # Get / General + xmin, xmax = axes.get_xlim() + ymin, ymax = axes.get_ylim() + general = [('Title', axes.get_title()), + sep, + (None, "<b>X-Axis</b>"), + ('Min', xmin), ('Max', xmax), + ('Label', axes.get_xlabel()), + ('Scale', [axes.get_xscale(), 'linear', 'log']), + sep, + (None, "<b>Y-Axis</b>"), + ('Min', ymin), ('Max', ymax), + ('Label', axes.get_ylabel()), + ('Scale', [axes.get_yscale(), 'linear', 'log']) + ] + + if has_curve: + # Get / Curves + linedict = {} + for line in axes.get_lines(): + label = line.get_label() + if label == '_nolegend_': + continue + linedict[label] = line + curves = [] + linestyles = LINESTYLES.items() + markers = MARKERS.items() + curvelabels = sorted(linedict.keys()) + for label in curvelabels: + line = linedict[label] + curvedata = [ + ('Label', label), + sep, + (None, '<b>Line</b>'), + ('Style', [line.get_linestyle()] + linestyles), + ('Width', line.get_linewidth()), + ('Color', col2hex(line.get_color())), + sep, + (None, '<b>Marker</b>'), + ('Style', [line.get_marker()] + markers), + ('Size', line.get_markersize()), + ('Facecolor', col2hex(line.get_markerfacecolor())), + ('Edgecolor', col2hex(line.get_markeredgecolor())), + ] + curves.append([curvedata, label, ""]) + + datalist = [(general, "Axes", "")] + if has_curve: + datalist.append((curves, "Curves", "")) + result = formlayout.fedit(datalist, title="Figure options", parent=parent, + icon=get_icon('qt4_editor_options.svg')) + if result is None: + return + + if has_curve: + general, curves = result + else: + general, = result + + # Set / General + title, xmin, xmax, xlabel, xscale, ymin, ymax, ylabel, yscale = general + axes.set_xscale(xscale) + axes.set_yscale(yscale) + axes.set_title(title) + axes.set_xlim(xmin, xmax) + axes.set_xlabel(xlabel) + axes.set_ylim(ymin, ymax) + axes.set_ylabel(ylabel) + + if has_curve: + # Set / Curves + for index, curve in enumerate(curves): + line = linedict[curvelabels[index]] + label, linestyle, linewidth, color, \ + marker, markersize, markerfacecolor, markeredgecolor = curve + line.set_label(label) + line.set_linestyle(linestyle) + line.set_linewidth(linewidth) + line.set_color(color) + if marker is not 'none': + line.set_marker(marker) + line.set_markersize(markersize) + line.set_markerfacecolor(markerfacecolor) + line.set_markeredgecolor(markeredgecolor) + + # Redraw + figure = axes.get_figure() + figure.canvas.draw() + Added: trunk/matplotlib/lib/matplotlib/backends/qt4_editor/formlayout.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/qt4_editor/formlayout.py (rev 0) +++ trunk/matplotlib/lib/matplotlib/backends/qt4_editor/formlayout.py 2010-01-03 18:30:04 UTC (rev 8064) @@ -0,0 +1,487 @@ +# -*- coding: utf-8 -*- +""" +formlayout +========== + +Module creating PyQt4 form dialogs/layouts to edit various type of parameters + + +formlayout License Agreement (MIT License) +------------------------------------------ + +Copyright (c) 2009 Pierre Raybaut + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. +""" + +__version__ = '1.0.5' +__license__ = __doc__ + +DEBUG = False + +import sys +STDERR = sys.stderr + +try: + from PyQt4.QtGui import QFormLayout +except ImportError: + raise ImportError, "Warning: formlayout requires PyQt4 >v4.3" + +from PyQt4.QtGui import (QWidget, QLineEdit, QComboBox, QLabel, QSpinBox, QIcon, + QStyle, QDialogButtonBox, QHBoxLayout, QVBoxLayout, + QDialog, QColor, QPushButton, QCheckBox, QColorDialog, + QPixmap, QTabWidget, QApplication, QStackedWidget, + QDateEdit, QDateTimeEdit, QFont, QFontComboBox, + QFontDatabase, QGridLayout) +from PyQt4.QtCore import (Qt, SIGNAL, SLOT, QSize, QString, + pyqtSignature, pyqtProperty) +from datetime import date + + +class ColorButton(QPushButton): + """ + Color choosing push button + """ + __pyqtSignals__ = ("colorChanged(QColor)",) + + def __init__(self, parent=None): + QPushButton.__init__(self, parent) + self.setFixedSize(20, 20) + self.setIconSize(QSize(12, 12)) + self.connect(self, SIGNAL("clicked()"), self.chooseColor) + self._color = QColor() + + def chooseColor(self): + rgba, valid = QColorDialog.getRgba(self._color.rgba(), + self.parentWidget()) + if valid: + color = QColor.fromRgba(rgba) + self.setColor(color) + + def color(self): + return self._color + + @pyqtSignature("QColor") + def setColor(self, color): + if color != self._color: + self._color = color + self.emit(SIGNAL("colorChanged(QColor)"), self._color) + pixmap = QPixmap(self.iconSize()) + pixmap.fill(color) + self.setIcon(QIcon(pixmap)) + + color = pyqtProperty("QColor", color, setColor) + + +def text_to_qcolor(text): + """ + Create a QColor from specified string + Avoid warning from Qt when an invalid QColor is instantiated + """ + color = QColor() + if isinstance(text, QString): + text = str(text) + if not isinstance(text, (unicode, str)): + return color + if text.startswith('#') and len(text)==7: + correct = '#0123456789abcdef' + for char in text: + if char.lower() not in correct: + return color + elif text not in list(QColor.colorNames()): + return color + color.setNamedColor(text) + return color + + +class ColorLayout(QHBoxLayout): + """Color-specialized QLineEdit layout""" + def __init__(self, color, parent=None): + QHBoxLayout.__init__(self) + assert isinstance(color, QColor) + self.lineedit = QLineEdit(color.name(), parent) + self.connect(self.lineedit, SIGNAL("textChanged(QString)"), + self.update_color) + self.addWidget(self.lineedit) + self.colorbtn = ColorButton(parent) + self.colorbtn.color = color + self.connect(self.colorbtn, SIGNAL("colorChanged(QColor)"), + self.update_text) + self.addWidget(self.colorbtn) + + def update_color(self, text): + color = text_to_qcolor(text) + if color.isValid(): + self.colorbtn.color = color + + def update_text(self, color): + self.lineedit.setText(color.name()) + + def text(self): + return self.lineedit.text() + + +def font_is_installed(font): + """Check if font is installed""" + return [fam for fam in QFontDatabase().families() if unicode(fam)==font] + +def tuple_to_qfont(tup): + """ + Create a QFont from tuple: + (family [string], size [int], italic [bool], bold [bool]) + """ + if not isinstance(tup, tuple) or len(tup) != 4 \ + or not font_is_installed(tup[0]) \ + or not isinstance(tup[1], int) \ + or not isinstance(tup[2], bool) \ + or not isinstance(tup[3], bool): + return None + font = QFont() + family, size, italic, bold = tup + font.setFamily(family) + font.setPointSize(size) + font.setItalic(italic) + font.setBold(bold) + return font + +def qfont_to_tuple(font): + return (unicode(font.family()), int(font.pointSize()), + font.italic(), font.bold()) + + +class FontLayout(QGridLayout): + """Font selection""" + def __init__(self, value, parent=None): + QGridLayout.__init__(self) + font = tuple_to_qfont(value) + assert font is not None + + # Font family + self.family = QFontComboBox(parent) + self.family.setCurrentFont(font) + self.addWidget(self.family, 0, 0, 1, -1) + + # Font size + self.size = QComboBox(parent) + self.size.setEditable(True) + sizelist = range(6, 12) + range(12, 30, 2) + [36, 48, 72] + size = font.pointSize() + if size not in sizelist: + sizelist.append(size) + sizelist.sort() + self.size.addItems([str(s) for s in sizelist]) + self.size.setCurrentIndex(sizelist.index(size)) + self.addWidget(self.size, 1, 0) + + # Italic or not + self.italic = QCheckBox(self.tr("Italic"), parent) + self.italic.setChecked(font.italic()) + self.addWidget(self.italic, 1, 1) + + # Bold or not + self.bold = QCheckBox(self.tr("Bold"), parent) + self.bold.setChecked(font.bold()) + self.addWidget(self.bold, 1, 2) + + def get_font(self): + font = self.family.currentFont() + font.setItalic(self.italic.isChecked()) + font.setBold(self.bold.isChecked()) + font.setPointSize(int(self.size.currentText())) + return qfont_to_tuple(font) + + +class FormWidget(QWidget): + def __init__(self, data, comment="", parent=None): + super(FormWidget, self).__init__(parent) + from copy import deepcopy + self.data = deepcopy(data) + self.widgets = [] + self.formlayout = QFormLayout(self) + if comment: + self.formlayout.addRow(QLabel(comment)) + self.formlayout.addRow(QLabel(" ")) + if DEBUG: + print "\n"+("*"*80) + print "DATA:", self.data + print "*"*80 + print "COMMENT:", comment + print "*"*80 + self.setup() + + def setup(self): + for label, value in self.data: + if DEBUG: + print "value:", value + if label is None and value is None: + # Separator: (None, None) + self.formlayout.addRow(QLabel(" "), QLabel(" ")) + self.widgets.append(None) + continue + elif label is None: + # Comment + self.formlayout.addRow(QLabel(value)) + self.widgets.append(None) + continue + elif tuple_to_qfont(value) is not None: + field = FontLayout(value, self) + elif text_to_qcolor(value).isValid(): + field = ColorLayout(QColor(value), self) + elif isinstance(value, (str, unicode)): + field = QLineEdit(value, self) + elif isinstance(value, (list, tuple)): + selindex = value.pop(0) + field = QComboBox(self) + if isinstance(value[0], (list, tuple)): + keys = [ key for key, _val in value ] + value = [ val for _key, val in value ] + else: + keys = value + field.addItems(value) + if selindex in value: + selindex = value.index(selindex) + elif selindex in keys: + selindex = keys.index(selindex) + elif not isinstance(selindex, int): + print >>STDERR, "Warning: '%s' index is invalid (label: " \ + "%s, value: %s)" % (selindex, label, value) + selindex = 0 + field.setCurrentIndex(selindex) + elif isinstance(value, bool): + field = QCheckBox(self) + field.setCheckState(Qt.Checked if value else Qt.Unchecked) + elif isinstance(value, float): + field = QLineEdit(repr(value), self) + elif isinstance(value, int): + field = QSpinBox(self) + field.setValue(value) + field.setMaximum(1e9) + elif isinstance(value, date): + if hasattr(value, 'hour'): + field = QDateTimeEdit(self) + field.setDateTime(value) + else: + field = QDateEdit(self) + field.setDate(value) + else: + field = QLineEdit(repr(value), self) + self.formlayout.addRow(label, field) + self.widgets.append(field) + + def get(self): + valuelist = [] + for index, (label, value) in enumerate(self.data): + field = self.widgets[index] + if label is None: + # Separator / Comment + continue + elif tuple_to_qfont(value) is not None: + value = field.get_font() + elif isinstance(value, (str, unicode)): + value = unicode(field.text()) + elif isinstance(value, (list, tuple)): + index = int(field.currentIndex()) + if isinstance(value[0], (list, tuple)): + value = value[index][0] + else: + value = value[index] + elif isinstance(value, bool): + value = field.checkState() == Qt.Checked + elif isinstance(value, float): + value = float(field.text()) + elif isinstance(value, int): + value = int(field.value()) + elif isinstance(value, date): + if hasattr(value, 'hour'): + value = field.dateTime().toPyDateTime() + else: + value = field.date().toPyDate() + else: + value = eval(str(field.text())) + valuelist.append(value) + return valuelist + + +class FormComboWidget(QWidget): + def __init__(self, datalist, comment="", parent=None): + super(FormComboWidget, self).__init__(parent) + layout = QVBoxLayout() + self.setLayout(layout) + self.combobox = QComboBox() + layout.addWidget(self.combobox) + + self.stackwidget = QStackedWidget(self) + layout.addWidget(self.stackwidget) + self.connect(self.combobox, SIGNAL("currentIndexChanged(int)"), + self.stackwidget, SLOT("setCurrentIndex(int)")) + + self.widgetlist = [] + for data, title, comment in datalist: + self.combobox.addItem(title) + widget = FormWidget(data, comment=comment, parent=self) + self.stackwidget.addWidget(widget) + self.widgetlist.append(widget) + + def get(self): + return [ widget.get() for widget in self.widgetlist] + + +class FormTabWidget(QWidget): + def __init__(self, datalist, comment="", parent=None): + super(FormTabWidget, self).__init__(parent) + layout = QVBoxLayout() + self.tabwidget = QTabWidget() + layout.addWidget(self.tabwidget) + self.setLayout(layout) + self.widgetlist = [] + for data, title, comment in datalist: + if len(data[0])==3: + widget = FormComboWidget(data, comment=comment, parent=self) + else: + widget = FormWidget(data, comment=comment, parent=self) + index = self.tabwidget.addTab(widget, title) + self.tabwidget.setTabToolTip(index, comment) + self.widgetlist.append(widget) + + def get(self): + return [ widget.get() for widget in self.widgetlist] + + +class FormDialog(QDialog): + """Form Dialog""" + def __init__(self, data, title="", comment="", + icon=None, parent=None): + super(FormDialog, self).__init__(parent) + + # Form + if isinstance(data[0][0], (list, tuple)): + self.formwidget = FormTabWidget(data, comment=comment, + parent=self) + elif len(data[0])==3: + self.formwidget = FormComboWidget(data, comment=comment, + parent=self) + else: + self.formwidget = FormWidget(data, comment=comment, + parent=self) + layout = QVBoxLayout() + layout.addWidget(self.formwidget) + + # Button box + bbox = QDialogButtonBox(QDialogButtonBox.Ok | QDialogButtonBox.Cancel) + self.connect(bbox, SIGNAL("accepted()"), SLOT("accept()")) + self.connect(bbox, SIGNAL("rejected()"), SLOT("reject()")) + layout.addWidget(bbox) + + self.setLayout(layout) + + self.setWindowTitle(title) + if not isinstance(icon, QIcon): + icon = QWidget().style().standardIcon(QStyle.SP_MessageBoxQuestion) + self.setWindowIcon(icon) + + def accept(self): + self.data = self.formwidget.get() + QDialog.accept(self) + + def reject(self): + self.data = None + QDialog.reject(self) + + def get(self): + """Return form result""" + return self.data + + +def fedit(data, title="", comment="", icon=None, parent=None): + """ + Create form dialog and return result + (if Cancel button is pressed, return None) + + data: datalist, datagroup + + datalist: list/tuple of (field_name, field_value) + datagroup: list/tuple of (datalist *or* datagroup, title, comment) + + -> one field for each member of a datalist + -> one tab for each member of a top-level datagroup + -> one page (of a multipage widget, each page can be selected with a combo + box) for each member of a datagroup inside a datagroup + + Supported types for field_value: + - int, float, str, unicode, bool + - colors: in Qt-compatible text form, i.e. in hex format or name (red,...) + (automatically detected from a string) + - list/tuple: + * the first element will be the selected index (or value) + * the other elements can be couples (key, value) or only values + """ + + # Create a QApplication instance if no instance currently exists + # (e.g. if the module is used directly from the interpreter) + if QApplication.startingUp(): + QApplication([]) + + dialog = FormDialog(data, title, comment, icon, parent) + if dialog.exec_(): + return dialog.get() + + + +if __name__ == "__main__": + + def create_datalist_example(): + return [('str', 'this is a string'), + ('list', [0, '1', '3', '4']), + ('list2', ['--', ('none', 'None'), ('--', 'Dashed'), + ('-.', 'DashDot'), ('-', 'Solid'), + ('steps', 'Steps'), (':', 'Dotted')]), + ('float', 1.2), + (None, 'Other:'), + ('int', 12), + ('font', ('Arial', 10, False, True)), + ('color', '#123409'), + ('bool', True), + ('datetime', date(2010, 10, 10)), + ] + + def create_datagroup_example(): + datalist = create_datalist_example() + return ((datalist, "Category 1", "Category 1 comment"), + (datalist, "Category 2", "Category 2 comment"), + (datalist, "Category 3", "Category 3 comment")) + + #--------- datalist example + datalist = create_datalist_example() + print "result:", fedit(datalist, title="Example", + comment="This is just an <b>example</b>.") + + #--------- datagroup example + datagroup = create_datagroup_example() + print "result:", fedit(datagroup, "Global title") + + #--------- datagroup inside a datagroup example + datalist = create_datalist_example() + datagroup = create_datagroup_example() + print "result:", fedit(((datagroup, "Title 1", "Tab 1 comment"), + (datalist, "Title 2", "Tab 2 comment"), + (datalist, "Title 3", "Tab 3 comment")), + "Global title") Added: trunk/matplotlib/license/LICENSE_QT4_EDITOR =================================================================== --- trunk/matplotlib/license/LICENSE_QT4_EDITOR (rev 0) +++ trunk/matplotlib/license/LICENSE_QT4_EDITOR 2010-01-03 18:30:04 UTC (rev 8064) @@ -0,0 +1,30 @@ + +Module creating PyQt4 form dialogs/layouts to edit various type of parameters + + +formlayout License Agreement (MIT License) +------------------------------------------ + +Copyright (c) 2009 Pierre Raybaut + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. +""" Modified: trunk/matplotlib/setup.py =================================================================== --- trunk/matplotlib/setup.py 2010-01-02 06:30:15 UTC (rev 8063) +++ trunk/matplotlib/setup.py 2010-01-03 18:30:04 UTC (rev 8064) @@ -49,6 +49,7 @@ packages = [ 'matplotlib', 'matplotlib.backends', + 'matplotlib.backends.qt4_editor', 'matplotlib.projections', 'matplotlib.testing', 'matplotlib.testing.jpl_units', This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ef...@us...> - 2010-01-04 02:22:41
|
Revision: 8066 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8066&view=rev Author: efiring Date: 2010-01-04 02:22:26 +0000 (Mon, 04 Jan 2010) Log Message: ----------- Added rcParams['axes.color_cycle'] Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/doc/api/api_changes.rst trunk/matplotlib/examples/api/color_cycle.py trunk/matplotlib/lib/matplotlib/axes.py trunk/matplotlib/lib/matplotlib/rcsetup.py trunk/matplotlib/matplotlibrc.template Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-03 21:07:05 UTC (rev 8065) +++ trunk/matplotlib/CHANGELOG 2010-01-04 02:22:26 UTC (rev 8066) @@ -1,3 +1,5 @@ +2010-01-03 Added rcParams['axes.color_cycle'] - EF + 2010-01-03 Added Pierre's qt4 formlayout editor and toolbar button - JDH 2009-12-31 Add support for using math text as marker symbols (Thanks to tcb) Modified: trunk/matplotlib/doc/api/api_changes.rst =================================================================== --- trunk/matplotlib/doc/api/api_changes.rst 2010-01-03 21:07:05 UTC (rev 8065) +++ trunk/matplotlib/doc/api/api_changes.rst 2010-01-04 02:22:26 UTC (rev 8066) @@ -10,7 +10,11 @@ Changes beyond 0.99.x ===================== -* You can now print several figures to one pdf file and modify the +* There is a new rc parameter ``axes.color_cycle``, and the color + cycle is now independent of the rc parameter ``lines.color``. + :func:`matplotlib.Axes.set_default_color_cycle` is deprecated. + +* You can now print several figures to one pdf file and modify the document information dictionary of a pdf file. See the docstrings of the class :class:`matplotlib.backends.backend_pdf.PdfPages` for more information. Modified: trunk/matplotlib/examples/api/color_cycle.py =================================================================== --- trunk/matplotlib/examples/api/color_cycle.py 2010-01-03 21:07:05 UTC (rev 8065) +++ trunk/matplotlib/examples/api/color_cycle.py 2010-01-04 02:22:26 UTC (rev 8066) @@ -13,7 +13,7 @@ mpl.rc('lines', linewidth=4) fig = plt.figure() -mpl.axes.set_default_color_cycle(['r', 'g', 'b', 'c']) +mpl.rcParams['axes.color_cycle'] = ['r', 'g', 'b', 'c'] ax = fig.add_subplot(2,1,1) ax.plot(yy) ax.set_title('Changed default color cycle to rgbc') Modified: trunk/matplotlib/lib/matplotlib/axes.py =================================================================== --- trunk/matplotlib/lib/matplotlib/axes.py 2010-01-03 21:07:05 UTC (rev 8065) +++ trunk/matplotlib/lib/matplotlib/axes.py 2010-01-04 02:22:26 UTC (rev 8066) @@ -1,5 +1,7 @@ from __future__ import division, generators import math, sys, warnings, datetime, new +from operator import itemgetter +import itertools import numpy as np from numpy import ma @@ -31,7 +33,6 @@ import matplotlib.ticker as mticker import matplotlib.transforms as mtransforms -from operator import itemgetter iterable = cbook.iterable is_string_like = cbook.is_string_like @@ -115,12 +116,19 @@ :class:`Axes` to which it will apply; it will apply to all future axes. - *clist* is a sequence of mpl color specifiers + *clist* is a sequence of mpl color specifiers. + See also: :meth:`~matplotlib.axes.Axes.set_color_cycle`. + + .. Note:: Deprecated 2010/01/03. + Set rcParams['axes.color_cycle'] directly. + """ - _process_plot_var_args.defaultColors = clist[:] - rcParams['lines.color'] = clist[0] + rcParams['axes.color_cycle'] = clist + warnings.warn("Set rcParams['axes.color_cycle'] directly", + DeprecationWarning) + class _process_plot_var_args: """ @@ -134,42 +142,18 @@ an arbitrary number of *x*, *y*, *fmt* are allowed """ - - defaultColors = ['b','g','r','c','m','y','k'] def __init__(self, axes, command='plot'): self.axes = axes self.command = command - self._clear_color_cycle() + self.set_color_cycle() - def _clear_color_cycle(self): - self.colors = _process_plot_var_args.defaultColors[:] - # if the default line color is a color format string, move it up - # in the que - try: - ind = self.colors.index(rcParams['lines.color']) - except ValueError: - self.firstColor = rcParams['lines.color'] - else: - self.colors[0], self.colors[ind] = self.colors[ind], self.colors[0] - self.firstColor = self.colors[0] + def set_color_cycle(self, clist=None): + if clist is None: + clist = rcParams['axes.color_cycle'] + self._colors = itertools.cycle(clist) - self.Ncolors = len(self.colors) - - self.count = 0 - - def set_color_cycle(self, clist): - self.colors = clist[:] - self.firstColor = self.colors[0] - self.Ncolors = len(self.colors) - self.count = 0 - def _get_next_cycle_color(self): - if self.count==0: - color = self.firstColor - else: - color = self.colors[int(self.count % self.Ncolors)] - self.count += 1 - return color + return self._colors.next() def __call__(self, *args, **kwargs): @@ -907,9 +891,10 @@ """ Set the color cycle for any future plot commands on this Axes. - clist is a list of mpl color specifiers. + *clist* is a list of mpl color specifiers. """ self._get_lines.set_color_cycle(clist) + self._get_patches_for_fill.set_color_cycle(clist) def ishold(self): Modified: trunk/matplotlib/lib/matplotlib/rcsetup.py =================================================================== --- trunk/matplotlib/lib/matplotlib/rcsetup.py 2010-01-03 21:07:05 UTC (rev 8065) +++ trunk/matplotlib/lib/matplotlib/rcsetup.py 2010-01-04 02:22:26 UTC (rev 8066) @@ -207,6 +207,14 @@ raise ValueError('%s does not look like a color arg%s'%(s, msg)) +def validate_colorlist(s): + 'return a list of colorspecs' + if type(s) is str: + return [validate_color(c.strip()) for c in s.split(',')] + else: + assert type(s) in [list, tuple] + return [validate_color(c) for c in s] + def validate_stringlist(s): 'return a list' if type(s) is str: @@ -440,6 +448,9 @@ # of the axis range is smaller than the # first or larger than the second 'axes.unicode_minus' : [True, validate_bool], + 'axes.color_cycle' : [['b','g','r','c','m','y','k'], + validate_colorlist], # cycle of plot + # line colors 'polaraxes.grid' : [True, validate_bool], # display polar grid or not 'axes3d.grid' : [True, validate_bool], # display 3d grid Modified: trunk/matplotlib/matplotlibrc.template =================================================================== --- trunk/matplotlib/matplotlibrc.template 2010-01-03 21:07:05 UTC (rev 8065) +++ trunk/matplotlib/matplotlibrc.template 2010-01-04 02:22:26 UTC (rev 8066) @@ -161,11 +161,11 @@ #text.markup : 'plain' # Affects how text, such as titles and labels, are # interpreted by default. # 'plain': As plain, unformatted text - # 'tex': As TeX-like text. Text between $'s will be - # formatted as a TeX math expression. - # This setting has no effect when text.usetex is True. - # In that case, all text will be sent to TeX for - # processing. + # 'tex': As TeX-like text. Text between $'s will be + # formatted as a TeX math expression. + # This setting has no effect when text.usetex is True. + # In that case, all text will be sent to TeX for + # processing. #text.hinting : True # If True, text will be hinted, otherwise not. This only # affects the Agg backend. @@ -184,8 +184,8 @@ #mathtext.fontset : cm # Should be 'cm' (Computer Modern), 'stix', # 'stixsans' or 'custom' #mathtext.fallback_to_cm : True # When True, use symbols from the Computer Modern - # fonts when a symbol can not be found in one of - # the custom math fonts. + # fonts when a symbol can not be found in one of + # the custom math fonts. #mathtext.default : it # The default font to use for math. # Can be any of the LaTeX font names, including @@ -211,6 +211,10 @@ # first or larger than the second #axes.unicode_minus : True # use unicode for the minus symbol # rather than hypen. See http://en.wikipedia.org/wiki/Plus_sign#Plus_sign +#axes.color_cycle : b, g, r, c, m, y, k # color cycle for plot lines + # as list of string colorspecs: + # single letter, long name, or + # web-style hex #polaraxes.grid : True # display grid on polar axes #axes3d.grid : True # display grid on 3d axes This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <md...@us...> - 2010-01-04 14:27:15
|
Revision: 8069 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8069&view=rev Author: mdboom Date: 2010-01-04 14:27:02 +0000 (Mon, 04 Jan 2010) Log Message: ----------- Merged revisions 8068 via svnmerge from https://matplotlib.svn.sf.net/svnroot/matplotlib/branches/v0_99_maint ........ r8068 | mdboom | 2010-01-04 09:14:38 -0500 (Mon, 04 Jan 2010) | 2 lines Fix bug in PDF, PS, SVG and OS-X backends: do not simplify filled paths. ........ Modified Paths: -------------- trunk/matplotlib/lib/matplotlib/backends/backend_pdf.py trunk/matplotlib/lib/matplotlib/backends/backend_ps.py trunk/matplotlib/lib/matplotlib/backends/backend_svg.py trunk/matplotlib/src/_macosx.m Property Changed: ---------------- trunk/matplotlib/ trunk/matplotlib/doc/pyplots/README trunk/matplotlib/doc/sphinxext/gen_gallery.py trunk/matplotlib/doc/sphinxext/gen_rst.py trunk/matplotlib/examples/misc/multiprocess.py trunk/matplotlib/examples/mplot3d/contour3d_demo.py trunk/matplotlib/examples/mplot3d/contourf3d_demo.py trunk/matplotlib/examples/mplot3d/polys3d_demo.py trunk/matplotlib/examples/mplot3d/scatter3d_demo.py trunk/matplotlib/examples/mplot3d/surface3d_demo.py trunk/matplotlib/examples/mplot3d/wire3d_demo.py trunk/matplotlib/lib/matplotlib/sphinxext/mathmpl.py trunk/matplotlib/lib/matplotlib/sphinxext/only_directives.py trunk/matplotlib/lib/matplotlib/sphinxext/plot_directive.py trunk/matplotlib/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png Property changes on: trunk/matplotlib ___________________________________________________________________ Modified: svnmerge-integrated - /branches/mathtex:1-7263 /branches/v0_99_maint:1-8057 + /branches/mathtex:1-7263 /branches/v0_99_maint:1-8068 Modified: svn:mergeinfo - /branches/v0_91_maint:5753-5771 /branches/v0_98_5_maint:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint:5753-5771 /branches/v0_98_5_maint:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/doc/pyplots/README ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_98_5_maint/doc/pyplots/README:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/pyplots/README:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_98_5_maint/doc/pyplots/README:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/pyplots/README:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/doc/sphinxext/gen_gallery.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/_templates/gen_gallery.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_gallery.py:6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_gallery.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/doc/_templates/gen_gallery.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_gallery.py:6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_gallery.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/doc/sphinxext/gen_rst.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/examples/gen_rst.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_rst.py:6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_rst.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/doc/examples/gen_rst.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_rst.py:6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_rst.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/misc/multiprocess.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/misc/log.py:5753-5771 /branches/v0_98_5_maint/examples/misc/log.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/misc/multiprocess.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/misc/log.py:5753-5771 /branches/v0_98_5_maint/examples/misc/log.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/misc/multiprocess.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/mplot3d/contour3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/contour.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contour.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contour3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/mplot3d/contour.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contour.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contour3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/mplot3d/contourf3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/contourf.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contourf.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contourf3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/mplot3d/contourf.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contourf.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contourf3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/mplot3d/polys3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/polys.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/polys.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/polys3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/mplot3d/polys.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/polys.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/polys3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/mplot3d/scatter3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/scatter.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/scatter.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/scatter3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/mplot3d/scatter.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/scatter.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/scatter3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/mplot3d/surface3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/surface.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/surface.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/surface3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/mplot3d/surface.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/surface.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/surface3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/examples/mplot3d/wire3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/wire.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/wire.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/wire3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/examples/mplot3d/wire.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/wire.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/wire3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Modified: trunk/matplotlib/lib/matplotlib/backends/backend_pdf.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_pdf.py 2010-01-04 14:14:38 UTC (rev 8068) +++ trunk/matplotlib/lib/matplotlib/backends/backend_pdf.py 2010-01-04 14:27:02 UTC (rev 8069) @@ -1068,7 +1068,8 @@ # an API change self.output(*self.pathOperations( Path.hatch(hatch_style[2]), - Affine2D().scale(sidelen))) + Affine2D().scale(sidelen), + simplify=False)) self.output(Op.stroke) self.endStream() @@ -1192,7 +1193,7 @@ def markerObject(self, path, trans, fillp, lw): """Return name of a marker XObject representing the given path.""" - pathops = self.pathOperations(path, trans) + pathops = self.pathOperations(path, trans, simplify=False) key = (tuple(pathops), bool(fillp)) result = self.markers.get(key) if result is None: @@ -1221,10 +1222,11 @@ self.endStream() @staticmethod - def pathOperations(path, transform, clip=None): + def pathOperations(path, transform, clip=None, simplify=None): cmds = [] last_points = None - for points, code in path.iter_segments(transform, clip=clip): + for points, code in path.iter_segments(transform, clip=clip, + simplify=simplify): if code == Path.MOVETO: # This is allowed anywhere in the path cmds.extend(points) @@ -1250,9 +1252,11 @@ def writePath(self, path, transform, clip=False): if clip: clip = (0.0, 0.0, self.width * 72, self.height * 72) + simplify = path.should_simplify else: clip = None - cmds = self.pathOperations(path, transform, clip) + simplify = False + cmds = self.pathOperations(path, transform, clip, simplify=simplify) self.output(*cmds) def reserveObject(self, name=''): @@ -1969,7 +1973,7 @@ if self._clippath != clippath: path, affine = clippath.get_transformed_path_and_affine() cmds.extend( - PdfFile.pathOperations(path, affine) + + PdfFile.pathOperations(path, affine, simplify=False) + [Op.clip, Op.endpath]) return cmds Modified: trunk/matplotlib/lib/matplotlib/backends/backend_ps.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_ps.py 2010-01-04 14:14:38 UTC (rev 8068) +++ trunk/matplotlib/lib/matplotlib/backends/backend_ps.py 2010-01-04 14:27:02 UTC (rev 8069) @@ -251,7 +251,8 @@ 0 setlinewidth """ % locals()) self._pswriter.write( - self._convert_path(Path.hatch(hatch), Affine2D().scale(72.0))) + self._convert_path(Path.hatch(hatch), Affine2D().scale(72.0), + simplify=False)) self._pswriter.write("""\ stroke } bind @@ -457,7 +458,7 @@ # unflip im.flipud_out() - def _convert_path(self, path, transform, clip=False): + def _convert_path(self, path, transform, clip=False, simplify=None): ps = [] last_points = None if clip: @@ -465,7 +466,8 @@ self.height * 72.0) else: clip = None - for points, code in path.iter_segments(transform, clip=clip): + for points, code in path.iter_segments(transform, clip=clip, + simplify=simplify): if code == Path.MOVETO: ps.append("%g %g m" % tuple(points)) elif code == Path.LINETO: @@ -488,7 +490,8 @@ if id is None: id = 'c%x' % len(self._clip_paths) ps_cmd = ['/%s {' % id] - ps_cmd.append(self._convert_path(clippath, clippath_transform)) + ps_cmd.append(self._convert_path(clippath, clippath_transform, + simplify=False)) ps_cmd.extend(['clip', 'newpath', '} bind def\n']) self._pswriter.write('\n'.join(ps_cmd)) self._clip_paths[(clippath, clippath_transform)] = id @@ -498,9 +501,10 @@ """ Draws a Path instance using the given affine transform. """ + clip = (rgbFace is None and gc.get_hatch_path() is None) + simplify = path.should_simplify and clip ps = self._convert_path( - path, transform, - clip=(rgbFace is None and gc.get_hatch_path() is None)) + path, transform, clip=clip, simplify=simplify) self._draw_ps(ps, gc, rgbFace) def draw_markers(self, gc, marker_path, marker_trans, path, trans, rgbFace=None): @@ -521,7 +525,8 @@ # construct the generic marker command: ps_cmd = ['/o {', 'gsave', 'newpath', 'translate'] # dont want the translate to be global - ps_cmd.append(self._convert_path(marker_path, marker_trans)) + ps_cmd.append(self._convert_path(marker_path, marker_trans, + simplify=False)) if rgbFace: ps_cmd.extend(['gsave', ps_color, 'fill', 'grestore']) @@ -547,7 +552,7 @@ name = 'p%x_%x' % (self._path_collection_id, i) ps_cmd = ['/%s {' % name, 'newpath', 'translate'] - ps_cmd.append(self._convert_path(path, transform)) + ps_cmd.append(self._convert_path(path, transform, simplify=False)) ps_cmd.extend(['} bind def\n']) write('\n'.join(ps_cmd)) path_codes.append(name) Modified: trunk/matplotlib/lib/matplotlib/backends/backend_svg.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_svg.py 2010-01-04 14:14:38 UTC (rev 8068) +++ trunk/matplotlib/lib/matplotlib/backends/backend_svg.py 2010-01-04 14:27:02 UTC (rev 8069) @@ -108,7 +108,8 @@ self._svgwriter.write(' width="%d" height="%d" >\n' % (HATCH_SIZE, HATCH_SIZE)) path_data = self._convert_path( gc.get_hatch_path(), - Affine2D().scale(HATCH_SIZE).scale(1.0, -1.0).translate(0, HATCH_SIZE)) + Affine2D().scale(HATCH_SIZE).scale(1.0, -1.0).translate(0, HATCH_SIZE), + simplify=False) if rgbFace is None: fill = 'none' else: @@ -166,7 +167,7 @@ clippath, clippath_trans = gc.get_clip_path() if clippath is not None: clippath_trans = self._make_flip_transform(clippath_trans) - path_data = self._convert_path(clippath, clippath_trans) + path_data = self._convert_path(clippath, clippath_trans, simplify=False) path = '<path d="%s"/>' % path_data elif cliprect is not None: x, y, w, h = cliprect.bounds @@ -217,7 +218,7 @@ .scale(1.0, -1.0) .translate(0.0, self.height)) - def _convert_path(self, path, transform, clip=False): + def _convert_path(self, path, transform, clip=False, simplify=None): path_data = [] appender = path_data.append path_commands = self._path_commands @@ -226,7 +227,8 @@ clip = (0.0, 0.0, self.width, self.height) else: clip = None - for points, code in path.iter_segments(transform, clip=clip): + for points, code in path.iter_segments(transform, clip=clip, + simplify=simplify): if code == Path.CLOSEPOLY: segment = 'z' else: @@ -241,15 +243,18 @@ def draw_path(self, gc, path, transform, rgbFace=None): trans_and_flip = self._make_flip_transform(transform) + clip = (rgbFace is None and gc.get_hatch_path() is None) + simplify = path.should_simplify and clip path_data = self._convert_path( - path, trans_and_flip, - clip=(rgbFace is None and gc.get_hatch_path() is None)) + path, trans_and_flip, clip=clip, simplify=simplify) self._draw_svg_element('path', 'd="%s"' % path_data, gc, rgbFace) def draw_markers(self, gc, marker_path, marker_trans, path, trans, rgbFace=None): write = self._svgwriter.write - key = self._convert_path(marker_path, marker_trans + Affine2D().scale(1.0, -1.0)) + key = self._convert_path(marker_path, + marker_trans + Affine2D().scale(1.0, -1.0), + simplify=False) name = self._markers.get(key) if name is None: name = 'm%s' % md5(key).hexdigest() @@ -282,7 +287,7 @@ for i, (path, transform) in enumerate(self._iter_collection_raw_paths( master_transform, paths, all_transforms)): transform = Affine2D(transform.get_matrix()).scale(1.0, -1.0) - d = self._convert_path(path, transform) + d = self._convert_path(path, transform, simplify=False) name = 'coll%x_%x_%s' % (self._path_collection_id, i, md5(d).hexdigest()) write('<path id="%s" d="%s"/>\n' % (name, d)) @@ -456,7 +461,7 @@ write('<defs>\n') for char_id, glyph_path in glyph_map_new.iteritems(): path = Path(*glyph_path) - path_data = self._convert_path(path, _flip) + path_data = self._convert_path(path, _flip, simplify=False) path_element = '<path id="%s" d="%s"/>\n' % (char_id, ''.join(path_data)) write(path_element) write('</defs>\n') @@ -504,7 +509,7 @@ for char_id, glyph_path in glyph_map_new.iteritems(): char_id = self._adjust_char_id(char_id) path = Path(*glyph_path) - path_data = self._convert_path(path, None) #_flip) + path_data = self._convert_path(path, None, simplify=False) #_flip) path_element = '<path id="%s" d="%s"/>\n' % (char_id, ''.join(path_data)) write(path_element) write('</defs>\n') @@ -535,7 +540,7 @@ for verts, codes in rects: path = Path(verts, codes) - path_data = self._convert_path(path, None) + path_data = self._convert_path(path, None, simplify=False) path_element = '<path d="%s"/>\n' % (''.join(path_data)) svg.append(path_element) Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/mathmpl.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/mathmpl.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/mathmpl.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/mathmpl.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/doc/sphinxext/mathmpl.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/mathmpl.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/mathmpl.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/only_directives.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/only_directives.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/only_directives.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/only_directives.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/doc/sphinxext/only_directives.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/only_directives.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/only_directives.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/plot_directive.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/plot_directive.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/plot_directive.py:6920-6925,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/plot_directive.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_91_maint/doc/sphinxext/plot_directive.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/plot_directive.py:6920-6925,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/plot_directive.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Property changes on: trunk/matplotlib/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_99_maint/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png:7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057 + /branches/v0_99_maint/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png:7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 Modified: trunk/matplotlib/src/_macosx.m =================================================================== --- trunk/matplotlib/src/_macosx.m 2010-01-04 14:14:38 UTC (rev 8068) +++ trunk/matplotlib/src/_macosx.m 2010-01-04 14:27:02 UTC (rev 8069) @@ -539,7 +539,7 @@ return NULL; } CGContextSetAlpha(cr, alpha); - + self->color[3] = alpha; Py_INCREF(Py_None); @@ -884,7 +884,7 @@ 0, rect, QUANTIZE_AUTO, - 1); + rgbFace == NULL); if (!iterator) { PyErr_SetString(PyExc_RuntimeError, @@ -961,7 +961,7 @@ 0, rect, QUANTIZE_AUTO, - 1); + 0); if (!iterator) { Py_DECREF(hatchpath); @@ -1146,14 +1146,14 @@ Py_DECREF(translation); PyErr_SetString(PyExc_ValueError, "transform_point did not return a NumPy array"); - return false; + return false; } if (PyArray_NDIM(translation)!=1 || PyArray_DIM(translation, 0)!=2) { Py_DECREF(translation); PyErr_SetString(PyExc_ValueError, "transform_point did not return an approriate array"); - return false; + return false; } tx = (CGFloat)(*(double*)PyArray_GETPTR1(translation, 0)); ty = (CGFloat)(*(double*)PyArray_GETPTR1(translation, 1)); @@ -1397,7 +1397,7 @@ Py_ssize_t Nlinestyles = PySequence_Size(linestyles); Py_ssize_t Naa = PySequence_Size(antialiaseds); if (N < Nlinestyles) Nlinestyles = N; - if ((Nfacecolors == 0 && Nedgecolors == 0) || Np == 0) goto exit; + if ((Nfacecolors == 0 && Nedgecolors == 0) || Np == 0) goto exit; /* Preset graphics context properties if possible */ if (Naa==1) @@ -1641,7 +1641,7 @@ master.c = c; master.d = d; master.tx = tx; - master.ty = ty; + master.ty = ty; } else { @@ -2255,7 +2255,7 @@ width = CTLineGetTypographicBounds(line, &ascent, &descent, NULL); rect = CTLineGetImageBounds(line, cr); - + CFRelease(line); return Py_BuildValue("fff", width, rect.size.height, descent); @@ -3022,7 +3022,7 @@ } /* NSSize contains CGFloat; cannot use size directly */ if(!PyArg_ParseTuple(args, "u#dd", - &characters, &n, &width, &height)) return NULL; + &characters, &n, &width, &height)) return NULL; size.width = width; size.height = height; @@ -3036,7 +3036,7 @@ NSRect rect = [view bounds]; NSString* filename = [NSString stringWithCharacters: characters - length: (unsigned)n]; + length: (unsigned)n]; NSString* extension = [filename pathExtension]; /* Calling dataWithPDFInsideRect on the view causes its update status @@ -3055,23 +3055,23 @@ if (! [extension isEqualToString: @"tiff"] && ! [extension isEqualToString: @"tif"]) { - NSBitmapImageFileType filetype; - NSBitmapImageRep* bitmapRep = [NSBitmapImageRep imageRepWithData: data]; - if ([extension isEqualToString: @"bmp"]) - filetype = NSBMPFileType; - else if ([extension isEqualToString: @"gif"]) - filetype = NSGIFFileType; - else if ([extension isEqualToString: @"jpg"] || - [extension isEqualToString: @"jpeg"]) - filetype = NSJPEGFileType; - else if ([extension isEqualToString: @"png"]) - filetype = NSPNGFileType; - else - { PyErr_SetString(PyExc_ValueError, "Unknown file type"); - return NULL; - } + NSBitmapImageFileType filetype; + NSBitmapImageRep* bitmapRep = [NSBitmapImageRep imageRepWithData: data]; + if ([extension isEqualToString: @"bmp"]) + filetype = NSBMPFileType; + else if ([extension isEqualToString: @"gif"]) + filetype = NSGIFFileType; + else if ([extension isEqualToString: @"jpg"] || + [extension isEqualToString: @"jpeg"]) + filetype = NSJPEGFileType; + else if ([extension isEqualToString: @"png"]) + filetype = NSPNGFileType; + else + { PyErr_SetString(PyExc_ValueError, "Unknown file type"); + return NULL; + } - data = [bitmapRep representationUsingType:filetype properties:nil]; + data = [bitmapRep representationUsingType:filetype properties:nil]; } [data writeToFile: filename atomically: YES]; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <md...@us...> - 2010-01-04 14:32:50
|
Revision: 8071 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8071&view=rev Author: mdboom Date: 2010-01-04 14:32:39 +0000 (Mon, 04 Jan 2010) Log Message: ----------- Merged revisions 8070 via svnmerge from https://matplotlib.svn.sf.net/svnroot/matplotlib/branches/v0_99_maint ........ r8070 | mdboom | 2010-01-04 09:28:57 -0500 (Mon, 04 Jan 2010) | 1 line Fix doc 'clean' ........ Modified Paths: -------------- trunk/matplotlib/doc/make.py Property Changed: ---------------- trunk/matplotlib/ trunk/matplotlib/doc/pyplots/README trunk/matplotlib/doc/sphinxext/gen_gallery.py trunk/matplotlib/doc/sphinxext/gen_rst.py trunk/matplotlib/examples/misc/multiprocess.py trunk/matplotlib/examples/mplot3d/contour3d_demo.py trunk/matplotlib/examples/mplot3d/contourf3d_demo.py trunk/matplotlib/examples/mplot3d/polys3d_demo.py trunk/matplotlib/examples/mplot3d/scatter3d_demo.py trunk/matplotlib/examples/mplot3d/surface3d_demo.py trunk/matplotlib/examples/mplot3d/wire3d_demo.py trunk/matplotlib/lib/matplotlib/sphinxext/mathmpl.py trunk/matplotlib/lib/matplotlib/sphinxext/only_directives.py trunk/matplotlib/lib/matplotlib/sphinxext/plot_directive.py trunk/matplotlib/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png Property changes on: trunk/matplotlib ___________________________________________________________________ Modified: svnmerge-integrated - /branches/mathtex:1-7263 /branches/v0_99_maint:1-8068 + /branches/mathtex:1-7263 /branches/v0_99_maint:1-8070 Modified: svn:mergeinfo - /branches/v0_91_maint:5753-5771 /branches/v0_98_5_maint:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint:5753-5771 /branches/v0_98_5_maint:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Modified: trunk/matplotlib/doc/make.py =================================================================== --- trunk/matplotlib/doc/make.py 2010-01-04 14:28:57 UTC (rev 8070) +++ trunk/matplotlib/doc/make.py 2010-01-04 14:32:39 UTC (rev 8071) @@ -67,13 +67,13 @@ def clean(): shutil.rmtree("build") shutil.rmtree("examples") - for pattern in ['doc/mpl_examples/api/*.png', - 'doc/mpl_examples/pylab_examples/*.png', - 'doc/mpl_examples/pylab_examples/*.pdf', - 'doc/mpl_examples/units/*.png', - 'doc/pyplots/tex_demo.png', - 'doc/_static/matplotlibrc', - 'doc/_templates/gallery.html']: + for pattern in ['mpl_examples/api/*.png', + 'mpl_examples/pylab_examples/*.png', + 'mpl_examples/pylab_examples/*.pdf', + 'mpl_examples/units/*.png', + 'pyplots/tex_demo.png', + '_static/matplotlibrc', + '_templates/gallery.html']: for filename in glob.glob(pattern): if os.path.exists(filename): os.remove(filename) Property changes on: trunk/matplotlib/doc/pyplots/README ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_98_5_maint/doc/pyplots/README:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/pyplots/README:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_98_5_maint/doc/pyplots/README:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/pyplots/README:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/doc/sphinxext/gen_gallery.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/_templates/gen_gallery.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_gallery.py:6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_gallery.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/doc/_templates/gen_gallery.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_gallery.py:6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_gallery.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/doc/sphinxext/gen_rst.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/examples/gen_rst.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_rst.py:6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_rst.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/doc/examples/gen_rst.py:5753-5771 /branches/v0_98_5_maint/doc/sphinxext/gen_rst.py:6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/doc/sphinxext/gen_rst.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/misc/multiprocess.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/misc/log.py:5753-5771 /branches/v0_98_5_maint/examples/misc/log.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/misc/multiprocess.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/misc/log.py:5753-5771 /branches/v0_98_5_maint/examples/misc/log.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/misc/multiprocess.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/mplot3d/contour3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/contour.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contour.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contour3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/mplot3d/contour.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contour.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contour3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/mplot3d/contourf3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/contourf.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contourf.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contourf3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/mplot3d/contourf.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/contourf.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/contourf3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/mplot3d/polys3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/polys.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/polys.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/polys3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/mplot3d/polys.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/polys.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/polys3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/mplot3d/scatter3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/scatter.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/scatter.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/scatter3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/mplot3d/scatter.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/scatter.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/scatter3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/mplot3d/surface3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/surface.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/surface.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/surface3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/mplot3d/surface.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/surface.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/surface3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/examples/mplot3d/wire3d_demo.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/examples/mplot3d/wire.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/wire.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/wire3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/examples/mplot3d/wire.py:5753-5771 /branches/v0_98_5_maint/examples/mplot3d/wire.py:6581,6585,6587,6589-6609,6614,6616,6625,6652,6660-6662,6672-6673,6714-6715,6717-6732,6752-6754,6761-6773,6781,6792,6800,6802,6805,6809,6811,6822,6827,6850,6854,6856,6859,6861-6873,6883-6884,6886,6890-6891,6906-6909,6911-6912,6915-6916,6918,6920-6925,6927-6928,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080 /branches/v0_99_maint/examples/mplot3d/wire3d_demo.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/mathmpl.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/mathmpl.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/mathmpl.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/mathmpl.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/doc/sphinxext/mathmpl.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/mathmpl.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/mathmpl.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/only_directives.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/only_directives.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/only_directives.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/only_directives.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/doc/sphinxext/only_directives.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/only_directives.py:6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/only_directives.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/lib/matplotlib/sphinxext/plot_directive.py ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_91_maint/doc/sphinxext/plot_directive.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/plot_directive.py:6920-6925,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/plot_directive.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_91_maint/doc/sphinxext/plot_directive.py:5753-5771 /branches/v0_98_5_maint/lib/matplotlib/sphinxext/plot_directive.py:6920-6925,6934,6941,6946,6948,6950,6952,6960,6972,6984-6985,6990,6995,6997-7001,7014,7016,7018,7024-7025,7033,7035,7042,7072,7080,7176,7209-7211,7227,7245 /branches/v0_99_maint/lib/matplotlib/sphinxext/plot_directive.py:7338,7393,7395-7404,7407-7424,7428-7433,7442-7444,7446,7475-7482,7484,7486,7489-7523,7567,7569,7582-7584,7616-7618,7633,7638,7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 Property changes on: trunk/matplotlib/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png ___________________________________________________________________ Modified: svn:mergeinfo - /branches/v0_99_maint/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png:7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068 + /branches/v0_99_maint/lib/matplotlib/tests/baseline_images/test_spines/spines_axes_positions.png:7703,7727-7734,7740-7741,7745,7751,7756,7762,7770,7772,7774,7776-7778,7780,7784,7788,7790,7792,7794,7796,7800,7803,7808,7822,7827,7834,7837,7844,7846-7847,7849,7858,7864,7866-7867,7874,7884,7896,7901-7903,7916,7919,7924,7928,7944,7952,7970,7972,7981,7983,7989-7991,7998,8001,8003,8016-8057,8068,8070 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <he...@us...> - 2010-01-04 22:58:50
|
Revision: 8074 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8074&view=rev Author: heeres Date: 2010-01-04 22:58:43 +0000 (Mon, 04 Jan 2010) Log Message: ----------- Add EngFormatter + example (Jason Heeris, Matthias Michler) Modified Paths: -------------- trunk/matplotlib/lib/matplotlib/ticker.py Added Paths: ----------- trunk/matplotlib/examples/api/engineering_formatter.py Added: trunk/matplotlib/examples/api/engineering_formatter.py =================================================================== --- trunk/matplotlib/examples/api/engineering_formatter.py (rev 0) +++ trunk/matplotlib/examples/api/engineering_formatter.py 2010-01-04 22:58:43 UTC (rev 8074) @@ -0,0 +1,19 @@ +''' +Demo to show use of the engineering Formatter. +''' + +import matplotlib.pyplot as plt +import numpy as np + +from matplotlib.ticker import EngFormatter + +ax = plt.subplot(111) +ax.set_xscale('log') +formatter = EngFormatter(unit='Hz', places=1) +ax.xaxis.set_major_formatter(formatter) + +xs = np.logspace(1, 9, 100) +ys = (0.8 + 0.4 * np.random.uniform(size=100)) * np.log10(xs)**2 +ax.plot(xs, ys) + +plt.show() Modified: trunk/matplotlib/lib/matplotlib/ticker.py =================================================================== --- trunk/matplotlib/lib/matplotlib/ticker.py 2010-01-04 17:22:32 UTC (rev 8073) +++ trunk/matplotlib/lib/matplotlib/ticker.py 2010-01-04 22:58:43 UTC (rev 8074) @@ -118,6 +118,7 @@ from __future__ import division +import decimal import math import numpy as np from matplotlib import rcParams @@ -507,23 +508,23 @@ is ``False`` """ self._base = base+0.0 - self.labelOnlyBase=labelOnlyBase + self.labelOnlyBase = labelOnlyBase self.decadeOnly = True - def base(self,base): + def base(self, base): 'change the *base* for labeling - warning: should always match the base used for :class:`LogLocator`' - self._base=base + self._base = base - def label_minor(self,labelOnlyBase): + def label_minor(self, labelOnlyBase): 'switch on/off minor ticks labeling' - self.labelOnlyBase=labelOnlyBase + self.labelOnlyBase = labelOnlyBase def __call__(self, x, pos=None): 'Return the format for tick val *x* at position *pos*' vmin, vmax = self.axis.get_view_interval() d = abs(vmax - vmin) - b=self._base + b = self._base if x == 0.0: return '0' sign = np.sign(x) @@ -533,13 +534,13 @@ if not isDecade and self.labelOnlyBase: s = '' elif x>10000: s= '%1.0e'%x elif x<1: s = '%1.0e'%x - else : s = self.pprint_val(x,d) + else : s = self.pprint_val(x, d) if sign == -1: s = '-%s' % s return self.fix_minus(s) - def format_data(self,value): + def format_data(self, value): self.labelOnlyBase = False value = cbook.strip_math(self.__call__(value)) self.labelOnlyBase = True @@ -554,14 +555,14 @@ return abs(x-n)<1e-10 def nearest_long(self, x): - if x==0: return 0L - elif x>0: return long(x+0.5) + if x == 0: return 0L + elif x > 0: return long(x+0.5) else: return long(x-0.5) def pprint_val(self, x, d): #if the number is not too big and it's an int, format it as an #int - if abs(x)<1e4 and x==int(x): return '%d' % x + if abs(x) < 1e4 and x == int(x): return '%d' % x if d < 1e-2: fmt = '%1.3e' elif d < 1e-1: fmt = '%1.3f' @@ -572,7 +573,7 @@ s = fmt % x #print d, x, fmt, s tup = s.split('e') - if len(tup)==2: + if len(tup) == 2: mantissa = tup[0].rstrip('0').rstrip('.') sign = tup[1][0].replace('+', '') exponent = tup[1][1:].lstrip('0') @@ -645,11 +646,97 @@ if usetex: s = r'$%s%d^{%d}$'% (sign_string, b, self.nearest_long(fx)) else: - s = r'$\mathdefault{%s%d^{%d}}$'% (sign_string, b, self.nearest_long(fx)) + s = r'$\mathdefault{%s%d^{%d}}$'% (sign_string, b, + self.nearest_long(fx)) return s +class EngFormatter(Formatter): + """ + Formats axis values using engineering prefixes to represent powers of 1000, + plus a specified unit, eg. 10 MHz instead of 1e7. + """ + # The SI engineering prefixes + ENG_PREFIXES = { + -24: "y", + -21: "z", + -18: "a", + -15: "f", + -12: "p", + -9: "n", + -6: u"\u03bc", # Greek letter mu + -3: "m", + 0: "", + 3: "k", + 6: "M", + 9: "G", + 12: "T", + 15: "P", + 18: "E", + 21: "Z", + 24: "Y" + } + + def __init__(self, unit="", places=None): + self.unit = unit + self.places = places + + def __call__(self, x, pos=None): + s = "%s%s" % (self.format_eng(x), self.unit) + return self.fix_minus(s) + + def format_eng(self, num): + """ Formats a number in engineering notation, appending a letter + representing the power of 1000 of the original number. Some examples: + + >>> format_eng(0) for self.places = 0 + '0' + + >>> format_eng(1000000) for self.places = 1 + '1.0 M' + + >>> format_eng("-1e-6") for self.places = 2 + u'-1.00 \u03bc' + + @param num: the value to represent + @type num: either a numeric value or a string that can be converted to + a numeric value (as per decimal.Decimal constructor) + + @return: engineering formatted string + """ + + dnum = decimal.Decimal(str(num)) + + sign = 1 + + if dnum < 0: + sign = -1 + dnum = -dnum + + if dnum != 0: + pow10 = decimal.Decimal(int(math.floor(dnum.log10()/3)*3)) + else: + pow10 = decimal.Decimal(0) + + pow10 = pow10.min(max(self.ENG_PREFIXES.keys())) + pow10 = pow10.max(min(self.ENG_PREFIXES.keys())) + + prefix = self.ENG_PREFIXES[int(pow10)] + + mant = sign*dnum/(10**pow10) + + if self.places is None: + format_str = u"%g %s" + elif self.places == 0: + format_str = u"%i %s" + elif self.places > 0: + format_str = (u"%%.%if %%s" % self.places) + + formatted = format_str % (mant, prefix) + + return formatted.strip() + class Locator(TickHelper): """ Determine the tick locations; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lee...@us...> - 2010-01-11 19:55:07
|
Revision: 8078 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8078&view=rev Author: leejjoon Date: 2010-01-11 19:54:58 +0000 (Mon, 11 Jan 2010) Log Message: ----------- Add add_click and pop_click methods in BlockingContourLabeler. Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/blocking_input.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-11 19:54:32 UTC (rev 8077) +++ trunk/matplotlib/CHANGELOG 2010-01-11 19:54:58 UTC (rev 8078) @@ -1,3 +1,6 @@ +2009-01-11 Add add_click and pop_click methods in + BlockingContourLabeler. -JJL + 2010-01-03 Added rcParams['axes.color_cycle'] - EF 2010-01-03 Added Pierre's qt4 formlayout editor and toolbar button - JDH Modified: trunk/matplotlib/lib/matplotlib/blocking_input.py =================================================================== --- trunk/matplotlib/lib/matplotlib/blocking_input.py 2010-01-11 19:54:32 UTC (rev 8077) +++ trunk/matplotlib/lib/matplotlib/blocking_input.py 2010-01-11 19:54:58 UTC (rev 8078) @@ -193,7 +193,7 @@ # consistent with matlab and sometimes quite useful, but will # require the user to test how many points were actually # returned before using data. - self.fig.canvas.stop_event_loop(event) + self.fig.canvas.stop_event_loop() def mouse_event_pop( self, event ): """ @@ -311,6 +311,12 @@ self.cs = cs BlockingMouseInput.__init__(self, fig=cs.ax.figure ) + def add_click(self, event): + self.button1(event) + + def pop_click(self, event, index=-1): + self.button3(event) + def button1(self,event): """ This will be called if an event involving a button other than This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lee...@us...> - 2010-01-11 19:55:25
|
Revision: 8079 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8079&view=rev Author: leejjoon Date: 2010-01-11 19:55:19 +0000 (Mon, 11 Jan 2010) Log Message: ----------- new 'bbox-forced' option for Axes.adjustable Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/axes.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-11 19:54:58 UTC (rev 8078) +++ trunk/matplotlib/CHANGELOG 2010-01-11 19:55:19 UTC (rev 8079) @@ -1,3 +1,6 @@ +2009-01-11 adjustable of Axes can be "box-forced" which allow + sharing axes. -JJL + 2009-01-11 Add add_click and pop_click methods in BlockingContourLabeler. -JJL Modified: trunk/matplotlib/lib/matplotlib/axes.py =================================================================== --- trunk/matplotlib/lib/matplotlib/axes.py 2010-01-11 19:54:58 UTC (rev 8078) +++ trunk/matplotlib/lib/matplotlib/axes.py 2010-01-11 19:55:19 UTC (rev 8079) @@ -349,7 +349,7 @@ ================ ========================================= Keyword Description ================ ========================================= - *adjustable* [ 'box' | 'datalim' ] + *adjustable* [ 'box' | 'datalim' | 'box-forced'] *alpha* float: the alpha transparency *anchor* [ 'C', 'SW', 'S', 'SE', 'E', 'NE', 'N', 'NW', 'W' ] @@ -947,13 +947,18 @@ *adjustable* - ========= ============================ - value description - ========= ============================ - 'box' change physical size of axes - 'datalim' change xlim or ylim - ========= ============================ + ============ ===================================== + value description + ============ ===================================== + 'box' change physical size of axes + 'datalim' change xlim or ylim + 'box-forced' same as 'box', but axes can be shared + ============ ===================================== + 'box' does not allow axes sharing, as this can cause + unintended side effect. For cases when sharing axes is + fine, use 'box-forced'. + *anchor* ===== ===================== @@ -984,9 +989,9 @@ def set_adjustable(self, adjustable): """ - ACCEPTS: [ 'box' | 'datalim' ] + ACCEPTS: [ 'box' | 'datalim' | 'box-forced'] """ - if adjustable in ('box', 'datalim'): + if adjustable in ('box', 'datalim', 'box-forced'): if self in self._shared_x_axes or self in self._shared_y_axes: if adjustable == 'box': raise ValueError( @@ -1098,7 +1103,7 @@ figW,figH = self.get_figure().get_size_inches() fig_aspect = figH/figW - if self._adjustable == 'box': + if self._adjustable in ['box', 'box-forced']: if aspect_scale_mode == "log": box_aspect = A * self.get_data_ratio_log() else: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lee...@us...> - 2010-01-11 19:55:35
|
Revision: 8080 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8080&view=rev Author: leejjoon Date: 2010-01-11 19:55:26 +0000 (Mon, 11 Jan 2010) Log Message: ----------- The color of legend patch follows the rc parameters axes.facecolor and axes.edgecolor Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/legend.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-11 19:55:19 UTC (rev 8079) +++ trunk/matplotlib/CHANGELOG 2010-01-11 19:55:26 UTC (rev 8080) @@ -1,3 +1,6 @@ +2009-01-11 The color of legend patch follows the rc parameters + axes.facecolor and axes.edgecolor. -JJL + 2009-01-11 adjustable of Axes can be "box-forced" which allow sharing axes. -JJL Modified: trunk/matplotlib/lib/matplotlib/legend.py =================================================================== --- trunk/matplotlib/lib/matplotlib/legend.py 2010-01-11 19:55:19 UTC (rev 8079) +++ trunk/matplotlib/lib/matplotlib/legend.py 2010-01-11 19:55:26 UTC (rev 8080) @@ -284,9 +284,11 @@ # We use FancyBboxPatch to draw a legend frame. The location # and size of the box will be updated during the drawing time. + self.legendPatch = FancyBboxPatch( xy=(0.0, 0.0), width=1., height=1., - facecolor='w', edgecolor='k', + facecolor=rcParams["axes.facecolor"], + edgecolor=rcParams["axes.edgecolor"], mutation_scale=self._fontsize, snap=True ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ef...@us...> - 2010-01-16 17:45:38
|
Revision: 8081 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8081&view=rev Author: efiring Date: 2010-01-16 17:45:32 +0000 (Sat, 16 Jan 2010) Log Message: ----------- Patch by Ian Thomas fixes 2 major cntr.c problems: Now line contours coincide with filled contour boundaries, and interior masked regions are handled correctly by contourf. Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/examples/pylab_examples/contourf_demo.py trunk/matplotlib/src/cntr.c Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-11 19:55:26 UTC (rev 8080) +++ trunk/matplotlib/CHANGELOG 2010-01-16 17:45:32 UTC (rev 8081) @@ -1,10 +1,14 @@ -2009-01-11 The color of legend patch follows the rc parameters +2010-01-16 Applied patch by Ian Thomas to fix two contouring + problems: now contourf handles interior masked regions, + and the boundaries of line and filled contours coincide. - EF + +2009-01-11 The color of legend patch follows the rc parameters axes.facecolor and axes.edgecolor. -JJL -2009-01-11 adjustable of Axes can be "box-forced" which allow +2009-01-11 adjustable of Axes can be "box-forced" which allow sharing axes. -JJL -2009-01-11 Add add_click and pop_click methods in +2009-01-11 Add add_click and pop_click methods in BlockingContourLabeler. -JJL 2010-01-03 Added rcParams['axes.color_cycle'] - EF Modified: trunk/matplotlib/examples/pylab_examples/contourf_demo.py =================================================================== --- trunk/matplotlib/examples/pylab_examples/contourf_demo.py 2010-01-11 19:55:26 UTC (rev 8080) +++ trunk/matplotlib/examples/pylab_examples/contourf_demo.py 2010-01-16 17:45:32 UTC (rev 8081) @@ -3,35 +3,14 @@ origin = 'lower' #origin = 'upper' -# The following controls only interior masking. -test_masking = False # There is a bug in filled contour masking with - # interior masks. +delta = 0.025 -if test_masking: - # Use a coarse grid so only a few masked points are needed. - delta = 0.5 -else: - delta = 0.025 - x = y = arange(-3.0, 3.01, delta) X, Y = meshgrid(x, y) Z1 = bivariate_normal(X, Y, 1.0, 1.0, 0.0, 0.0) Z2 = bivariate_normal(X, Y, 1.5, 0.5, 1, 1) Z = 10 * (Z1 - Z2) -# interior badmask doesn't work yet for filled contours -if test_masking: - badmask = zeros(shape(Z)) - - badmask[5,5] = 1 - badmask[5,6] = 1 - Z[5,5] = 0 - Z[5,6] = 0 - - badmask[0,0] = 1 - Z[0,0] = 0 - Z = ma.array(Z, mask=badmask) - nr, nc = Z.shape # put NaNs in one corner: @@ -43,7 +22,11 @@ # mask another corner: Z[:nr//6, :nc//6] = ma.masked +# mask a circle in the middle: +interior = sqrt((X**2) + (Y**2)) < 0.5 +Z[interior] = ma.masked + # We are using automatic selection of contour levels; # this is usually not such a good idea, because they don't # occur on nice boundaries, but we do it here for purposes @@ -63,7 +46,7 @@ origin=origin, hold='on') -title('Nonsense (with 2 masked corners)') +title('Nonsense (3 masked regions)') xlabel('word length anomaly') ylabel('sentence length anomaly') @@ -87,7 +70,7 @@ colors = ('k',), linewidths = (3,), origin = origin) -title('Listed colors (with 2 masked corners)') +title('Listed colors (3 masked regions)') clabel(CS4, fmt = '%2.1f', colors = 'w', fontsize=14) colorbar(CS3) Modified: trunk/matplotlib/src/cntr.c =================================================================== --- trunk/matplotlib/src/cntr.c 2010-01-11 19:55:26 UTC (rev 8080) +++ trunk/matplotlib/src/cntr.c 2010-01-16 17:45:32 UTC (rev 8081) @@ -50,12 +50,14 @@ * The problem is that two disjoint curves cut through a saddle zone * (I reject the alternative of connecting the opposite points to make * a single self-intersecting curve, since those make ugly contour plots - * -- I've tried it). The real problem with saddle zones is that you - * need to communicate the connectivity decision you make back to the - * calling routine, since for the next contour level, we need to tell - * the contour tracer to make the same decision as on the previous - * level. The input/output triangulation array is the solution to this - * nasty problem. + * -- I've tried it). The solution is to determine the z value of the + * centre of the zone, which is the mean of the z values of the four + * corner points. If the centre z is higher than the contour level of + * interest and you are moving along the line with higher values on the + * left, turn right to leave the saddle zone. If the centre z is lower + * than the contour level turn left. Whether the centre z is higher + * than the 1 or 2 contour levels is stored in the saddle array so that + * it does not need to be recalculated in subsequent passes. * * Another complicating factor is that there may be logical holes in * the mesh -- zones which do not exist. We want our contours to stop @@ -175,6 +177,11 @@ * or not, z value 0, 1, or 2 -- is kept in a mesh sized data array */ typedef short Cdata; +/* information to decide on correct contour direction in saddle zones + * is stored in a mesh sized array. Only those entries corresponding + * to saddle zones have nonzero values in this array. */ +typedef char Saddle; + /* here is the minimum structure required to tell where we are in the * mesh sized data array */ typedef struct Csite Csite; @@ -189,8 +196,8 @@ long count; /* count of start markers visited */ double zlevel[2]; /* contour levels, zlevel[1]<=zlevel[0] * signals single level case */ - short *triangle; /* triangulation array for the mesh */ - char *reg; /* region array for the mesh (was int) */ + Saddle *saddle; /* saddle zone information for the mesh */ + char *reg; /* region array for the mesh (was int) */ Cdata *data; /* added by EF */ long edge0, left0; /* starting site on this curve for closure */ int level0; /* starting level for closure */ @@ -225,8 +232,6 @@ printf("\n"); } -/* triangle only takes values of -1, 0, 1, so it could be a signed char. */ -/* most or all of the longs probably could be converted to ints with no loss */ /* the Cdata array consists of the following bits: * Z_VALUE (2 bits) 0, 1, or 2 function value at point @@ -243,6 +248,7 @@ * OPEN_END marks an i-edge start point whose other endpoint is * on a boundary for the single level case * ALL_DONE marks final start point + * SLIT_DN_VISITED this slit downstroke hasn't/has been visited in pass 2 */ #define Z_VALUE 0x0003 #define ZONE_EX 0x0004 @@ -257,6 +263,7 @@ #define SLIT_DN 0x0800 #define OPEN_END 0x1000 #define ALL_DONE 0x2000 +#define SLIT_DN_VISITED 0x4000 /* some helpful macros to find points relative to a given directed * edge -- points are designated 0, 1, 2, 3 CCW around zone with 0 and @@ -272,6 +279,15 @@ enum {kind_zone, kind_edge1, kind_edge2, kind_slit_up, kind_slit_down, kind_start_slit=16} point_kinds; +/* Saddle zone array consists of the following bits: + * SADDLE_SET whether zone's saddle data has been set. + * SADDLE_GT0 whether z of centre of zone is higher than site->level[0]. + * SADDLE_GT1 whether z of centre of zone is higher than site->level[1]. + */ +#define SADDLE_SET 0x01 +#define SADDLE_GT0 0x02 +#define SADDLE_GT1 0x04 + /* ------------------------------------------------------------------------ */ /* these actually mark points */ @@ -313,18 +329,17 @@ long left0 = site->left0; int level0 = site->level0 == level; int two_levels = site->zlevel[1] > site->zlevel[0]; - short *triangle = site->triangle; + Saddle* saddle = site->saddle; const double *x = pass2 ? site->x : 0; const double *y = pass2 ? site->y : 0; - const double *z = pass2 ? site->z : 0; - double zlevel = pass2 ? site->zlevel[level] : 0.0; + const double *z = site->z; + double zlevel = site->zlevel[level]; double *xcp = pass2 ? site->xcp : 0; double *ycp = pass2 ? site->ycp : 0; short *kcp = pass2 ? site->kcp : 0; int z0, z1, z2, z3; - int keep_left = 0; /* flag to try to minimize curvature in saddles */ int done = 0; int n_kind; @@ -402,29 +417,28 @@ { if (z1 == z3) { - /* this is a saddle zone, need triangle to decide - * -- set triangle if not already decided for this zone */ + /* this is a saddle zone, determine whether to turn left or + * right depending on height of centre of zone relative to + * contour level. Set saddle[zone] if not already decided. */ long zone = edge + (left > 0 ? left : 0); - if (triangle) + if (!(saddle[zone] & SADDLE_SET)) { - if (!triangle[zone]) - { - if (keep_left) - triangle[zone] = jedge ? -1 : 1; - else - triangle[zone] = jedge ? 1 : -1; - } - if (triangle[zone] > 0 ? !jedge : jedge) - goto bkwd; + saddle[zone] = SADDLE_SET; + double zcentre = (z[p0] + z[p0+left] + z[p1] + z[p1+left])/4.0; + if (zcentre > site->zlevel[0]) + saddle[zone] |= + (two_levels && zcentre > site->zlevel[1]) + ? SADDLE_GT0 | SADDLE_GT1 : SADDLE_GT0; } - else - { - if (keep_left) - goto bkwd; - } + + int turnRight = level == 2 ? (saddle[zone] & SADDLE_GT1) + : (saddle[zone] & SADDLE_GT0); + if (z1 ^ (level == 2)) + turnRight = !turnRight; + if (!turnRight) + goto bkwd; } /* bend forward (right along curve) */ - keep_left = 1; jedge = !jedge; edge = p1 + (left > 0 ? left : 0); { @@ -437,7 +451,6 @@ { bkwd: /* bend backward (left along curve) */ - keep_left = 0; jedge = !jedge; edge = p0 + (left > 0 ? left : 0); { @@ -590,17 +603,27 @@ if (n_kind) kcp[n_kind] += kind_start_slit; return slit_cutter (site, 0, pass2); } + if (fwd < 0 && level0 && left < 0) + { + if (n_kind) kcp[n_kind] += kind_start_slit; + return slit_cutter (site, 0, pass2); + } return 3; } else if (pass2) { if (heads_up || (fwd < 0 && (data[edge] & SLIT_DN))) { - site->edge = edge; - site->left = left; - site->n = n + marked; - if (n_kind) kcp[n_kind] += kind_start_slit; - return slit_cutter (site, heads_up, pass2); + if (!heads_up && !(data[edge] & SLIT_DN_VISITED)) + data[edge] |= SLIT_DN_VISITED; + else + { + site->edge = edge; + site->left = left; + site->n = n + marked; + if (n_kind) kcp[n_kind] += kind_start_slit; + return slit_cutter (site, heads_up, pass2); + } } } else @@ -1181,6 +1204,8 @@ /* place immediate stop mark if nothing found */ if (!count) data[0] |= ALL_DONE; + else + for (i = 0; i < ijmax; ++i) site->saddle[i] = 0; /* initialize site */ site->edge0 = site->edge00 = site->edge = 0; @@ -1252,7 +1277,7 @@ if (site == NULL) return NULL; site->data = NULL; site->reg = NULL; - site->triangle = NULL; + site->saddle = NULL; site->xcp = NULL; site->ycp = NULL; site->kcp = NULL; @@ -1268,7 +1293,6 @@ { long ijmax = iMax * jMax; long nreg = iMax * jMax + iMax + 1; - long i; site->imax = iMax; site->jmax = jMax; @@ -1278,21 +1302,20 @@ PyMem_Free(site); return -1; } - site->triangle = (short *) PyMem_Malloc(sizeof(short) * ijmax); - if (site->triangle == NULL) + site->saddle = (Saddle*) PyMem_Malloc(sizeof(Saddle) * ijmax); + if (site->saddle == NULL) { PyMem_Free(site->data); PyMem_Free(site); return -1; } - for (i = 0; i < ijmax; i++) site->triangle[i] = 0; site->reg = NULL; if (mask != NULL) { site->reg = (char *) PyMem_Malloc(sizeof(char) * nreg); if (site->reg == NULL) { - PyMem_Free(site->triangle); + PyMem_Free(site->saddle); PyMem_Free(site->data); PyMem_Free(site); return -1; @@ -1311,7 +1334,7 @@ void cntr_del(Csite *site) { - PyMem_Free(site->triangle); + PyMem_Free(site->saddle); PyMem_Free(site->reg); PyMem_Free(site->data); PyMem_Free(site); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <as...@us...> - 2010-01-16 19:19:21
|
Revision: 8082 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8082&view=rev Author: astraw Date: 2010-01-16 19:19:14 +0000 (Sat, 16 Jan 2010) Log Message: ----------- Ensure three minor ticks always drawn (SF# 2924245). Patch by Neil Crighton. Modified Paths: -------------- trunk/matplotlib/CHANGELOG trunk/matplotlib/lib/matplotlib/ticker.py Modified: trunk/matplotlib/CHANGELOG =================================================================== --- trunk/matplotlib/CHANGELOG 2010-01-16 17:45:32 UTC (rev 8081) +++ trunk/matplotlib/CHANGELOG 2010-01-16 19:19:14 UTC (rev 8082) @@ -1,3 +1,6 @@ +2009-01-16 Ensure three minor ticks always drawn (SF# 2924245). Patch + by Neil Crighton. -ADS + 2010-01-16 Applied patch by Ian Thomas to fix two contouring problems: now contourf handles interior masked regions, and the boundaries of line and filled contours coincide. - EF Modified: trunk/matplotlib/lib/matplotlib/ticker.py =================================================================== --- trunk/matplotlib/lib/matplotlib/ticker.py 2010-01-16 17:45:32 UTC (rev 8081) +++ trunk/matplotlib/lib/matplotlib/ticker.py 2010-01-16 19:19:14 UTC (rev 8082) @@ -1320,15 +1320,13 @@ except IndexError: raise ValueError('Need at least two major ticks to find minor ' 'tick locations') - # see whether major step should be divided by 5, 4 or 2. This + # see whether major step should be divided by 5, 4. This # should cover most cases. temp = float(('%e' % majorstep).split('e')[0]) if temp % 5 < 1e-10: minorstep = majorstep / 5. - elif temp % 2 < 1e-10: - minorstep = majorstep / 4. else: - minorstep = majorstep / 2. + minorstep = majorstep / 4. tmin = majorlocs[0] - majorstep tmax = majorlocs[-1] + majorstep This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |