Skip to content

Commit 4f22b67

Browse files
show scatter titles in these two examples
the scatter-series one i understand - we have to prevent the composite chart from overriding the title function, since we need the special title function that overrides the grotesque #702 scatter override of key+value accessors but i can't get why we don't need that for the multi-scatter example. they're both composite charts, but this one works with the shared composite title function because somehow or another, the key accessor that title function sees is *not* the scatter override one. it has something to do with the title function capturing key+value accessors from its own closure, but i'm confused as heck and must be tired as well. ref #1200
1 parent e1a1211 commit 4f22b67

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

web/examples/multi-scatter.html

+1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
.yAxisLabel("This is the Y Axis!")
4040
.clipPadding(10)
4141
.dimension(scatterDimension)
42+
.brushOn(false)
4243
.legend(dc.legend().x(70).y(10).itemHeight(13).gap(5))
4344
.compose([
4445
dc.scatterPlot(chart)

web/examples/scatter-series.html

+1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
.dimension(runDimension)
4949
.group(runGroup)
5050
.mouseZoomable(true)
51+
.shareTitle(false) // allow default scatter title to work
5152
.seriesAccessor(function(d) {return "Expt: " + d.key[0];})
5253
.keyAccessor(function(d) {return +d.key[1];})
5354
.valueAccessor(function(d) {return +d.value - 500;})

0 commit comments

Comments
 (0)