@@ -51,10 +51,10 @@ function Polar(gd, id) {
51
51
var fullLayout = gd . _fullLayout ;
52
52
var clipIdBase = 'clip' + fullLayout . _uid + id ;
53
53
54
- this . clipIds . circle = clipIdBase + '-circle ' ;
55
- this . clipPaths . circle = fullLayout . _clips . append ( 'clipPath' )
56
- . attr ( 'id' , this . clipIds . circle ) ;
57
- this . clipPaths . circle . append ( 'path' ) ;
54
+ this . clipIds . forTraces = clipIdBase + '-for-traces ' ;
55
+ this . clipPaths . forTraces = fullLayout . _clips . append ( 'clipPath' )
56
+ . attr ( 'id' , this . clipIds . forTraces ) ;
57
+ this . clipPaths . forTraces . append ( 'path' ) ;
58
58
59
59
this . framework = fullLayout . _polarlayer . append ( 'g' )
60
60
. attr ( 'class' , id ) ;
@@ -130,7 +130,7 @@ proto.updateLayers = function(fullLayout, polarLayout) {
130
130
sel . append ( 'g' ) . classed ( 'maplayer' , true ) ;
131
131
break ;
132
132
case 'plotbg' :
133
- layers . bgcircle = sel . append ( 'path' ) ;
133
+ layers . bg = sel . append ( 'path' ) ;
134
134
break ;
135
135
case 'radial-grid' :
136
136
sel . style ( 'fill' , 'none' ) ;
@@ -235,19 +235,18 @@ proto.updateLayout = function(fullLayout, polarLayout) {
235
235
xaxis . isPtWithinRange = function ( d ) { return _this . isPtWithinSector ( d ) ; } ;
236
236
yaxis . isPtWithinRange = function ( ) { return true ; } ;
237
237
238
+ _this . clipPaths . forTraces . select ( 'path' )
239
+ . attr ( 'd' , pathSectorClosed ( radius , sector ) )
240
+ . attr ( 'transform' , strTranslate ( cxx , cyy ) ) ;
241
+
238
242
layers . frontplot
239
243
. attr ( 'transform' , strTranslate ( xOffset2 , yOffset2 ) )
240
- . call ( Drawing . setClipUrl , _this . _hasClipOnAxisFalse ? null : _this . clipIds . circle ) ;
244
+ . call ( Drawing . setClipUrl , _this . _hasClipOnAxisFalse ? null : _this . clipIds . forTraces ) ;
241
245
242
- layers . bgcircle . attr ( {
243
- d : pathSectorClosed ( radius , sector ) ,
244
- transform : strTranslate ( cx , cy )
245
- } )
246
- . call ( Color . fill , polarLayout . bgcolor ) ;
247
-
248
- _this . clipPaths . circle . select ( 'path' )
246
+ layers . bg
249
247
. attr ( 'd' , pathSectorClosed ( radius , sector ) )
250
- . attr ( 'transform' , strTranslate ( cxx , cyy ) ) ;
248
+ . attr ( 'transform' , strTranslate ( cx , cy ) )
249
+ . call ( Color . fill , polarLayout . bgcolor ) ;
251
250
252
251
// remove crispEdges - all the off-square angles in polar plots
253
252
// make these counterproductive.
0 commit comments