Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 947e6eb

Browse filesBrowse files
authored
Merge pull request #5161 from zblz/log-ticks
API: Changes to default log scale tick formatting
2 parents 22aa800 + 5c28e95 commit 947e6eb
Copy full SHA for 947e6eb

File tree

Expand file treeCollapse file tree

6 files changed

+333
-101
lines changed
Filter options
Expand file treeCollapse file tree

6 files changed

+333
-101
lines changed

‎lib/matplotlib/scale.py

Copy file name to clipboardExpand all lines: lib/matplotlib/scale.py
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
from matplotlib.cbook import dedent
1010
from matplotlib.ticker import (NullFormatter, ScalarFormatter,
11-
LogFormatterMathtext, LogitFormatter)
11+
LogFormatterSciNotation, LogitFormatter)
1212
from matplotlib.ticker import (NullLocator, LogLocator, AutoLocator,
1313
SymmetricalLogLocator, LogitLocator)
1414
from matplotlib.transforms import Transform, IdentityTransform
@@ -304,9 +304,9 @@ def set_default_locators_and_formatters(self, axis):
304304
log scaling.
305305
"""
306306
axis.set_major_locator(LogLocator(self.base))
307-
axis.set_major_formatter(LogFormatterMathtext(self.base))
307+
axis.set_major_formatter(LogFormatterSciNotation(self.base))
308308
axis.set_minor_locator(LogLocator(self.base, self.subs))
309-
axis.set_minor_formatter(NullFormatter())
309+
axis.set_minor_formatter(LogFormatterSciNotation(self.base))
310310

311311
def get_transform(self):
312312
"""
@@ -462,7 +462,7 @@ def set_default_locators_and_formatters(self, axis):
462462
symmetrical log scaling.
463463
"""
464464
axis.set_major_locator(SymmetricalLogLocator(self.get_transform()))
465-
axis.set_major_formatter(LogFormatterMathtext(self.base))
465+
axis.set_major_formatter(LogFormatterSciNotation(self.base))
466466
axis.set_minor_locator(SymmetricalLogLocator(self.get_transform(),
467467
self.subs))
468468
axis.set_minor_formatter(NullFormatter())
Binary file not shown.
Loading

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.