Files
maintenance_system/public/sdk/docs/Model.html
2025-10-11 09:56:33 +08:00

2356 lines
40 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>接口文档 Class: Model</title>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">
<link type="text/css" rel="stylesheet" href="styles/site.Cerulean.css">
</head>
<body>
<div class="navbar navbar-default navbar-fixed-top navbar-inverse">
<div class="container">
<div class="navbar-header">
<a class="navbar-brand" href="index.html">接口文档</a>
<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<div class="navbar-collapse collapse" id="topNavigation">
<ul class="nav navbar-nav">
<li class="dropdown">
<a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
<ul class="dropdown-menu ">
<li><a href="Draw.html">Draw</a></li><li><a href="DrawAssemble.html">DrawAssemble</a></li><li><a href="DrawPoint.html">DrawPoint</a></li><li><a href="DrawPolygon.html">DrawPolygon</a></li><li><a href="DrawPolyline.html">DrawPolyline</a></li><li><a href="DrawRect.html">DrawRect</a></li><li><a href="DrawSector.html">DrawSector</a></li><li><a href="DrawStraightArrow.html">DrawStraightArrow</a></li><li><a href="DrawThreeRect.html">DrawThreeRect</a></li><li><a href="module.exports.html">module.exports</a></li><li><a href="module.exports_module.exports.html">module.exports#module.exports</a></li><li><a href="Measure.html">Measure</a></li><li><a href="MeasureAzimuth.html">MeasureAzimuth</a></li><li><a href="MeasureCircle.html">MeasureCircle</a></li><li><a href="MeasureDistance.html">MeasureDistance</a></li><li><a href="MeasureHeight.html">MeasureHeight</a></li><li><a href="MeasureLocation.html">MeasureLocation</a></li><li><a href="MeasureProjectionDistance.html">MeasureProjectionDistance</a></li><li><a href="MeasureSlopeDistance.html">MeasureSlopeDistance</a></li><li><a href="MeasureTdArea.html">MeasureTdArea</a></li><li><a href="MeasureTriangle.html">MeasureTriangle</a></li><li><a href="MeasureTyArea.html">MeasureTyArea</a></li><li><a href="DrawTakeOff.html">DrawTakeOff</a></li><li><a href="CircleViewShed.html">CircleViewShed</a></li><li><a href="%25E7%25AD%2589%25E9%25AB%2598%25E7%25BA%25BF%25E5%2588%2586%25E6%259E%2590.html">等高线分析</a></li><li><a href="%25E5%25A1%25AB%25E6%258C%2596%25E6%2596%25B9%25E5%2588%2586%25E6%259E%2590.html">填挖方分析</a></li><li><a href="Flat.html">Flat</a></li><li><a href="%25E5%2589%2596%25E9%259D%25A2%25E5%2588%2586%25E6%259E%2590.html">剖面分析</a></li><li><a href="%25E5%2589%2596%25E5%2588%2587.html">剖切</a></li><li><a href="%25E5%259D%25A1%25E5%25BA%25A6%25E5%259D%25A1%25E5%2590%2591%25E5%2588%2586%25E6%259E%2590.html">坡度坡向分析</a></li><li><a href="Submerge.html">Submerge</a></li><li><a href="TerrainExcavation.html">TerrainExcavation</a></li><li><a href="Test.html">Test</a></li><li><a href="PolygonObject.html">PolygonObject</a></li><li><a href="ViewShedStage.html">ViewShedStage</a></li><li><a href="AssembleObject.html">AssembleObject</a></li><li><a href="AttackArrowObject.html">AttackArrowObject</a></li><li><a href="GdImagery.html">GdImagery</a></li><li><a href="Model.html">Model</a></li><li><a href="Model2.html">Model2</a></li><li><a href="BIM.html">BIM</a></li><li><a href="BaseTileset.html">BaseTileset</a></li><li><a href="Tileset.html">Tileset</a></li><li><a href="BatchModel.html">BatchModel</a></li><li><a href="BillboardObject.html">BillboardObject</a></li><li><a href="CircleDiffuse.html">CircleDiffuse</a></li><li><a href="CircleObject.html">CircleObject</a></li><li><a href="CurvelineObject.html">CurvelineObject</a></li><li><a href="EllipseObject.html">EllipseObject</a></li><li><a href="Explosion.html">Explosion</a></li><li><a href="FlowLine.html">FlowLine</a></li><li><a href="FlyRoam.html">FlyRoam</a></li><li><a href="GeoJson.html">GeoJson</a></li><li><a href="Graffiti.html">Graffiti</a></li><li><a href="GroundImage.html">GroundImage</a></li><li><a href="GroundSvg_loadEvent.html">GroundSvg#loadEvent</a></li><li><a href="Flame.html">Flame</a></li><li><a href="Fountain.html">Fountain</a></li><li><a href="Smoke.html">Smoke</a></li><li><a href="Spout.html">Spout</a></li><li><a href="PincerArrowObject.html">PincerArrowObject</a></li><li><a href="PolyhedronObject.html">PolyhedronObject</a></li><li><a href="PolylineObject.html">PolylineObject</a></li><li><a href="RadarScan.html">RadarScan</a></li><li><a href="RadarScanStereoscopic.html">RadarScanStereoscopic</a></li><li><a href="Corridor.html">Corridor</a></li><li><a href="Road.html">Road</a></li><li><a href="RoutePlanning.html">RoutePlanning</a></li><li><a href="SectorObject.html">SectorObject</a></li><li><a href="StraightArrowObject.html">StraightArrowObject</a></li><li><a href="TextBox.html">TextBox</a></li><li><a href="GroundText.html">GroundText</a></li><li><a href="StandText.html">StandText</a></li><li><a href="TrajectoryMotion.html">TrajectoryMotion</a></li><li><a href="TrajectoryMotionObject.html">TrajectoryMotionObject</a></li><li><a href="WallRealStereoscopic.html">WallRealStereoscopic</a></li><li><a href="WallStereoscopic.html">WallStereoscopic</a></li><li><a href="WallStereoscopic2.html">WallStereoscopic2</a></li><li><a href="WaterSurface.html">WaterSurface</a></li><li><a href="Tools.html">Tools</a></li><li><a href="CoordTransform.GCJ02ToBD09.html">CoordTransform.GCJ02ToBD09</a></li><li><a href="CoordTransform.GCJ02ToWGS84.html">CoordTransform.GCJ02ToWGS84</a></li><li><a href="YJEarth.html">YJEarth</a></li>
</ul>
</li>
<li class="dropdown">
<a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a>
<ul class="dropdown-menu ">
<li><a href="global.html#leftClickHandler">leftClickHandler</a></li><li><a href="global.html#edit">edit</a></li><li><a href="global.html#flyTo">flyTo</a></li><li><a href="global.html#remove">remove</a></li><li><a href="global.html#setRepeat">setRepeat</a></li><li><a href="global.html#cease">cease</a></li><li><a href="global.html#keyboardMapRoamingInit">keyboardMapRoamingInit</a></li><li><a href="global.html#getFlagFromKeyboard">getFlagFromKeyboard</a></li><li><a href="global.html#keyDown">keyDown</a></li><li><a href="global.html#keyUp">keyUp</a></li><li><a href="global.html#keyboardMapRoamingRender">keyboardMapRoamingRender</a></li><li><a href="global.html#Clear">Clear</a></li><li><a href="global.html#show">show</a></li><li><a href="global.html#delPosition">delPosition</a></li><li><a href="global.html#addPoint">addPoint</a></li><li><a href="global.html#rotationEditing">rotationEditing</a></li><li><a href="global.html#start%257D)">start
})</a></li><li><a href="global.html#end%257D)">end
})</a></li><li><a href="global.html#on">on</a></li><li><a href="global.html#BD_FACTOR">BD_FACTOR</a></li>
</ul>
</li>
</ul>
<div class="col-sm-3 col-md-3">
<form class="navbar-form" role="search">
<div class="input-group">
<input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
<div class="input-group-btn">
<button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
<div class="container" id="toc-content">
<div class="row">
<div class="col-md-8">
<div id="main">
<h1 class="page-title">Class: Model</h1>
<section>
<header>
<h2>
Model
</h2>
</header>
<article>
<div class="container-overview">
<hr>
<dt>
<h4 class="name" id="Model"><span class="type-signature"></span>new Model<span class="signature">(sdk, options)</span><span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
加载模型
</div>
<h5>Parameters:</h5>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>sdk</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="description last">sdk</td>
</tr>
<tr>
<td class="name"><code>options</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="description last">模型参数
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>id</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">唯一标识</td>
</tr>
<tr>
<td class="name"><code>show</code></td>
<td class="type">
<span class="param-type">boolean</span>
</td>
<td class="default">
true
</td>
<td class="description last">模型显隐</td>
</tr>
<tr>
<td class="name"><code>name</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">名称</td>
</tr>
<tr>
<td class="name"><code>url</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">资源地址</td>
</tr>
<tr>
<td class="name"><code>position</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">模型位置
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>lng</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">经度</td>
</tr>
<tr>
<td class="name"><code>lat</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">纬度</td>
</tr>
<tr>
<td class="name"><code>alt</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">高度</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>scale</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">比例
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>x</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
1
</td>
<td class="description last">x轴比例</td>
</tr>
<tr>
<td class="name"><code>y</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
1
</td>
<td class="description last">y轴比例</td>
</tr>
<tr>
<td class="name"><code>z</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
1
</td>
<td class="description last">z轴比例</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>maximumScale</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
100
</td>
<td class="description last">最大比例</td>
</tr>
<tr>
<td class="name"><code>minimumPixelSize</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
60
</td>
<td class="description last">最小像素</td>
</tr>
<tr>
<td class="name"><code>scaleByDistance</code></td>
<td class="type">
<span class="param-type">boolean</span>
</td>
<td class="default">
true
</td>
<td class="description last">随视野缩放</td>
</tr>
<tr>
<td class="name"><code>rotate</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">旋转角度
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>x</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">x轴旋转度数</td>
</tr>
<tr>
<td class="name"><code>y</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">y轴旋转度数</td>
</tr>
<tr>
<td class="name"><code>z</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">z轴旋转度数</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>label</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">标签对象
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>text</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">标签文本</td>
</tr>
<tr>
<td class="name"><code>show</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">标签显隐</td>
</tr>
<tr>
<td class="name"><code>position</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">标签位置</td>
</tr>
<tr>
<td class="name"><code>position</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">标签位置
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>lng</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">经度</td>
</tr>
<tr>
<td class="name"><code>lat</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">纬度</td>
</tr>
<tr>
<td class="name"><code>alt</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">高度</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>fontSize</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
20
</td>
<td class="description last">字体大小</td>
</tr>
<tr>
<td class="name"><code>fontFamily</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
0
</td>
<td class="description last">字体项 0黑体1思源黑体2庞门正道标题体3数黑体</td>
</tr>
<tr>
<td class="name"><code>color</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
#ffffff
</td>
<td class="description last">字体颜色</td>
</tr>
<tr>
<td class="name"><code>lineWidth</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
4
</td>
<td class="description last">引线宽</td>
</tr>
<tr>
<td class="name"><code>lineColor</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
#00ffff80
</td>
<td class="description last">引线颜色</td>
</tr>
<tr>
<td class="name"><code>pixelOffset</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
20
</td>
<td class="description last">字体偏移(引线长度)</td>
</tr>
<tr>
<td class="name"><code>backgroundColor</code></td>
<td class="type">
<span class="param-type">array</span>
</td>
<td class="default">
['#00ffff80',
</td>
<td class="description last">'#00ffff80'] 背景颜色</td>
</tr>
<tr>
<td class="name"><code>scaleByDistance</code></td>
<td class="type">
<span class="param-type">boolean</span>
</td>
<td class="default">
</td>
<td class="description last">距离缩放</td>
</tr>
<tr>
<td class="name"><code>near</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
2000
</td>
<td class="description last">视野缩放最近距离</td>
</tr>
<tr>
<td class="name"><code>far</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="default">
100000
</td>
<td class="description last">视野缩放最远距离</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>attribute</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">属性内容
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>link</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
{}
</td>
<td class="description last">链接
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>content</code></td>
<td class="type">
<span class="param-type">array</span>
</td>
<td class="default">
[]
</td>
<td class="description last">链接内容</td>
</tr>
<tr>
<td class="name"><code>content[].name</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">链接名称</td>
</tr>
<tr>
<td class="name"><code>content[].url</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">链接地址</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>richTextContent</code></td>
<td class="type">
<span class="param-type">string</span>
</td>
<td class="default">
</td>
<td class="description last">富文本内容</td>
</tr>
<tr>
<td class="name"><code>customView</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="default">
</td>
<td class="description last">默认视角
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>orientation</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="description last">默认视角方位
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>heading</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">航向角</td>
</tr>
<tr>
<td class="name"><code>pitch</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">俯仰角</td>
</tr>
<tr>
<td class="name"><code>roll</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">翻滚角</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td class="name"><code>relativePosition</code></td>
<td class="type">
<span class="param-type">object</span>
</td>
<td class="description last">视角相对位置
<h6 class="method-params-label method-subparams-label">Properties</h6>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>lng</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">经度</td>
</tr>
<tr>
<td class="name"><code>lat</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">纬度</td>
</tr>
<tr>
<td class="name"><code>alt</code></td>
<td class="type">
<span class="param-type">number</span>
</td>
<td class="description last">高度</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
</dd>
</div>
<h3 class="subsection-title">Members</h3>
<dl>
<hr>
<dt class="name" id="rotationEditing">
<h4 id="rotationEditing"><span class="type-signature"></span>rotationEditing<span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
打开模型旋转功能
</div>
<dl class="details">
</dl>
</dd>
</dl>
<h3 class="subsection-title">Methods</h3>
<dl>
<hr>
<dt>
<h4 class="name" id="edit"><span class="type-signature">&lt;async> </span>edit<span class="signature">(state)</span><span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
编辑框
</div>
<h5>Parameters:</h5>
<table class="params table table-striped">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>state</code></td>
<td class="type">
<span class="param-type">boolean</span>
</td>
<td class="default">
false
</td>
<td class="description last">状态: true打开, false关闭</td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
</dd>
</dl>
</article>
</section>
</div>
</div>
<div class="clearfix"></div>
<div class="col-md-3">
<div id="toc" class="col-md-3 hidden-xs hidden-sm hidden-md"></div>
</div>
</div>
</div>
<div class="modal fade" id="searchResults">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title">Search results</h4>
</div>
<div class="modal-body"></div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
</div>
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div>
<footer>
<span class="jsdoc-message">
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.11</a>
on 2025-09-01T10:14:35+08:00
using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
</span>
</footer>
<script src="scripts/docstrap.lib.js"></script>
<script src="scripts/toc.js"></script>
<script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>
<script>
$( function () {
$( "[id*='$']" ).each( function () {
var $this = $( this );
$this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
} );
$( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
var $this = $( this );
var example = $this.find( "code" );
exampleText = example.html();
var lang = /{@lang (.*?)}/.exec( exampleText );
if ( lang && lang[1] ) {
exampleText = exampleText.replace( lang[0], "" );
example.html( exampleText );
lang = lang[1];
} else {
var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
lang = langClassMatch ? langClassMatch[1] : "javascript";
}
if ( lang ) {
$this
.addClass( "sunlight-highlight-" + lang )
.addClass( "linenums" )
.html( example.html() );
}
} );
Sunlight.highlightAll( {
lineNumbers : true,
showMenu : true,
enableDoclinks : true
} );
$.catchAnchorLinks( {
navbarOffset: 10
} );
$( "#toc" ).toc( {
anchorName : function ( i, heading, prefix ) {
return $( heading ).attr( "id" ) || ( prefix + i );
},
selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
showAndHide : false,
smoothScrolling: true
} );
$( "#main span[id^='toc']" ).addClass( "toc-shim" );
$( '.dropdown-toggle' ).dropdown();
$( "table" ).each( function () {
var $this = $( this );
$this.addClass('table');
} );
} );
</script>
<!--Navigation and Symbol Display-->
<script>
$( function () {
$( '#main' ).localScroll( {
offset : { top : 60 } //offset by the height of your header (give or take a few px, see what works for you)
} );
$( "dt.name" ).each( function () {
var $this = $( this ).find("h4");
var icon = $( "<i/>" ).addClass( "icon-plus-sign" ).addClass( "pull-right" ).addClass( "icon-white" );
var dt = $(this);
var children = dt.next( "dd" );
dt.prepend( icon ).css( {cursor : "pointer"} );
dt.addClass( "member-collapsed" ).addClass( "member" );
children.hide();
dt.children().on( "click", function () {
children = dt.next( "dd" );
children.slideToggle( "fast", function () {
if ( children.is( ":visible" ) ) {
icon.addClass( "icon-minus-sign" ).removeClass( "icon-plus-sign" ).removeClass( "icon-white" );
dt.addClass( "member-open" ).animate( "member-collapsed" );
} else {
icon.addClass( "icon-plus-sign" ).removeClass( "icon-minus-sign" ).addClass( "icon-white" );
dt.addClass( "member-collapsed" ).removeClass( "member-open" );
}
} );
} );
} );
} );
</script>
<!--Google Analytics-->
<script type="text/javascript">
$(document).ready(function() {
SearcherDisplay.init();
});
</script>
</body>
</html>