Skip to content

scattergl fill - autorange and restyle #2354

@alexcjohnson

Description

@alexcjohnson
Collaborator

scattergl doesn't match the scatter svg autorange behavior with fill: for example, fill: 'tozeroy' like in the gl2d_axes_labels2 mock should trigger the y axis to autorange to zero, and the x axis to autorange tightly rather than padded, despite the markers.

Also: open the same mock and Plotly.restyle(gd, {fill: 'none'}) - the fill will not disappear, though if you add a fill to a plot that doesn't have one, it will appear.

Activity

etpinard

etpinard commented on Feb 9, 2018

@etpinard
Contributor

Also: open the same mock and Plotly.restyle(gd, {fill: 'none'}) - the fill will not disappear, though if you add a fill to a plot that doesn't have one, it will appear.

cc @dfcreative


scattergl probably suffers from other autorange bugs and/or discrepancies.

etpinard

etpinard commented on Feb 22, 2018

@etpinard
Contributor

Plotly.restyle(gd, {fill: 'none'}) - the fill will not disappear

this one is fixed via #2377. The autorange issues prevail.

etpinard

etpinard commented on Feb 22, 2018

@etpinard
Contributor

@dfcreative I found a pretty bad typo in the scattergl calc step where the marker options container is refered to options.markers here, here, here and here instead of options.markers as set here.

This means that Axis.expand never got the correct size values here and the autorange computation for scattergl were plain wrong. See image diffs in commit 58c2972 .

In short, I'll spend some time during to clean up the scattergl calc, by hopefully reusing as much of Scatter.calc as possible.

etpinard

etpinard commented on Feb 28, 2018

@etpinard
Contributor

done in #2404

etpinard

etpinard commented on Feb 28, 2018

@etpinard
Contributor

Related: #2417

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugsomething broken

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @alexcjohnson@etpinard

        Issue actions

          scattergl fill - autorange and restyle · Issue #2354 · plotly/plotly.js