Follow us on GitHub

com.google.gwt.maps.client.overlays
Class MarkerImage

java.lang.Object
  extended by com.google.gwt.core.client.JavaScriptObject
      extended by com.google.gwt.maps.client.overlays.MarkerImage

public class MarkerImage
extends JavaScriptObject

A structure representing a Marker icon or shadow image.

See MarkerImage API Doc


Constructor Summary
protected MarkerImage()
          A structure representing a Marker icon or shadow image.
 
Method Summary
 Point getAnchor()
          gets The position at which to anchor an image in correspondance to the location of the marker on the map.
 Point getOrigin()
          gets The position of the image within a sprite, if any.
 Size getScaledSize()
          gets The size of the entire image after scaling, if any.
 Size getSize()
          gets The display size of the sprite or image.
 String getUrl()
          gets The URL of the image or sprite sheet.
static MarkerImage newInstance(String url)
          creates A structure representing a Marker icon or shadow image.
static MarkerImage newInstance(String url, Size size)
          creates A structure representing a Marker icon or shadow image.
static MarkerImage newInstance(String url, Size size, Point origin)
          creates A structure representing a Marker icon or shadow image.
static MarkerImage newInstance(String url, Size size, Point origin, Point anchor)
          creates A structure representing a Marker icon or shadow image.
static MarkerImage newInstance(String url, Size size, Point origin, Point anchor, Size scaledSize)
          creates A structure representing a Marker icon or shadow image.
 void setAnchor(Point anchor)
          sets The position at which to anchor an image in correspondance to the location of the marker on the map.
 void setOrigin(Point origin)
          sets The position of the image within a sprite, if any.
 void setScaledSize(Size scaledSize)
          sets The size of the entire image after scaling, if any.
 void setSize(Size size)
          sets The display size of the sprite or image.
 void setUrl(String url)
          sets The URL of the image or sprite sheet.
 
Methods inherited from class com.google.gwt.core.client.JavaScriptObject
cast, createArray, createFunction, createObject, equals, hashCode, toSource, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MarkerImage

protected MarkerImage()
A structure representing a Marker icon or shadow image.

Method Detail

newInstance

public static final MarkerImage newInstance(String url)
creates A structure representing a Marker icon or shadow image.

Parameters:
url - The URL of the image or sprite sheet.
Returns:
MarkerImage

newInstance

public static final MarkerImage newInstance(String url,
                                            Size size)
creates A structure representing a Marker icon or shadow image.

Parameters:
url - The URL of the image or sprite sheet.
size - The display size of the sprite or image. When using sprites, you must specify the sprite size. If the size is not provided, it will be set when the image loads.
Returns:
MarkerImage

newInstance

public static final MarkerImage newInstance(String url,
                                            Size size,
                                            Point origin)
creates A structure representing a Marker icon or shadow image.

Parameters:
url - The URL of the image or sprite sheet.
size - The display size of the sprite or image. When using sprites, you must specify the sprite size. If the size is not provided, it will be set when the image loads.
origin - The position of the image within a sprite, if any. By default, the origin is located at the top left corner of the image (0, 0).
Returns:
MarkerImage

newInstance

public static final MarkerImage newInstance(String url,
                                            Size size,
                                            Point origin,
                                            Point anchor)
creates A structure representing a Marker icon or shadow image.

Parameters:
url - The URL of the image or sprite sheet.
size - The display size of the sprite or image. When using sprites, you must specify the sprite size. If the size is not provided, it will be set when the image loads.
origin - The position of the image within a sprite, if any. By default, the origin is located at the top left corner of the image (0, 0).
anchor - The position at which to anchor an image in correspondance to the location of the marker on the map. By default, the anchor is located along the center point of the bottom of the image.
Returns:
MarkerImage

newInstance

public static final MarkerImage newInstance(String url,
                                            Size size,
                                            Point origin,
                                            Point anchor,
                                            Size scaledSize)
creates A structure representing a Marker icon or shadow image.

Parameters:
url - The URL of the image or sprite sheet.
size - The display size of the sprite or image. When using sprites, you must specify the sprite size. If the size is not provided, it will be set when the image loads.
origin - The position of the image within a sprite, if any. By default, the origin is located at the top left corner of the image (0, 0).
anchor - The position at which to anchor an image in correspondance to the location of the marker on the map. By default, the anchor is located along the center point of the bottom of the image.
scaledSize - The size of the entire image after scaling, if any. Use this property to stretch/shrink an image or a sprite.
Returns:
MarkerImage

setAnchor

public final void setAnchor(Point anchor)
sets The position at which to anchor an image in correspondance to the location of the marker on the map. By default, the anchor is located along the center point of the bottom of the image.

Parameters:
anchor -

getAnchor

public final Point getAnchor()
gets The position at which to anchor an image in correspondance to the location of the marker on the map. By default, the anchor is located along the center point of the bottom of the image.


setOrigin

public final void setOrigin(Point origin)
sets The position of the image within a sprite, if any. By default, the origin is located at the top left corner of the image (0, 0).

Parameters:
origin -

getOrigin

public final Point getOrigin()
gets The position of the image within a sprite, if any. By default, the origin is located at the top left corner of the image (0, 0).


setScaledSize

public final void setScaledSize(Size scaledSize)
sets The size of the entire image after scaling, if any. Use this property to stretch/shrink an image or a sprite.

Parameters:
scaledSize -

getScaledSize

public final Size getScaledSize()
gets The size of the entire image after scaling, if any. Use this property to stretch/shrink an image or a sprite.


setSize

public final void setSize(Size size)
sets The display size of the sprite or image. When using sprites, you must specify the sprite size. If the size is not provided, it will be set when the image loads.

Parameters:
size -

getSize

public final Size getSize()
gets The display size of the sprite or image. When using sprites, you must specify the sprite size. If the size is not provided, it will be set when the image loads.


setUrl

public final void setUrl(String url)
sets The URL of the image or sprite sheet.

Parameters:
url -

getUrl

public final String getUrl()
gets The URL of the image or sprite sheet.



Follow us on GitHub

Copyright © 2011-2012 Gone Vertical LLC. All Rights Reserved.