Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a44f66e commit fd8ec19Copy full SHA for fd8ec19
2 files changed
doc/users/whats_new/offset_label_color.rst
@@ -0,0 +1,4 @@
1
+Axis offset label now responds to `labelcolor`
2
+----------------------------------------------
3
+
4
+Axis offset labels are now colored the same as axis tick markers when `labelcolor` is altered.
lib/matplotlib/tests/test_axes.py
@@ -4477,6 +4477,16 @@ def test_axisbelow():
4477
ax.set_axisbelow(setting)
4478
4479
4480
+@cleanup
4481
+def test_offset_label_color():
4482
+ # Tests issue 6440
4483
+ fig = plt.figure()
4484
+ ax = fig.add_subplot(1, 1, 1)
4485
+ ax.plot([1.01e9, 1.02e9, 1.03e9])
4486
+ ax.yaxis.set_tick_params(labelcolor='red')
4487
+ assert ax.yaxis.get_offset_text().get_color() == 'red'
4488
4489
4490
@cleanup
4491
def test_large_offset():
4492
fig, ax = plt.subplots()
0 commit comments