-
Notifications
You must be signed in to change notification settings - Fork 17
/
noncart.html
50 lines (48 loc) · 2.44 KB
/
noncart.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
<!DOCTYPE html>
<html lang="ru">
<head>
<meta charset="utf-8">
<title>Non-Cartographic / Canvas векторная карта</title>
<meta name="description" content="Надпись на холсте, Canvas векторная карта">
<link rel="icon" href="img/fav.svg" type="image/svg+xml">
<script src="/static/js/metrics.js" data-floor="1"></script>
</head>
<body>
<script src="js/proj4js-combined.js"></script>
<script src="js/dbcarta.js"></script>
<script>
function init() {
document.body.id = 'mcont';
DV = new dbCarta({id: 'mcont', draggable: false});
DV.style.backgroundColor = 'white';
DV.style.border = '1px dashed lightgray';
// center by A
var points = DV.toPoints([-76,82], true);
DV.centerCarta(points[0] + DV.m.offset[0], points[1] + DV.m.offset[1]);
DV.changeProject(203);
DV.scaleCarta(4);
// add new layer
DV.mopt['.Arctic']['fg'] = 'white';
DV.mopt['.Water']['bg'] = 'white';
DV.mopt['yellow'] = {cls: 'Polygon', fg: 'black', bg: 'yellow'};
DV.mopt['red'] = {cls: 'Polygon', fg: 'black', bg: 'red'};
DV.mopt['hole'] = {cls: 'Polygon', fg: 'black', bg: 'white'};
DV.loadCarta([['yellow','D1',[[-178,80],[-178,70],[-158,73],[-158,77],[-178,80]],'D',null,true]],1);
DV.loadCarta([['hole','D2',[[-175,78],[-175,72],[-161,74],[-161,76],[-175,78]]]],1);
DV.loadCarta([['red','B1',[[-148,80],[-148,70],[-128,73],[-142,75],[-128,77],[-148,80]],'B',null,true]],1);
DV.loadCarta([['hole','B2',[[-145,78],[-145,75.5],[-138,77],[-145,78]]]],1);
DV.loadCarta([['hole','B3',[[-145,74],[-145,71.5],[-138,73],[-145,74]]]],1);
DV.loadCarta([['yellow','C',[[-98,80],[-118,83],[-118,70],[-98,73],[-101,75],[-115,73],[-115,80],[-101,78],[-98,80]],'C',null,true]],1);
DV.loadCarta([['red','A1',[[-76,80],[-86,70],[-78,70],[-77,74],[-75,74],[-74,70],[-66,70],[-76,80]],'A',null,true]],1);
DV.loadCarta([['hole','A2',[[-76,77],[-77,75],[-75,75],[-76,77]]]],1);
DV.loadCarta([['yellow','R1',[[-58,80],[-58,70],[-53,70],[-53,73],[-44,70],[-38,70],[-52,75],[-38,77],[-58,80]],'R',null,true]],1);
DV.loadCarta([['hole','R2',[[-55,78],[-55,75.5],[-48,77],[-55,78]]]],1);
DV.loadCarta([['red','T',[[-28,80],[-28,77],[-20,77],[-20,70],[-12,70],[-12,77],[-4,77],[-4,80],[-28,80]],'T',null,true]],1);
DV.loadCarta([['yellow','A3',[[14,80],[4,70],[12,70],[13,74],[15,74],[16,70],[24,70],[14,80]],'A',null,true]],1);
DV.loadCarta([['hole','A4',[[14,77],[13,75],[15,75],[14,77]]]],1);
DV.m.domap = true; // map area
};
init();
</script>
</body>
</html>