-
Notifications
You must be signed in to change notification settings - Fork 2
/
label.html
160 lines (155 loc) · 4.42 KB
/
label.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
<!doctype html>
<html lang="en">
<head>
<title>Openlayer label with collide check</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no, width=device-width">
<link href="Css/ol.css" rel="stylesheet" />
<link rel="stylesheet" href="Css/bootstrap.min.css" type="text/css">
</head>
<style type="text/css">
body {
padding: 0;
margin: 0;
cursor: default;
width: 98%;
height: 95%;
}
header {display:block;position:fixed;background:#222;color:#eee;width:98%;}
#map{
position:absolute;
top:40px;
width: 98%;
height: 90%;
background-color: #deeff7;
/* 渐变背景 */
transition: background, 1.4s;
}
#layertree{
background-color: rgba(155,155,155,0.6);
border-radius: 6px;
position: absolute;
right:10px;
top:40px;
display: none;
padding-right: 20px;
}
#mouse-position{
position: absolute;
left: 20px;
top: 560px;
}
#plot{
pointer-events: none;
position: absolute;
top:400px;
left:20px;
}
.bar{
pointer-events: auto;
fill:#AFAFB9;
}
/*.bar.selected:{
fill:green;
}*/
.tip{
position: absolute;
background: black;
color:white;
padding:6px;
font-size: 12px;
border-radius: 4px;
margin-bottom: 10px;
display: none;
opacity: 0;
}
#info {
position: absolute;
height: 1px;
width: 1px;
z-index: 100;
}
#shpfile{
height: 80px;
width: 200px;
border:dashed 1.5px grey;
}
.tooltip.in {
opacity: 1;
filter: alpha(opacity=100);
}
.tooltip.top .tooltip-arrow {
border-top-color: white;
}
.tooltip-inner {
border: 2px solid white;
}
.layers{
text-decoration: none;
list-style: none;
}
.checkbox{
width: 100px;
}
.opacity
{
width: 100px;
}
</style>
<body>
<header>
<h5>Label Engine with collide check, pls wait for road data loading...</h5>
</header>
<div id="map"><div id="info"></div></div>
<div id="mouse-position"></div>
<div id="plot"></div>
<div id="layertree" class="span6">
<ul class="layers">
<!--<li id="layerb">
<label class="checkbox" for="vlayerb">
<input id="vlayerb" class="visible" type="checkbox">layername</input>
<input class="opacity" type="range" min="0" max="1" step="0.01"></input>
</label>
</li>-->
</ul>
</div>
<div id="drawpanel">
<!-- <div id="toggledraw"></div> -->
<!-- <label>Geometry type </label>
<select id="type">
<option value="None">None</option>
<option value="Point">Point</option>
<option value="LineString">LineString</option>
<option value="Polygon">Polygon</option>
</select>
<button id="removedraw">取消绘制</button>
<button id="removedrawed">清除绘制</button>
<button id="exportkml">导出kml格式</button>
<button id="exportgeojson">导出geojson格式</button>
<input id="lnglat" type="text" value="121.31 31.312"></input>
<button id="addpoint">addpoint</button>
-->
<br>
<!-- <input type="checkbox" name="bufferHelper" id="bufferHelper" onchange="toggleHelper()">
<label for="bufferHelper">辅助多边形</label>
<input type="checkbox" name="labelSwitch" id="labelSwitch" onchange="toggleLabel()" checked>
<label for="labelSwitch">标注开关</label>
<input type="checkbox" name="distSwitch" id="distSwitch" onchange="toggleStrategy()" checked>
<label for="distSwitch">距离检测算法(默认配置)</label> -->
<!--<input type="file" name="shpfile" id="shpfile" onchange="fileselect()">拖放shp/json/csv/txt文件</input>
<div id="selectinfo" class="alert alert-success">
</div>-->
</div>
</body>
<script src="Scripts/label/ol4.js"></script>
<script src="Scripts/label/settextpathstyle.js"></script>
<script src="Scripts/label/labelUtils.js"></script>
<script src="Scripts/label/layercontrol.js"></script>
<script src="Scripts/jquery-1.11.1.min.js"></script>
<script src="Scripts/bootstrap.min.js"></script>
<script src="Scripts/label/shp.js"></script>
<script src='Scripts/label/labelHtml.js'></script>
<script src="Scripts/label/interactions.js"></script>
</html>