| EMS.Icon | |
| states | {Integer} is the number of states the icon has. |
| Functions | |
| EMS.Icon | Creates a new instance of a hover icon. |
| draw | Constructs contents of the control. |
| setState | |
| Static Functions | |
| start | {EMS.Icon} A new start icon useful for putting at the start of a route. |
| end | {EMS.Icon} A end start icon useful for putting at the end of a route. |
| via | |
| cross | Shortcut for getting a cross-hair icon. |
| poi | |
| multipoi | |
| babushka |
Creates a new instance of a hover icon.
| url | {String} The URL of the icon. |
| size | {OpenLayers.Size} The size of the icon. |
| offset | {OpenLayers.Pixel} The offset to the center of the icon. |
| calculateOffset | {Function} A (optional) function to calculate the offset to the center of the icon. |
| states | {Integer} The number of states this icon contains (defaults to 1). |
draw: function( px )
Constructs contents of the control.
| px | {OpenLayers.Pixel} |
{DOMElement} A reference to a div that represents this control.
EMS.Icon.start = function()
{EMS.Icon} A new start icon useful for putting at the start of a route.
EMS.Icon.end = function()
{EMS.Icon} A end start icon useful for putting at the end of a route.
EMS.Icon.via = function( index )
| index | {Integer} is the index, a value between 1 and 5 which will appear on the icon. Returns: {EMS.Icon} A via point with a number on it. |
EMS.Icon.crosshair = function( color )
Shortcut for getting a cross-hair icon.
| color | {String|<EMS.Color>} is either a string name such as GREEN, RED or BLUE. Or one EMS.Color. Only RED, GREEN or BLUE is currently supported. If nothing is given, it will default to BLUE. |
{EMS.Icon} A cross hair icon.
EMS.Icon.poi = function( text, color, background, hover )
| text | {String} is the text to be shown. There is really only enough room on the icon for about 2-3 characters. |
| color | {String}|{EMS.Color} is the {String} name of the color, the {String} hex color or the EMS.Color. This is optional and will default to being white. |
| background | {String|<EMS.Gradient>} is the {String} name of the gradient or a EMS.Gradient. This is optional and will default to being EMS.Gradient.RED. |
| hover | {String|<EMS.Gradient>} is the {String} name of the gradient or a EMS.Gradient to be used for the hover color. This will default to blue one is not given. |
{EMS.Icon} A newly created poi icon.
EMS.Icon.multipoi = function( text, color, background, hover )
| text | {String} is the text to be shown. This is the little number in the top right corner. |
| color | {String|<EMS.Color>} is the {String} name of the color, the {String} hex color or the EMS.Color. This is optional and will default to being white. |
| background | {String|<EMS.Gradient>} is the {String} name of the gradient or a EMS.Gradient. This is optional and will default to being EMS.Gradient.RED. |
| hover | {String|<EMS.Gradient>} is the {String} name of the gradient or a EMS.Gradient to be used for the hover color. This will default to blue one is not given. |
{EMS.Icon} A newly created poi icon.
EMS.Icon.babushka = function( text, color, background, hover )
| text | {String} is the text to be shown. This is the little number in the top right corner. |
| color | {String|<EMS.Color>} is the {String} name of the color, the {String} hex color or the EMS.Color. This is optional and will default to being white. |
| background | {String|<EMS.Gradient>} is the {String} name of the gradient or a EMS.Gradient. This is optional and will default to being EMS.Gradient.RED. |
| hover | {String|<EMS.Gradient>} is the {String} name of the gradient or a EMS.Gradient to be used for the hover color. This will default to blue one is not given. |
{EMS.Icon} A newly created babushka icon.
Constructs contents of the control.
draw: function( px )
setState: function( state )
{EMS.Icon} A new start icon useful for putting at the start of a route.
EMS.Icon.start = function()
{EMS.Icon} A end start icon useful for putting at the end of a route.
EMS.Icon.end = function()
EMS.Icon.via = function( index )
Shortcut for getting a cross-hair icon.
EMS.Icon.crosshair = function( color )
EMS.Icon.poi = function( text, color, background, hover )
EMS.Icon.multipoi = function( text, color, background, hover )
EMS.Icon.babushka = function( text, color, background, hover )