Skip to content

Commit

Permalink
Fixed issue with markers disappearing in IE in certain positions. Closes
Browse files Browse the repository at this point in the history
  • Loading branch information
highslide-software committed Jun 14, 2011
1 parent f17f16c commit 10c2283
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 8 deletions.
20 changes: 16 additions & 4 deletions js/highcharts.src.js
Expand Up @@ -1691,7 +1691,7 @@ SVGElement.prototype = {
});

wrapper.attr({
d: wrapper.renderer.symbols[wrapper.symbolName](wrapper.x, wrapper.y, wrapper.r, {
d: wrapper.renderer.symbols[wrapper.symbolName](mathRound(wrapper.x), mathRound(wrapper.y), wrapper.r, {
start: wrapper.start,
end: wrapper.end,
width: wrapper.width,
Expand Down Expand Up @@ -2551,8 +2551,8 @@ SVGRenderer.prototype = {

// check if there's a path defined for this symbol
path = symbolFn && symbolFn(
x,
y,
mathRound(x),
mathRound(y),
radius,
options
),
Expand Down Expand Up @@ -2609,7 +2609,6 @@ SVGRenderer.prototype = {
createElement('img', {
onload: function() {
var img = this;

centerImage(obj, symbolSizes[imageSrc] = [img.width, img.height]);
},
src: imageSrc
Expand Down Expand Up @@ -3811,6 +3810,19 @@ VMLRenderer.prototype = merge( SVGRenderer.prototype, { // inherit SVGRenderer
},
// Add circle symbol path. This performs significantly faster than v:oval.
circle: function (x, y, r) {
console.log([
'wa', // clockwisearcto
x - r, // left
y - r, // top
x + r, // right
y + r, // bottom
x + r, // start x
y, // start y
x + r, // end x
y, // end y
//'x', // finish path
'e' // close
].join( ))
return [
'wa', // clockwisearcto
x - r, // left
Expand Down
7 changes: 3 additions & 4 deletions js/parts/SvgRenderer.js
Expand Up @@ -232,7 +232,7 @@ SVGElement.prototype = {
});

wrapper.attr({
d: wrapper.renderer.symbols[wrapper.symbolName](wrapper.x, wrapper.y, wrapper.r, {
d: wrapper.renderer.symbols[wrapper.symbolName](mathRound(wrapper.x), mathRound(wrapper.y), wrapper.r, {
start: wrapper.start,
end: wrapper.end,
width: wrapper.width,
Expand Down Expand Up @@ -1092,8 +1092,8 @@ SVGRenderer.prototype = {

// check if there's a path defined for this symbol
path = symbolFn && symbolFn(
x,
y,
mathRound(x),
mathRound(y),
radius,
options
),
Expand Down Expand Up @@ -1150,7 +1150,6 @@ SVGRenderer.prototype = {
createElement('img', {
onload: function() {
var img = this;

centerImage(obj, symbolSizes[imageSrc] = [img.width, img.height]);
},
src: imageSrc
Expand Down

0 comments on commit 10c2283

Please sign in to comment.