ComponentOne Maps for WPF and Silverlight
C1Maps Control Basics / Tool Customization
In This Topic
    Tool Customization
    In This Topic

    The panning and zooming tools displayed by default in the map are implemented in the C1MapToolsLayer. It is included in C1Maps' template, so it's not necessary to add it to the Layers collection. To customize the tools you will first hide the default tools by setting C1Maps.ShowTools to False, and then add your own C1MapToolsLayer instance. Here is the XAML for this:

    XAML
    Copy Code
    <c1:C1Maps ShowTools="false">
        <c1:C1Maps.Layers>
            <c1:C1MapToolsLayer/>
        </c1:C1Maps.Layers>
    </c1:C1Maps>
    
     
    

    Note that you could also implement a different layer for the tools, but you'll just modify the template of the built-in tools in this example. Now, to edit this XAML in Blend, you can right-click the ToolsLayer and select Edit Control Parts (Template) | Edit a Copy:

    Now you can just edit the template in Blend, and the changes will be reflected in the map.

    See Also