ThinkGeo.com    |     Documentation    |     Premium Support

About PanZoomBarMapTool Theme

Hi @Ethan
I want to change the style of PanZoomBarMap.The diagram below is a rendering

I’ve rewritten this class PanZoomBarMap like this:
public class OwnPanZoomBarMapTool:PanZoomBarMapTool
{
public override void OnApplyTemplate()
{
base.OnApplyTemplate();
var zoomInImage = (Image)base.GetTemplateChild(“ZoomInImage”);
zoomInImage.Source = new BitmapImage(new Uri(@“C:\Users\asus\Desktop\ThinkGeoGis\qq1.png”));
var canvasZoomBar = (Canvas)base.GetTemplateChild(“ZoomBar”);
canvasZoomBar.Background = Brushes.Transparent;
var canvasTip = (Canvas)base.GetTemplateChild(“ZoomHandlerTip”);
canvasTip.Background = Brushes.Transparent;
var grid = (Grid)base.GetTemplateChild(“PanPanel”);
grid.Background = Brushes.Transparent;
}
}
MapControl.MapTools.Clear();
OwnPanZoomBarMapTool ownPanZoomBarMapTool = new OwnPanZoomBarMapTool();
MapControl.MapTools.Add(ownPanZoomBarMapTool);

The mark above is what I want. How can i do?

Regards
ZhangMing

Hi Zhangming,

Thanks to let us know your requirement.

But your question is in fact a WPF control problem but not a map problem. Our track zoom bar don’t support customize skin for now, so maybe we cannot give your more suggestion about that, but I think the Snoop is a helpful utility.

If you have further custom requirement for our map, please feel free to contact our sales for professional service.

Regards,

Ethan

Hi @Ethan
Thank you for your answer.

Regards,
ZhangMing

Hi ZhangMing,

Any question please let us know.

Regards,

Ethan