Пример #1
0
 private void UpdateMsaglEdge(MsaglGraphs.Edge msaglEdge, SgvlGraphs.Edge sgvlEdge)
 {
     // Метка ребра
     UpdateMsaglEdgeLabel(msaglEdge, sgvlEdge);
     // Цвет ребра
     UpdateMsaglEdgeColor(msaglEdge, sgvlEdge);
 }
Пример #2
0
        private void OnEdgeColorChanged(SgvlGraphs.Edge edge)
        {
            var msaglEdge = MsaglGraph.EdgeById($"{edge.SourceVertex.Number}-{edge.TargetVertex.Number}");

            UpdateMsaglEdgeColor(msaglEdge, edge);
        }
Пример #3
0
 private void UpdateMsaglEdgeLabel(MsaglGraphs.Edge msaglEdge, SgvlGraphs.Edge sgvlEdge)
 {
     msaglEdge.LabelText = sgvlEdge.Label;
 }
Пример #4
0
 private void UpdateMsaglEdgeColor(MsaglGraphs.Edge msaglEdge, SgvlGraphs.Edge sgvlEdge)
 {
     msaglEdge.Attr.Color = new MsaglGraphs.Color(sgvlEdge.Color.A, sgvlEdge.Color.R, sgvlEdge.Color.G, sgvlEdge.Color.B);
 }
 private void UpdateMsaglEdgeBold(MsaglGraphs.Edge msaglEdge, SgvlGraphs.Edge sgvlEdge) {
     if (sgvlEdge.Bold)
         msaglEdge.Attr.LineWidth = 2;
     else
         msaglEdge.Attr.LineWidth = 1;
 }