Updated mapnik.Layer (markdown)
parent
564c7c68be
commit
5bbbe0315f
1 changed files with 50 additions and 16 deletions
|
@ -1,42 +1,76 @@
|
|||
<type 'Boost.Python.class'>
|
||||
|
||||
###abstract
|
||||
|
||||
|
||||
###active
|
||||
|
||||
|
||||
###cache_features
|
||||
|
||||
|
||||
###clear_label_cache
|
||||
|
||||
|
||||
###datasource
|
||||
|
||||
|
||||
###envelope
|
||||
|
||||
envelope( (Layer)arg1) -> Box2d :
|
||||
Return the geographic envelope/bounding box.
|
||||
Determined based on the layer datasource.
|
||||
|
||||
Usage:
|
||||
|
||||
>>> from mapnik import Layer
|
||||
>>> lyr = Layer('My Layer','+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs')
|
||||
>>> lyr.envelope()
|
||||
box2d(-1.0,-1.0,0.0,0.0) # default until a datasource is loaded
|
||||
|
||||
|
||||
C++ signature :
|
||||
|
||||
mapnik::box2d<double> envelope(mapnik::layer {lvalue})
|
||||
|
||||
###maxzoom
|
||||
|
||||
Float
|
||||
|
||||
###minzoom
|
||||
|
||||
Float
|
||||
|
||||
###name
|
||||
|
||||
String
|
||||
|
||||
|
||||
###queryable
|
||||
|
||||
Boolean
|
||||
|
||||
|
||||
###srs
|
||||
|
||||
String representing the spatial reference system of the map.
|
||||
|
||||
###styles
|
||||
|
||||
a list of mapnik.Style objects
|
||||
|
||||
###title
|
||||
|
||||
String
|
||||
|
||||
###visible
|
||||
|
||||
|
||||
visible( (Layer)arg1, (float)arg2) -> bool :
|
||||
Return True if this layer's data is active and visible at a given scale.
|
||||
|
||||
Otherwise returns False.
|
||||
Accepts a scale value as an integer or float input.
|
||||
Will return False if:
|
||||
scale >= minzoom - 1e-6
|
||||
or:
|
||||
scale < maxzoom + 1e-6
|
||||
|
||||
Usage:
|
||||
|
||||
>>> from mapnik import Layer
|
||||
>>> lyr = Layer('My Layer','+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs')
|
||||
>>> lyr.visible(1.0/1000000)
|
||||
True
|
||||
>>> lyr.active = False
|
||||
>>> lyr.visible(1.0/1000000)
|
||||
False
|
||||
|
||||
|
||||
C++ signature :
|
||||
bool visible(mapnik::layer {lvalue},double)
|
||||
|
|
Loading…
Reference in a new issue