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

Skip to content

Commit a16ad75

Browse files
committed
axes_grid: axisline respect rcParam's tick.direction
svn path=/trunk/matplotlib/; revision=7291
1 parent e714e7c commit a16ad75

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

lib/mpl_toolkits/axes_grid/axislines.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -434,6 +434,13 @@ def get_tick_iterators(self, axes):
434434
if self.passthru_pt[1 - self.nth_coord] > 0.5:
435435
angle = 180+angle
436436

437+
438+
# take care the tick direction
439+
if self.nth_coord == 0 and rcParams["xtick.direction"] == "out":
440+
angle += 180
441+
elif self.nth_coord == 1 and rcParams["ytick.direction"] == "out":
442+
angle += 180
443+
437444
major = self.axis.major
438445
majorLocs = major.locator()
439446
major.formatter.set_locs(majorLocs)

0 commit comments

Comments
 (0)