new cercalia.SimpleLabel(options)
Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Marker options
|
Extends
Methods
-
destroy()
src/cercalia/simplelabel.js, line 451 -
Destroy object
-
Returns:
Get Class name of object
-
getFillColor(){string}
src/cercalia/simplelabel.js, line 308 -
Return text color.
Returns:
Hexadecimal color. For example:#FF0000
.
-
getFontFamily(){string}
src/cercalia/simplelabel.js, line 225 -
Returns text font family-
Returns:
Font family.
-
getFontSize(){number}
src/cercalia/simplelabel.js, line 267 -
Returns text font
Returns:
Font size in pixels.
-
Returns:
Unique Id.
-
getOffset(){}
src/cercalia/simplelabel.js, line 288 -
Returns offset.
Returns:
Offset[x,y]
.
-
getOverflow(){boolean}
src/cercalia/simplelabel.js, line 426 -
Returns:
Get overflow value
-
getRotation(){number}
src/cercalia/simplelabel.js, line 367 -
Returns SimpleLabel rotation
Returns:
Rotation angle in degrees.
-
getStrokeColor(){string}
src/cercalia/simplelabel.js, line 328 -
Returns outline color of text.
Returns:
Hexadecimal color. For exmaple:#FF0000
.
-
getStrokeWidth(){number}
src/cercalia/simplelabel.js, line 348 -
Get Stroke Width
Returns:
Width in pixels.
-
getText(){string}
src/cercalia/simplelabel.js, line 205 -
Get simple label text
Returns:
Get text.
-
Get Text style.
Returns:
Text style.
-
isFontBold(){boolean}
src/cercalia/simplelabel.js, line 245 -
Returns
true
if font is bold.Returns:
Font bold.true
bold,false
normal weight.
-
isVisible(){boolean}
src/cercalia/simplelabel.js, line 391 -
Returns:
visible Returns if SimpleLabel is visible
-
setFillColor(fillColor)
src/cercalia/simplelabel.js, line 297 -
Change text color. If have an assigned marker updates it
Name Type Description fillColor
string Hexadecimal color. For example:
#FF0000
. -
setFontBold(fontBold)
src/cercalia/simplelabel.js, line 234 -
Change the text passed by parameter. If have an assigned marker updates it
Name Type Description fontBold
boolean true
bold,false
normal weight. -
setFontFamily(fontFamily)
src/cercalia/simplelabel.js, line 214 -
Change the text passed by parameter. If have an assigned marker updates it
Name Type Description fontFamily
string Font Family. Example:
Arial
. -
setFontSize(fontSize)
src/cercalia/simplelabel.js, line 255 -
Change the text size in pixels. If have an assigned marker updates it
Name Type Description fontSize
number Font size in pixels.
-
setOffset(offset)
src/cercalia/simplelabel.js, line 277 -
Change displacement on the horizontal axis. If have an assigned marker updates it
Name Type Description offset
Offset
[x,y]
. -
setOverflow(overflow)
src/cercalia/simplelabel.js, line 416 -
Name Type Description overflow
boolean Permit overflow over feature or not.
-
setRotation(rotation)
src/cercalia/simplelabel.js, line 357 -
Change the text passed by parameter. If has an assigned marker updates it
Name Type Description rotation
number Rotation angle in degrees.
-
setStrokeColor(strokeColor)
src/cercalia/simplelabel.js, line 317 -
Change outline color. If has an assigned marker updates it
Name Type Description strokeColor
string Hexadecimal color. For exmaple:
#FF0000
. -
setStrokeWidth(strokeWidth)
src/cercalia/simplelabel.js, line 337 -
Change width. If null, sets 0 value. If has an assigned marker updates it
Name Type Description strokeWidth
number Width in pixels.
-
setText(text, opt_divider)
src/cercalia/simplelabel.js, line 189 -
Change the text passed by parameter. If have an assigned marker updates it
Name Type Description text
string Text to put to simple label.
divider
boolean Optional divider.
-
setVisible(visible)
src/cercalia/simplelabel.js, line 400 -
Show / hide label
Name Type Description visible
boolean Set visible. (
true
orfalse
).