From 191b3399e07069ef15bb399aea73b70ec4619340 Mon Sep 17 00:00:00 2001 From: Oscar Gustafsson Date: Thu, 25 Apr 2024 11:53:38 +0200 Subject: [PATCH] Backport PR #28136: Appease pycodestyle. --- lib/matplotlib/backends/backend_ps.py | 3 +-- lib/matplotlib/projections/polar.py | 6 +----- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/lib/matplotlib/backends/backend_ps.py b/lib/matplotlib/backends/backend_ps.py index d760bef04d19..5f224f38af1e 100644 --- a/lib/matplotlib/backends/backend_ps.py +++ b/lib/matplotlib/backends/backend_ps.py @@ -362,8 +362,7 @@ def create_hatch(self, hatch): /PaintProc {{ pop {linewidth:g} setlinewidth -{self._convert_path( - Path.hatch(hatch), Affine2D().scale(sidelen), simplify=False)} +{self._convert_path(Path.hatch(hatch), Affine2D().scale(sidelen), simplify=False)} gsave fill grestore diff --git a/lib/matplotlib/projections/polar.py b/lib/matplotlib/projections/polar.py index 6bd72d2e35e0..8d3e03f64e7c 100644 --- a/lib/matplotlib/projections/polar.py +++ b/lib/matplotlib/projections/polar.py @@ -270,11 +270,7 @@ def __call__(self, x, pos=None): vmin, vmax = self.axis.get_view_interval() d = np.rad2deg(abs(vmax - vmin)) digits = max(-int(np.log10(d) - 1.5), 0) - # Use Unicode rather than mathtext with \circ, so that it will work - # correctly with any arbitrary font (assuming it has a degree sign), - # whereas $5\circ$ will only work correctly with one of the supported - # math fonts (Computer Modern and STIX). - return f"{np.rad2deg(x):0.{digits:d}f}\N{DEGREE SIGN}" + return f"{np.rad2deg(x):0.{digits}f}\N{DEGREE SIGN}" class _AxisWrapper: