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

Skip to content

Commit 1587277

Browse files
AlainAlain
Alain
authored and
Alain
committed
update behavior change and what's new
1 parent 41b7a20 commit 1587277

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

doc/api/next_api_changes/behavior/25775-HZ.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Default antialiasing behavior changes for ``Text`` and ``Annotation``
1+
Default antialiasing behavior changes for ``Text`` and ``Annotation``
22
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
33

44
``matplotlib.pyplot.annotate()`` and ``matplotlib.pyplot.text()`` now support parameter ``antialiased`` when initializing.
@@ -10,6 +10,7 @@ Examples:
1010
plt.text(0.5, 0.5, '6 inches x 2 inches', antialiased=True)
1111
ax.annotate('local max', xy=(2, 1), xytext=(3, 1.5), antialiased=False)
1212
13+
See "What's New" for more details on usage.
1314

1415
With this new feature, you may want to make sure that you are creating and saving/showing the figure under the same context::
1516

@@ -24,5 +25,5 @@ With this new feature, you may want to make sure that you are creating and savin
2425
ax.annotate('local max', xy=(2, 1), xytext=(3, 1.5))
2526
with rccontext(text.antialiased=False):
2627
fig.savefig('/tmp/test.png')
27-
28+
2829
Also note that antialiasing for tick labeles will be set with ``rcParams['text.antialiased']`` when they are created (usually when a ``Figure`` is created) - This means antialiasing for them can no longer be changed by modifying ``rcParams['text.antialiased']``.

doc/users/next_whats_new/antialiasing_text_annotation.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
Support customizing antialiasing for text and annotation
2-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2+
--------------------------------------------------------
33
``matplotlib.pyplot.annotate()`` and ``matplotlib.pyplot.text()`` now support parameter ``antialiased``.
44
When ``antialiased`` is set to ``True``, antialiasing will be applied to the text.
55
When ``antialiased`` is set to ``False``, antialiasing will not be applied to the text.
66
When ``antialiased`` is not specified, antialiasing will be set by ``rcParams['text.antialiased']`` at the creation time of ``Text`` and ``Annotation`` object.
7-
87
Examples:
98

109
.. code-block::

0 commit comments

Comments
 (0)