Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 969af73

Browse files
committed
multiple backed support take II
svn path=/trunk/matplotlib/; revision=25
1 parent 2dd00d4 commit 969af73

64 files changed

Lines changed: 22816 additions & 30 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CHANGELOG

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,38 @@
4848
vlines outside the viewport, so I wrote a dedicated class
4949
Vline2D which derives from Line2D
5050

51-
5251

5352
2003-05-01
5453

5554
Fixed ytick bug where grid and tick show outside axis viewport with gc clip
55+
56+
2003-05-14
57+
58+
Added new ways to specify colors 1) matlab format string 2)
59+
html-style hex string, 3) rgb tuple. See examples/color_demo.py
60+
61+
2003-05-28
62+
63+
Changed figure rendering to draw form a pixmap to reduce flicker.
64+
See examples/system_monitor.py for an example where the plot is
65+
continusouly updated w/o flicker. This example is meant to
66+
simulate a system monitor that shows free CPU, RAM, etc...
67+
68+
2003-08-04
69+
70+
Added Jon Anderson's GTK shell, which doesn't require pygtk to
71+
have threading built-in and looks nice!
72+
73+
2003-08-25
74+
75+
Fixed deprecation warnings for python2.3 and pygtk-1.99.18
76+
77+
2003-08-26
78+
79+
Added figure text with new example examples/figtext.py
80+
81+
82+
2003-08-27
83+
84+
Fixed bugs i figure text with font override dictionairies and fig
85+
text that was placed outside the window bounding box

LICENSE

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@ documentation.
99
2. Subject to the terms and conditions of this License Agreement, JDH
1010
hereby grants Licensee a nonexclusive, royalty-free, world-wide
1111
license to reproduce, analyze, test, perform and/or display publicly,
12-
prepare derivative works, distribute, and otherwise use matplotlib
13-
0.2 alone or in any derivative version, provided, however, that JDH's
12+
prepare derivative works, distribute, and otherwise use matplotlib 0.2
13+
alone or in any derivative version, provided, however, that JDH's
1414
License Agreement and JDH's notice of copyright, i.e., "Copyright (c)
15-
2002 John D. Hunter; All Rights Reserved" are retained in matplotlib
16-
0.2 alone or in any derivative version prepared by Licensee.
15+
2002, 2003 John D. Hunter; All Rights Reserved" are retained in
16+
matplotlib 0.2 alone or in any derivative version prepared by
17+
Licensee.
1718

1819
3. In the event Licensee prepares a derivative work that is based on
1920
or incorporates matplotlib 0.2 or any part thereof, and wants to make

Makefile

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
# Copyright (C) 2003 <[email protected]>
33
# $Header$
44
# $Log$
5+
# Revision 1.4 2003/09/15 17:54:16 jdh2358
6+
# multiple backed support take II
7+
#
58
# Revision 1.3 2003/05/12 19:56:54 jdh2358
69
# update license to version 2 and the docs
710
#
@@ -14,29 +17,32 @@
1417

1518
VERSION = `python setup.py --version`
1619
DISTFILES = INSTALL README TODO LICENSE CHANGELOG Makefile GOALS INTERACTIVE \
17-
matplotlib examples examples setup.py
20+
MANIFEST.in matplotlib examples setup.py
1821
MODULES = artist cbook gtkutils lines patches colors text matlab figure
1922
RELEASE = matplotlib-${VERSION}
2023

2124

2225
clean:
23-
python setup.py clean;
24-
find . \( -name "*~" -o -name "*.pyc" \) | xargs rm -f;
25-
find examples -name "*.png" | xargs rm -f;
26+
python setup.py clean;\
27+
find . \( -name "*~" -o -name "*.pyc" \) | xargs rm -f;\
28+
find examples -name "*.png" | xargs rm -f;\
2629
find matplotlib -name "*.png" | xargs rm -f;
2730

2831
htmldocs:
2932
rm -f docs/*.html;\
3033
cd matplotlib;\
31-
pydoc -w ${MODULES};\
34+
/usr/bin/pydoc -w ${MODULES};\
3235
mv *.html ../docs/
3336

3437
release: ${DISTFILES}
35-
rm -rf ${RELEASE};
36-
mkdir ${RELEASE};
37-
cp -a ${DISTFILES} ${RELEASE}/;
38-
tar cvfz releases/${RELEASE}.tar.gz ${RELEASE}/ --dereference;
39-
python setup.py bdist_wininst;
40-
cp dist/${RELEASE}.win32.exe releases/;
38+
rm -rf ${RELEASE};\
39+
mkdir ${RELEASE};\
40+
cp -a ${DISTFILES} ${RELEASE}/;\
41+
rm -rf ${RELEASE}/CVS ${RELEASE}/matplotlib/CVS ${RELEASE}/examples/CVS ${RELEASE}/examples/figures/* ${RELEASE}/examples/*.png ${RELEASE}/examples/*.pyc ${RELEASE}/matplotlib/*.png ${RELEASE}/matplotlib/*.pyc ;\
42+
tar cvfz releases/${RELEASE}.tar.gz ${RELEASE}/ --dereference;\
43+
python setup.py bdist_wininst;\
44+
cp dist/${RELEASE}.win32.exe releases/;\
45+
zip -r ${RELEASE}.zip ${RELEASE};\
46+
mv ${RELEASE}.zip releases/;\
4147
rm -rf ${RELEASE};
4248

TODO

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717

1818
DONE
1919

20-
-- enable anti aliasing for fonts: DONE with pango
20+
-- enable anti aliasing for fonts:
21+
22+
DONE with pango
2123

2224
-- enable fancy text labels (eg, greek letters, math symbols,
2325
superscripts) ala TeX or unicode
@@ -107,5 +109,20 @@
107109

108110
-- raise the figure returned by figure but don't give it the focus
109111

112+
DONE 2003-05-12 with window.window.raise_()
113+
110114
-- when you toggle an axes for interactive navigation, make sure a
111-
checked on appears as the default is one is checked
115+
checked on appears as the default is one is checked
116+
117+
-- compile pygtk for threads on win32.
118+
119+
-- There is a bug in vertical rendering of text that is exposed in the
120+
text, but not the ylabel, command. It looks like a pixmap or
121+
images is not being properly initialized, resulting in pixel noise.
122+
123+
-- Fix the way the color map allocs colors. Use only one DrawingArea
124+
instead of creating a new one with each call to ColorDispatcher().
125+
With this fix the bug in the logo code where the foreground text
126+
doesn't render to the desired color
127+
128+
-- include manifest file for rpms

examples/histogram_demo.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44
x = mu + sigma*randn(10000)
55

66
# the histogram of the data
7-
n, bins, patches = hist(x, 150, normed=1)
8-
7+
n, bins, patches = hist(x, 50, normed=1)
98
# add a 'best fit' line
9+
10+
1011
y = normpdf( bins, mu, sigma)
1112
l = plot(bins, y, 'r--')
1213
set(l, 'linewidth', 2)
@@ -17,5 +18,5 @@
1718
title('Histogram of IQ: mu=100, sigma=15')
1819

1920

20-
#savefig('figures/histogram.png')
21+
savefig('histogram', dpi=150)
2122
show()

examples/simple_plot.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
t = arange(0.0, 2.0, 0.01)
44
s = sin(2*pi*t)
5-
plot(t, s, 'o')
5+
plot(t, s)
66
xlabel('time (s)')
77
ylabel('voltage (mV)')
88
title('About as simple as it gets, folks')

examples/subplot_demo.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,8 @@ def f(t):
99
t2 = arange(0.0, 5.0, 0.02)
1010
t3 = arange(0.0, 2.0, 0.01)
1111

12-
figure(1, size=(800,600))
1312
subplot(211)
14-
plot(t1, f(t1), 'bo', t2, f(t2), 'k')
13+
l = plot(t1, f(t1), 'bo', t2, f(t2), 'k')
1514
title('A tale of 2 subplots')
1615
ylabel('Damped oscillation')
1716

@@ -20,5 +19,6 @@ def f(t):
2019
xlabel('time (s)')
2120
ylabel('Undamped')
2221

22+
savefig('subplot_demo', 150)
2323
show()
2424

examples/text_themes.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
font = {'fontname' : 'Courier',
44
'color' : 'r',
5-
'fontweight' : 'bold',
6-
'fontsize' : 11}
5+
'fontweight' : 'normal',
6+
'fontsize' : 12}
77

88
def f(t):
99
s1 = cos(2*pi*t)
@@ -14,7 +14,7 @@ def f(t):
1414
t2 = arange(0.0, 5.0, 0.02)
1515

1616
plot(t1, f(t1), 'bo', t2, f(t2), 'k')
17-
title('Damped exponential decay', font, fontsize=12)
17+
title('Damped exponential decay', font, fontsize=14, color='r')
1818
text(3, 0.65, 'cos(2 pi t) exp(-t)', font, color='k')
1919
xlabel('time (s)', font)
2020
ylabel('voltage (mV)', font)

0 commit comments

Comments
 (0)