private void SetupGraphControl()
        {
            GraphControlSilverlight.AllowGraphEditing        = true;
            GraphControlSilverlight.AllowLabelEditing        = true;
            GraphControlSilverlight.ShowExperimentalControls = true;

            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "Rounded Box", Shape = Microsoft.Msagl.Drawing.Shape.Box, XRadius = 5.0, YRadius = 5.0
            });
            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "Ellipse", Shape = Microsoft.Msagl.Drawing.Shape.Ellipse
            });
            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "Box", Shape = Microsoft.Msagl.Drawing.Shape.Box
            });
            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "Inv. House", Shape = Microsoft.Msagl.Drawing.Shape.InvHouse
            });
            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "House", Shape = Microsoft.Msagl.Drawing.Shape.House
            });
            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "Octagon", Shape = Microsoft.Msagl.Drawing.Shape.Octagon
            });
            GraphControlSilverlight.AddNodeType(new NodeTypeEntry()
            {
                Name = "Diamond", Shape = Microsoft.Msagl.Drawing.Shape.Diamond
            });
        }
        public MainPage()
        {
            InitializeComponent();

            SetupGraphControl();

            GraphControlSilverlight.Graph.Name = "GraphControl Test";
            CreateInitialGraph(GraphControlSilverlight.Graph);
            GraphControlSilverlight.BeginLayoutWithConstraints();

            DGraph.Name = "DGraph Test";
            CreateInitialGraph(DGraph);
            DGraph.BeginLayout();

            GraphControlForClusters.Graph.Name = "Clusters";
            CreateClusteredGraph();

            GraphControlForClusters_Complex.Name = "Complex Clusters";
            CreateComplexClusteredGraph();

            GraphControlForNesting.Graph.Name = "Nesting";
            CreateNestedGraph();

            GraphControlForNesting_Complex.Name = "Complex Nesting";
            CreateComplexNestedGraph();
            //*/
            //CreateGraphFromGeometry();
        }
        public MainPage()
        {
            InitializeComponent();

            SetupGraphControl();

            CreateInitialGraph(GraphControlSilverlight.Graph);
            CreateInitialGraph(DGraph);

            GraphControlSilverlight.BeginLayoutWithConstraints();
            DGraph.BeginLayout();
        }