diff --git a/INSTALL b/INSTALL index 96dbae42b717..7a35f1df2eba 100644 --- a/INSTALL +++ b/INSTALL @@ -208,7 +208,7 @@ libpng 1.2 (or later) `pytz` Used to manipulate time-zone aware datetimes. -:term:`freetype` 2.3 or later +:term:`FreeType` 2.3 or later library for reading true type font files. ``cycler`` 0.9 or later diff --git a/doc/devel/testing.rst b/doc/devel/testing.rst index 0cc5aabcc392..b2dc7516179c 100644 --- a/doc/devel/testing.rst +++ b/doc/devel/testing.rst @@ -38,10 +38,10 @@ Build matplotlib for image comparison tests matplotlib's test suite makes heavy use of image comparison tests, meaning the result of a plot is compared against a known good result. -Unfortunately, different versions of freetype produce differently +Unfortunately, different versions of FreeType produce differently formed characters, causing these image comparisons to fail. To make them reproducible, matplotlib can be built with a special local copy -of freetype. This is recommended for all matplotlib developers. +of FreeType. This is recommended for all matplotlib developers. Add the following content to a ``setup.cfg`` file at the root of the matplotlib source directory:: diff --git a/doc/glossary/index.rst b/doc/glossary/index.rst index fe75339287d2..5f0b683f14cf 100644 --- a/doc/glossary/index.rst +++ b/doc/glossary/index.rst @@ -22,8 +22,8 @@ Glossary EPS Encapsulated Postscript (`EPS `_) - freetype - `freetype `_ is a font rasterization + FreeType + `FreeType `_ is a font rasterization library used by matplotlib which supports TrueType, Type 1, and OpenType fonts. diff --git a/doc/users/screenshots.rst b/doc/users/screenshots.rst index 57001fa763c1..a8a4be075e87 100644 --- a/doc/users/screenshots.rst +++ b/doc/users/screenshots.rst @@ -252,7 +252,7 @@ Mathtext_examples Below is a sampling of the many TeX expressions now supported by matplotlib's internal mathtext engine. The mathtext module provides TeX style mathematical -expressions using `freetype2 `_ +expressions using `FreeTYpe `_ and the BaKoMa computer modern or `STIX `_ fonts. See the :mod:`matplotlib.mathtext` module for additional details. diff --git a/doc/users/text_intro.rst b/doc/users/text_intro.rst index 4f04c9360f28..67d504dcbd5c 100644 --- a/doc/users/text_intro.rst +++ b/doc/users/text_intro.rst @@ -8,7 +8,7 @@ expressions, truetype support for raster and vector outputs, newline separated text with arbitrary rotations, and unicode support. Because we embed the fonts directly in the output documents, e.g., for postscript or PDF, what you see on the screen is what you get in the hardcopy. -`freetype2 `_ support +`FreeType `_ support produces very nice, antialiased fonts, that look good even at small raster sizes. matplotlib includes its own :mod:`matplotlib.font_manager`, thanks to Paul Barrett, which diff --git a/examples/pylab_examples/font_table_ttf.py b/examples/pylab_examples/font_table_ttf.py index 8708ae502e67..a78d39716573 100755 --- a/examples/pylab_examples/font_table_ttf.py +++ b/examples/pylab_examples/font_table_ttf.py @@ -1,6 +1,6 @@ # -*- noplot -*- """ -matplotlib has support for freetype fonts. Here's a little example +matplotlib has support for FreeType fonts. Here's a little example using the 'table' command to build a font table that shows the glyphs by character code. diff --git a/lib/matplotlib/__init__.py b/lib/matplotlib/__init__.py index 06ad93643dd5..89b635282484 100644 --- a/lib/matplotlib/__init__.py +++ b/lib/matplotlib/__init__.py @@ -1499,7 +1499,7 @@ def _init_tests(): if not os.path.isdir(os.path.join(os.path.dirname(__file__), 'tests')): raise ImportError("matplotlib test data is not installed") - # The version of freetype to install locally for running the + # The version of FreeType to install locally for running the # tests. This must match the value in `setupext.py` LOCAL_FREETYPE_VERSION = '2.5.2' @@ -1507,9 +1507,9 @@ def _init_tests(): if (ft2font.__freetype_version__ != LOCAL_FREETYPE_VERSION or ft2font.__freetype_build_type__ != 'local'): warnings.warn( - "matplotlib is not built with the correct freetype version to run " - "tests. Set local_freetype=True in setup.cfg and rebuild. Expect " - "many image comparison failures below.") + "matplotlib is not built with the correct FreeType version to run " + "tests. Set local_freetype=True in setup.cfg and rebuild. " + "Expect many image comparison failures below.") try: import nose diff --git a/lib/matplotlib/mathtext.py b/lib/matplotlib/mathtext.py index 99440a655070..e569616dc75b 100644 --- a/lib/matplotlib/mathtext.py +++ b/lib/matplotlib/mathtext.py @@ -113,7 +113,7 @@ class MathtextBackend(object): - :meth:`render_rect_filled` - :meth:`get_results` - And optionally, if you need to use a Freetype hinting style: + And optionally, if you need to use a FreeType hinting style: - :meth:`get_hinting_type` """ @@ -150,7 +150,7 @@ def get_results(self, box): def get_hinting_type(self): """ - Get the Freetype hinting type to use with this particular + Get the FreeType hinting type to use with this particular backend. """ return LOAD_NO_HINTING diff --git a/matplotlibrc.template b/matplotlibrc.template index 7492fe7b7be4..f9bb84cb4f85 100644 --- a/matplotlibrc.template +++ b/matplotlibrc.template @@ -195,10 +195,10 @@ backend : %(backend)s #text.hinting : auto # May be one of the following: # 'none': Perform no hinting - # 'auto': Use freetype's autohinter + # 'auto': Use FreeType's autohinter # 'native': Use the hinting information in the # font file, if available, and if your - # freetype library supports it + # FreeType library supports it # 'either': Use the native hinting information, # or the autohinter if none is available. # For backward compatibility, this value may also be @@ -357,9 +357,9 @@ backend : %(backend)s #image.lut : 256 # the size of the colormap lookup table #image.origin : upper # lower | upper #image.resample : False -#image.composite_image : True # When True, all the images on a set of axes are - # combined into a single composite image before - # saving a figure as a vector graphics file, +#image.composite_image : True # When True, all the images on a set of axes are + # combined into a single composite image before + # saving a figure as a vector graphics file, # such as a PDF. ### CONTOUR PLOTS diff --git a/setup.cfg.template b/setup.cfg.template index e5ea29b5163c..cae6f678e19f 100644 --- a/setup.cfg.template +++ b/setup.cfg.template @@ -11,7 +11,7 @@ [test] # If you plan to develop matplotlib and run or add to the test suite, # set this to True. It will download and build a specific version of -# freetype, and then use that to build the ft2font extension. This +# FreeType, and then use that to build the ft2font extension. This # ensures that test images are exactly reproducible. #local_freetype = False diff --git a/setupext.py b/setupext.py index 9cc75d78a3c1..5c94cfc8919d 100755 --- a/setupext.py +++ b/setupext.py @@ -20,9 +20,9 @@ PY3 = (sys.version_info[0] >= 3) -# This is the version of freetype to use when building a local version -# of freetype. It must match the value in -# lib/matplotlib.__init__.py:validate_test_dependencies +# This is the version of FreeType to use when building a local +# version. It must match the value in +# lib/matplotlib.__init__.py LOCAL_FREETYPE_VERSION = '2.5.2' # md5 hash of the freetype tarball LOCAL_FREETYPE_HASH = '004320381043d275c4e28bbacf05a1b7' diff --git a/src/ft2font.cpp b/src/ft2font.cpp index 4e05eaaa5e9f..b15a89ce1d92 100644 --- a/src/ft2font.cpp +++ b/src/ft2font.cpp @@ -25,8 +25,8 @@ transform is placed on the font to shrink it back to the desired size. While it is a bit surprising that the dpi setting affects hinting, whereas the global transform does not, this is documented - behavior of freetype, and therefore hopefully unlikely to change. - The freetype 2 tutorial says: + behavior of FreeType, and therefore hopefully unlikely to change. + The FreeType 2 tutorial says: NOTE: The transformation is applied to every glyph that is loaded through FT_Load_Glyph and is completely independent of diff --git a/src/ft2font.h b/src/ft2font.h index ee3e6e166db6..793b0e507f4a 100644 --- a/src/ft2font.h +++ b/src/ft2font.h @@ -1,6 +1,6 @@ /* -*- mode: c++; c-basic-offset: 4 -*- */ -/* A python interface to freetype2 */ +/* A python interface to FreeType */ #ifndef _FT2FONT_H #define _FT2FONT_H #include @@ -21,7 +21,7 @@ extern "C" { #define FIXED_MAJOR(val) (long)((val & 0xffff000) >> 16) #define FIXED_MINOR(val) (long)(val & 0xffff) -// the freetype string rendered into a width, height buffer +// the FreeType string rendered into a width, height buffer class FT2Image { public: