Skip to content

Commit e0e698d

Browse files
authored
Merge pull request #378 from nschloe/typo
fix missing f-string specifiers
2 parents e0dd986 + ae1dd8e commit e0e698d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tikzplotlib/_axes.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,19 +48,19 @@ def __init__(self, data, obj): # noqa: C901
4848

4949
# get axes titles
5050
xlabel = obj.get_xlabel()
51-
xrotation = obj.xaxis.get_label().get_rotation()
5251
if xlabel:
5352
xlabel = _common_texification(xlabel)
5453
self.axis_options.append(f"xlabel={{{xlabel}}}")
54+
xrotation = obj.xaxis.get_label().get_rotation()
5555
if xrotation != 0:
56-
self.axis_options.append("xlabel style={{rotate={xrotation - 90)}}}")
56+
self.axis_options.append(f"xlabel style={{rotate={xrotation - 90}}}")
5757
ylabel = obj.get_ylabel()
58-
yrotation = obj.yaxis.get_label().get_rotation()
5958
if ylabel:
6059
ylabel = _common_texification(ylabel)
6160
self.axis_options.append(f"ylabel={{{ylabel}}}")
61+
yrotation = obj.yaxis.get_label().get_rotation()
6262
if yrotation != 90:
63-
self.axis_options.append("ylabel style={{rotate={yrotation - 90}}}")
63+
self.axis_options.append(f"ylabel style={{rotate={yrotation - 90}}}")
6464

6565
# Axes limits.
6666
ff = data["float format"]

0 commit comments

Comments
 (0)