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

Skip to content

Commit 97c7da7

Browse files
committed
Release note, deprecation notices, doc changes
1 parent 2dfd5b0 commit 97c7da7

File tree

5 files changed

+33
-8
lines changed

5 files changed

+33
-8
lines changed

doc/_static/transforms.png

-12.8 KB
Loading
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
``Affine2DBase``, ``BlendedAffine2D`` and ``CompositeAffine2D``
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
4+
In order to support 3-dimensional transforms, the following deprecations have been
5+
made. The deprecated classes can be directly replaced with the new alternatives
6+
7+
- ``Affine2DBase`` has been replaced with ``AffineImmutable``
8+
- ``BlendedAffine2D`` has been replaced with ``BlendedAffine``
9+
- ``CompositeAffine2D`` has been replaced with ``CompositeAffine``.

doc/api/transformations.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77

88
.. automodule:: matplotlib.transforms
99
:members: TransformNode, BboxBase, Bbox, TransformedBbox, Transform,
10-
TransformWrapper, AffineBase, Affine2DBase, Affine2D, IdentityTransform,
11-
BlendedGenericTransform, BlendedAffine2D, blended_transform_factory,
12-
CompositeGenericTransform, CompositeAffine2D,
13-
composite_transform_factory, BboxTransform, BboxTransformTo,
10+
TransformWrapper, AffineBase, AffineImmutable, Affine2DBase, Affine2D,
11+
IdentityTransform, BlendedGenericTransform, BlendedAffine, BlendedAffine2D,
12+
blended_transform_factory, CompositeGenericTransform, CompositeAffine,
13+
CompositeAffine2D, composite_transform_factory, BboxTransform, BboxTransformTo,
1414
BboxTransformFrom, ScaledTranslation, TransformedPath, nonsingular,
1515
interval_contains, interval_contains_open
1616
:show-inheritance:
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
Added support for Non 2-dimensional transforms
2+
----------------------------------------------
3+
4+
Support has been added for transforms in matplotlib that aren't 2D.
5+
6+
``AffineImmutable`` directly replaces ``Affine2DBase``, and introduces a ``dims``
7+
keyword that specifies the dimension of the transform, defaulting to 2.
8+
9+
``BlendedAffine`` directly replaces ``BlendedAffine2D``, and can blend more than
10+
two transforms, with each transform handling a different axis.
11+
12+
``CompositeAffine`` directly replaces ``CompositeAffine2D``, and composes two Affine
13+
transforms, as long as they have the same dimensions.
14+
15+
``IdentityTransform`` can create identity matrices of any dimension, through the use of
16+
the ``dims`` keyword.

galleries/tutorials/artists.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -463,15 +463,15 @@ class in the Matplotlib API, and the one you will be working with most
463463
# In [268]: print(rect.get_data_transform())
464464
# CompositeGenericTransform(
465465
# TransformWrapper(
466-
# BlendedAffine2D(
466+
# BlendedAffine(
467467
# IdentityTransform(),
468468
# IdentityTransform())),
469469
# CompositeGenericTransform(
470470
# BboxTransformFrom(
471471
# TransformedBbox(
472472
# Bbox(x0=0.0, y0=0.0, x1=1.0, y1=1.0),
473473
# TransformWrapper(
474-
# BlendedAffine2D(
474+
# BlendedAffine(
475475
# IdentityTransform(),
476476
# IdentityTransform())))),
477477
# BboxTransformTo(
@@ -489,15 +489,15 @@ class in the Matplotlib API, and the one you will be working with most
489489
# In [269]: print(ax.transData)
490490
# CompositeGenericTransform(
491491
# TransformWrapper(
492-
# BlendedAffine2D(
492+
# BlendedAffine(
493493
# IdentityTransform(),
494494
# IdentityTransform())),
495495
# CompositeGenericTransform(
496496
# BboxTransformFrom(
497497
# TransformedBbox(
498498
# Bbox(x0=0.0, y0=0.0, x1=1.0, y1=1.0),
499499
# TransformWrapper(
500-
# BlendedAffine2D(
500+
# BlendedAffine(
501501
# IdentityTransform(),
502502
# IdentityTransform())))),
503503
# BboxTransformTo(

0 commit comments

Comments
 (0)