Skip to content
This repository was archived by the owner on Apr 21, 2023. It is now read-only.

Commit f506306

Browse files
committed
use (xl,xr,yt,yb) instead of (x,y) as push margin coordinates
... this enables an axis to push the margin on both side of its span
1 parent a9e2dbb commit f506306

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/plots/cartesian/axes.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -1897,12 +1897,12 @@ axes.drawOne = function(gd, ax, opts) {
18971897
if(llbbox.width > 0) {
18981898
var rExtra = llbbox.right - (ax._offset + ax._length);
18991899
if(rExtra > 0) {
1900-
push.x = 1;
1900+
push.xr = 1;
19011901
push.r = rExtra;
19021902
}
19031903
var lExtra = ax._offset - llbbox.left;
19041904
if(lExtra > 0) {
1905-
push.x = 0;
1905+
push.xl = 0;
19061906
push.l = lExtra;
19071907
}
19081908
}
@@ -1917,12 +1917,12 @@ axes.drawOne = function(gd, ax, opts) {
19171917
if(llbbox.height > 0) {
19181918
var bExtra = llbbox.bottom - (ax._offset + ax._length);
19191919
if(bExtra > 0) {
1920-
push.y = 0;
1920+
push.yb = 0;
19211921
push.b = bExtra;
19221922
}
19231923
var tExtra = ax._offset - llbbox.top;
19241924
if(tExtra > 0) {
1925-
push.y = 1;
1925+
push.yt = 1;
19261926
push.t = tExtra;
19271927
}
19281928
}

0 commit comments

Comments
 (0)