SvgTibcoLayer.js

SvgTibcoLayer()


constructor
Inherits from SvgTileLayer

The class responsible for adding tiles of a specific type and style to the map. Adds the TIBCO copyright prefix to the attribution control by default.

Options:
  • mapType(MapTypes)The map tiles type (default: STANDARD)
  • mapStyle(MapStyles)The map tiles style (default: LIGHT)
Parameter Type Description
options Object The layer options

Example

$(document).ready(function () {
  var mapContainer = T.DomUtil.get('map'),
    tibcoLayerStandard = new T.TibcoLayer({ name: 'TibcoLayer 1', mapType: T.MapTypes.BASIC, mapStyle: T.MapStyles.DARK }),
    tibcoLayerSvg = new T.SvgTibcoLayer({ name: 'TibcoLayer 2', mapType: T.MapTypes.LABELS, mapStyle: T.MapStyles.DARK })

  var map = new T.Map(mapContainer, {
    zoom: 3,
    center: new T.LatLng(46, 2),
    controls: {
      attribution: {
        prefix: "<a href=''>©TIBCO</a>"
      }
    }
  })

  map.addLayer(tibcoLayerStandard)
  map.addLayer(tibcoLayerSvg)
})
<!DOCTYPE html>
<html>

<head>
  <title>TibcoMaps - Svg Tibco Layer</title>
  <meta charset="UTF-8">

  <link rel="stylesheet" href="svg-tibco-layer.css"/>
  <link rel="stylesheet" href='../lib/fonts-stylesheet.css' type="text/css" charset="utf-8" />

  <!-- Javascript -->
  <script type="text/javascript" src='../lib/GeoAnalytics.js'></script>
  <script type="text/javascript" src='../lib/jquery-1.9.1.min.js'></script>
  <script type="text/javascript" src="svg-tibco-layer.js"></script>
</head>

  <body>
    <div class="custom-container">
      <div id="map"></div>
    </div>
  </body>
</html>
body,
html {
  height: 100%;
  width: 100%;
  margin: 0px;
}

.custom-container {
  position: absolute;
  top: 0px;
  bottom: 0px;
  left: 0px;
  right: 0px;
}

#map {
  width: 100vw;
  height: 100vh;
}