8000 resynced cvs to freetype2 · matplotlib/matplotlib@9dcf399 · GitHub
[go: up one dir, main page]

Skip to content
8000

Commit 9dcf399

Browse files
committed
resynced cvs to freetype2
svn path=/trunk/matplotlib/; revision=154
1 parent c9426ab commit 9dcf399

File tree

14 files changed

+700
-1071
lines changed

14 files changed

+700
-1071
lines changed

MANIFEST

Lines changed: 58 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,6 @@ FontTools/fontTools/ttLib/tables/table_API_readme.txt
9191
FontTools/fontTools/ttLib/tables/ 8000 ttProgram.py
9292
FontTools/fontTools/ttLib/test/__init__.py
9393
FontTools/fontTools/ttLib/test/ttBrowser.py
94-
FontToolsSrc/eexecOp/README.txt
95-
FontToolsSrc/eexecOp/eexecOpmodule.c
9694
agg2/gpc/gpc.c
9795
agg2/gpc/gpc.h
9896
agg2/include/agg_affine_matrix.h
@@ -265,6 +263,7 @@ examples/embedding_in_gtk2.py
265263
examples/embedding_in_wx.py
266264
examples/errorbar_demo.py
267265
examples/figtext.py
266+
examples/ftface_props.py
268267
examples/gdtest.py
269268
examples/histogram_demo.py
270269
examples/interactive.py
@@ -295,15 +294,68 @@ examples/text_handles.py
295294
examples/text_themes.py
296295
examples/vertical_ticklabels.py
297296
examples/vline_demo.py
298-
examples/wx_demo.py
299-
examples/xvfb_demo.py
300297
examples/data/AAPL.dat
301298
examples/data/INTC.dat
302299
examples/data/eeg.dat
303300
examples/data/intc.csv
304301
examples/data/membrane.dat
305302
examples/data/msft.csv
306303
examples/data/s1045.ima
304+
examples/test/README
305+
examples/test/__init__.py
306+
examples/test/agg_font_test.py
307+
examples/test/alignment_test.py
308+
examples/test/backend_agg_test.py
309+
examples/test/bar_test.py
310+
examples/test/batchtest.py
311+
examples/test/batchtest2.py
312+
examples/test/break.py
313+
examples/test/center_test.py
314+
examples/test/clip_end.py
315+
examples/test/cmmi_test.py
316+
examples/test/cmmi_test2.py
317+
examples/test/cmmi_test3.py
318+
examples/test/cmmi_test4.py
319+
examples/test/cmmi_test5.py
320+
examples/test/cmmi_test6.py
321+
examples/test/dash_test.py
322+
examples/test/fonttable.py
323+
examples/test/ft2test.py
324+
examples/test/ft2test2.py
325+
examples/test/gd2gtk_test.py
326+
examples/test/gtk2_test.py
327+
examples/test/highres_test.py
328+
examples/test/hist_test.py
329+
examples/test/histogram_demo.py
330+
examples/test/line_thickness.py
331+
examples/test/lots_o_points.py
332+
examples/test/manset.py
333+
examples/test/matplotlibc_test.py
334+
examples/test/memleak.py
335+
examples/test/memleak2.py
336+
examples/test/memleak3.py
337+
examples/test/mesh_test.py
338+
examples/test/plot_bug.py
339+
examples/test/plotraw.py
340+
examples/test/print_only.py
341+
examples/test/ps_landtest.py
342+
examples/test/rounding.py
343+
examples/test/semilog_test.py
344+
examples/test/shapefile_test.py
345+
examples/test/specgram_demo.py
346+
examples/test/subplot_demo.py
347+
examples/test/table_demo.py
348+
examples/test/table_demo3.py
349+
examples/test/table_test.py
350+
examples/test/table_test2.py
351+
examples/test/test.py
352+
examples/test/test_backend_agg.py
353+
examples/test/transtest.py
354+
examples/test/vline_demo.py
355+
examples/test/libpng-1.2.5/README
356+
examples/test/libpng-1.2.5/contrib/gregbook/README
357+
examples/test/libpng-1.2.5/contrib/pngminus/README
358+
examples/test/libpng-1.2.5/contrib/pngsuite/README
307359
images/stock_close.xpm
308360
images/stock_down.xpm
309361
images/stock_left.xpm
@@ -322,6 +374,7 @@ matplotlib/axis.py
322374
matplotlib/backend_bases.py
323375
matplotlib/cbook.py
324376
matplotlib/collection.py
377+
matplotlib/colormap.py
325378
matplotlib/colors.py
326379
matplotlib/figure.py
327380
matplotlib/legend.py
@@ -347,68 +400,22 @@ src/_backend_agg.cpp
347400
src/_backend_agg.h
348401
src/_gtkagg.cpp
349402
src/_gtkgd.c
403+
src/font.cpp
350404
src/ft2font.c
351405
src/ft2font.h
352-
src/test.c
353-
test/README
354-
test/agg_font_test.py
355-
test/alignment_test.py
356-
test/backend_agg_test.py
357-
test/bar_test.py
358-
test/batchtest.py
359-
test/batchtest2.py
360-
test/break.py
361-
test/center_test.py
362-
test/clip_end.py
363-
test/dash_test.py
364-
test/ft2test.py
365-
test/gd2gtk_test.py
366-
test/gtk2_test.py
367-
test/highres_test.py
368-
test/hist_test.py
369-
test/histogram_demo.py
370-
test/line_thickness.py
371-
test/lots_o_points.py
372-
test/manset.py
373-
test/matplotlibc_test.py
374-
test/memleak.py
375-
test/memleak2.py
376-
test/memleak3.py
377-
test/mesh_test.py
378-
test/plot_bug.py
379-
test/plotraw.py
380-
test/print_only.py
381-
test/ps_landtest.py
382-
test/rounding.py
383-
test/semilog_test.py
384-
test/shapefile_test.py
385-
test/specgram_demo.py
386-
test/subplot_demo.py
387-
test/table_demo.py
388-
test/table_demo3.py
389-
test/table_test.py
390-
test/table_test2.py
391-
test/test.py
392-
test/test_backend_agg.py
393-
test/transtest.py
394-
test/vline_demo.py
395406
ttfquery/__init__.py
396407
ttfquery/__init__.pyc
397408
ttfquery/_scriptregistry.py
398-
ttfquery/_scriptregistry.pyc
399409
ttfquery/describe.py
400-
ttfquery/describe.pyc
401410
ttfquery/family_query.py
402411
ttfquery/findsystem.py
403-
ttfquery/findsystem.pyc
404412
ttfquery/font_family_groups.py
405413
ttfquery/glyph.py
406414
ttfquery/glyphquery.py
407415
ttfquery/guessdescription.py
408416
ttfquery/license.txt
409417
ttfquery/metadata_query.py
410418
ttfquery/ttffiles.py
411-
ttfquery/ttffiles.pyc
412419
win32src/importlib.bat
413420
win32src/profile22.bat
414421
win32src/profile23.bat

TODO

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,4 +224,11 @@
224224

225225
-- decreasing axes - James Boyle <boyle5@llnl.gov>
226226

227-
-- make rgb rgba
227+
-- make rgb rgba
228+
229+
-- check out Helge's contour
230+
231+
-- DONE 2004-02-23 with points_to_pixels. fonts too big on wx
232+
233+
-- test agg/freetype2 with ms freetype fonts in path. Be sure to
234+
remove ~/.fonts.cache after changing yout ttfpath

examples/ftface_props.py

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
"""
2+
This is a demo script to show you how to use all the properties of an
3+
FT2Font object. These describe global font properties. For
4+
individual character metrices, use the Glyp object, as returned by
5+
load_char
6+
"""
7+
from matplotlib.ft2font import FT2Font
8+
9+
fname = '/usr/local/share/matplotlib/VeraIt.ttf'
10+
11+
font = FT2Font(fname)
12+
13+
# these constants are used to access the style_flags and face_flags
14+
FT_FACE_FLAG_SCALABLE = 1 << 0
15+
FT_FACE_FLAG_FIXED_SIZES = 1 << 1
16+
FT_FACE_FLAG_FIXED_WIDTH = 1 << 2
17+
FT_FACE_FLAG_SFNT = 1 << 3
18+
FT_FACE_FLAG_HORIZONTAL = 1 << 4
19+
FT_FACE_FLAG_VERTICAL = 1 << 5
20+
FT_FACE_FLAG_KERNING = 1 << 6
21+
FT_FACE_FLAG_FAST_GLYPHS = 1 << 7
22+
FT_FACE_FLAG_MULTIPLE_MASTERS = 1 << 8
23+
FT_FACE_FLAG_GLYPH_NAMES = 1 << 9
24+
FT_FACE_FLAG_EXTERNAL_STREAM = 1 << 10
25+
FT_STYLE_FLAG_ITALIC = 1 << 0
26+
FT_STYLE_FLAG_BOLD = 1 << 1
27+
28+
print 'Num faces :', font.num_faces # number of faces in file
29+
print 'Num glyphs :', font.num_glyphs # number of glyphs in the face
30+
print 'Family name :', font.family_name # face family name
31+
print 'Syle name :', font.style_name # face syle name
32+
print 'Num fixed :', font.num_fixed_sizes # number of embedded bitmap in face
33+
34+
# the following are only available if face.scalable
35+
if font.scalable:
36+
# the face global bounding box (xmin, ymin, xmax, ymax)
37+
print 'Bbox :', font.bbox
38+
# number of font units covered by the EM
39+
print 'EM :', font.units_per_EM
40+
# the ascender in 26.6 units
41+
print 'Ascender :', font.ascender
42+
# the descender in 26.6 units
43+
print 'Descender :', font.descender
44+
# the height in 26.6 units
45+
print 'Height :', font.height
46+
# maximum horizontal cursor advance
47+
print 'Max adv width :', font.max_advance_width
48+
# same for vertical layout
49+
print 'Max adv height :', font.max_advance_height
50+
# vertical position of the underline bar
51+
print 'Underline pos :', font.underline_position
52+
# vertical thickness of the underline
53+
print 'Underline thickness :', font.underline_thickness
54+
55+
print 'Italics :', font.style_flags & FT_STYLE_FLAG_ITALIC != 0
56+
print 'Bold :', font.style_flags & FT_STYLE_FLAG_BOLD != 0
57+
print 'Scalable :', font.style_flags & FT_FACE_FLAG_SCALABLE != 0
58+
print 'Fixed sizes :', font.style_flags & FT_FACE_FLAG_FIXED_SIZES != 0
59+
print 'Fixed width :', font.style_flags & FT_FACE_FLAG_FIXED_WIDTH != 0
60+
print 'SFNT :', font.style_flags & FT_FACE_FLAG_SFNT != 0
61+
print 'Horizontal :', font.style_flags & FT_FACE_FLAG_HORIZONTAL != 0
62+
print 'Vertical :', font.style_flags & FT_FACE_FLAG_VERTICAL != 0
63+
print 'Kerning :', font.style_flags & FT_FACE_FLAG_KERNING != 0
64+
print 'Fast glyphs :', font.style_flags & FT_FACE_FLAG_FAST_GLYPHS != 0
65+
print 'Mult. masters :', font.style_flags & FT_FACE_FLAG_MULTIPLE_MASTERS != 0
66+
print 'Glyph names :', font.style_flags & FT_FACE_FLAG_GLYPH_NAMES != 0
67+

examples/log_test.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
from matplotlib.matlab import *
2+
3+
dt = 0.01
4+
t = arange(dt, 20.0, dt)
5+
6+
semilogx(t, exp(-t/5.0))
7+
grid(True)
8+
#savefig('log_demo')
9+
show()

fonts/ttf/cmex10.ttf

20.6 KB
Binary file not shown.

fonts/ttf/cmmi10.ttf

31.8 KB
Binary file not shown.

fonts/ttf/cmr10.ttf

25.7 KB
Binary file not shown.

fonts/ttf/cmsy10.ttf

28.7 KB
Binary file not shown.

setup.py

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

8585

8686
setup(name="matplotlib",
87-
version= '0.51a',
87+
version= '0.51b',
8888
description = "Matlab style python plotting package",
8989
author = "John D. Hunter",
9090
author_email="jdhunter@ace.bsd.uchicago.edu",

0 commit comments

Comments
 (0)
0