Show and hide layers in a drawing
HTML Drawing Control
Show and hide layers in a drawing
You can give the user the ability to display and hide drawing layers in the HTML drawing. The user will check and clear the checkboxes for the layers that they want to display.
To add the layer menu to your view:
-
In the .axvw file, reference
drawing-common-controls :
<panel type="view" id="highlightStylesView" file="drawing-common-controls.axvw"/>
-
In .js file, add ‘LayersPopup’ to addOnsConfig parameter before constructing DrawingControl object.
parameters['addOnsConfig'] = { … 'LayersPopup': {divId: "svgDiv"}, }; this.svgControl = new Drawing.DrawingControl("svgDiv", "svg_ctrls", parameters);