New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Marker not at the center of the point #7273

Closed
artem78 opened this Issue Oct 13, 2017 · 2 comments

Comments

Projects
None yet
3 participants
@artem78

artem78 commented Oct 13, 2017

I`m using markers with custom images. The bug is that they placed with offset of the point. I noticed that this is happening when I use marker enabled parameter:

    plotOptions: {
        series: {
            marker: {
                enabled: false
            }
        }
    },

h_1507893506_8577037_a76f242a80

Without this param all looks fine:
h_1507893444_7440525_0451dc9184

Demo: http://jsfiddle.net/crazzzy/7mug981a/
I see this issue in both my browsers Firefox and Chrome.

@pawelfus

This comment has been minimized.

Contributor

pawelfus commented Oct 16, 2017

Hi @artem78

Thanks!

Workaround:
Set marker.radius = -2, demo: http://jsfiddle.net/7mug981a/1/

Internal note:
It's caused by default value for radius (4) which is cleaned up here:

highcharts/js/parts/Series.js

Lines 3676 to 3678 in b399225

if (point.hasImage) {
radius = 0; // and subsequently width and height is not set
}

But only for series with enabled markers:

if (hasMarkers) {
markerAttribs = series.markerAttribs(point, state);
}

@pawelfus pawelfus added the Bug label Oct 16, 2017

@pawelfus pawelfus self-assigned this Dec 29, 2017

pawelfus added a commit that referenced this issue Dec 29, 2017

pawelfus added a commit that referenced this issue Dec 29, 2017

@TorsteinHonsi

This comment has been minimized.

Collaborator

TorsteinHonsi commented Feb 1, 2018

@pawelfus The test for https://utils.highcharts.local/samples/#test/unit-tests/series/marker doesn't pass in Firefox. Will you have a look?

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