Skip to content
Snippets Groups Projects
Commit 8e8f201c authored by robcast's avatar robcast
Browse files

fixed typo.

parent bde8c46c
Branches
Tags
No related merge requests found
...@@ -278,24 +278,24 @@ ...@@ -278,24 +278,24 @@
pos = geom.position(newshape.geometry.coordinates[0]); pos = geom.position(newshape.geometry.coordinates[0]);
// create annotation shape // create annotation shape
annoShape = {'type': 'point', 'geometry': pos}; annoShape = {'type': 'point', 'geometry': pos};
annoshape.geometry['units'] = 'fraction'; annoShape.geometry['units'] = 'fraction';
} else if (type === 'Rectangle') { } else if (type === 'Rectangle') {
pos = geom.position(newshape.geometry.coordinates[0]); pos = geom.position(newshape.geometry.coordinates[0]);
var pt2 = geom.position(newshape.geometry.coordinates[1]); var pt2 = geom.position(newshape.geometry.coordinates[1]);
var rect = geom.rectangle(pos, pt2); var rect = geom.rectangle(pos, pt2);
// create annotation shape // create annotation shape
annoShape = {'type': 'rectangle', 'geometry': rect}; annoShape = {'type': 'rectangle', 'geometry': rect};
annoshape.geometry['units'] = 'fraction'; annoShape.geometry['units'] = 'fraction';
} else if (type === 'Polygon') { } else if (type === 'Polygon') {
pos = geom.position(newshape.geometry.coordinates[0]); pos = geom.position(newshape.geometry.coordinates[0]);
// create annotation shape // create annotation shape
annoShape = {'type': 'polygon', 'geometry': {'coordinates': newshape.geometry.coordinates}}; annoShape = {'type': 'polygon', 'geometry': {'coordinates': newshape.geometry.coordinates}};
annoshape.geometry['units'] = 'fraction'; annoShape.geometry['units'] = 'fraction';
} else if (type === 'LineString') { } else if (type === 'LineString') {
pos = geom.position(newshape.geometry.coordinates[0]); pos = geom.position(newshape.geometry.coordinates[0]);
// create annotation shape // create annotation shape
annoShape = {'type': 'linestring', 'geometry': {'coordinates': newshape.geometry.coordinates}}; annoShape = {'type': 'linestring', 'geometry': {'coordinates': newshape.geometry.coordinates}};
annoshape.geometry['units'] = 'fraction'; annoShape.geometry['units'] = 'fraction';
} else { } else {
console.error("Unsupported annotation shape="+type); console.error("Unsupported annotation shape="+type);
return; return;
...@@ -399,7 +399,7 @@ ...@@ -399,7 +399,7 @@
}, },
'properties' : { 'properties' : {
'stroke' : 'yellow', 'stroke' : 'yellow',
'cssclass' : cssPrefix+'svg-annotationregion annotator-hl', 'cssclass' : cssPrefix+'svg-annotation annotator-hl',
'style' : 'pointer-events:all' 'style' : 'pointer-events:all'
}, },
'annotation': annotation 'annotation': annotation
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment