yenbao1340 / gmaps-utility-library-dev

Automatically exported from code.google.com/p/gmaps-utility-library-dev
0 stars 0 forks source link

opt_anchor data isn't taking effect #208

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. use a variety of values for opt_anchor

http://kate-maher.com/kiva649/101205_stuff/markers_update_v3.html

What is the expected output? What do you see instead?
The location of the marker cluster text should shift with changing top and left 
opt_anchor[] values, but it does not.

Please use labels and text to provide additional information.

 {
        url: 'images/yellow_4.png',
        height: 200,
        width: 200,
        opt_anchor: [24,0],
    opt_textColor: '#111111',
        opt_textSize: 11
      }

shows the same as 

 {
        url: 'images/yellow_4.png',
        height: 200,
        width: 200,
        opt_anchor: [200,-50],
    opt_textColor: '#111111',
        opt_textSize: 11
      }

Also, the documentation isn't very clear.  Is it [x,y] on [top,left] where 
[0,0] is the left uppermost corner of the cluster image?  Is there a limit?  Is 
it in pixels?

Original issue reported on code.google.com by kate.ma...@gmail.com on 12 Dec 2010 at 8:46

GoogleCodeExporter commented 8 years ago
Ok, to fix this, change line 952 on markerclusterer.js from

 this.anchor = style.opt_anchor;

to

 this.anchor_ = style.opt_anchor;

Original comment by kate.ma...@gmail.com on 12 Dec 2010 at 10:59

GoogleCodeExporter commented 8 years ago
You should make sure that you have the latest version of the source code from 
http://code.google.com/p/google-maps-utility-library-v3/source/browse/#svn/trunk
/markerclusterer/src because this bug was fixed in September :)

Original comment by lu...@google.com on 12 Dec 2010 at 11:06

GoogleCodeExporter commented 8 years ago
I'm using the compiled version of Mar 30th 2011 and it doesn't work either.

Original comment by volker.b...@googlemail.com on 14 Jul 2011 at 5:39

GoogleCodeExporter commented 8 years ago
Also it does not recognize the color- and size values.
It does work with the packed version, though (Revision 317)

Original comment by volker.b...@googlemail.com on 14 Jul 2011 at 5:59