Exemplo n.º 1
0
        public static LabelBox FromXml(XmlReader reader, Map map)
        {
            var labelBox = new LabelBox();
            labelBox.Map = map;
            labelBox.ReadXml(reader);

            return labelBox;
        }
Exemplo n.º 2
0
 public MapWrapper(Map map)
     :base(map)
 {
     _map = map;
 }
Exemplo n.º 3
0
 public MapRenderer(Renderer renderer, Map map)
     : base(renderer, map, null)
 {
     _map = map;
 }
Exemplo n.º 4
0
 private void InitMap()
 {
     _map = new Map();
     _map.NodeTypes.Add(SpatialiteLayer.NodeType.ElementName, SpatialiteLayer.NodeType);
     _map.Changed += new EventHandler(map_Changed);
 }
Exemplo n.º 5
0
		private bool PromptToSaveChanges(Map map)
		{
			if (!_mapHasChanges)
				return true;
			
			var result = MessageBox.Show("Save changes?", Application.ProductName, MessageBoxButtons.YesNoCancel);
			if (result == DialogResult.Yes)
				return Save();
			return (result == DialogResult.No);
		}
Exemplo n.º 6
0
 public void SetMap(Map map)
 {
     Clear();
     AddMapNode(_mapNode, map);
 }
Exemplo n.º 7
0
        public TreeNode AddMapNode(TreeNode parent, Map map)
        {
            Debug.Assert(_mapNode == null);
            if (_treeView != null)
                _treeView.AfterCheck -= _treeView_AfterCheck;

            var node = AddGroupNode(parent, map);
            node.Expand();
            node.Tag = new MapWrapper(map);

            if (_treeView != null)
                _treeView.AfterCheck += _treeView_AfterCheck;

            return node;
        }
Exemplo n.º 8
0
        public override object Clone()
        {
            var map = new Map();
            map.BackgroundColor = BackgroundColor;
            map.Base = Base;

            foreach (var node in Nodes)
                map.Nodes.Add((ThemeNode)node.Clone());

            return map;
        }