private static void Level1Config(AureaColor systemColor, UPMCoIEdgeViewConfig parentEdgeConfigurationLevel1, UPMCoIEdgeViewConfig additionalEdgeConfiguration, UPMCoIViewConfig config)
        {
            var level = new UPMCoILevelViewConfig();

            var node = new UPMCoINodeViewConfig(AureaColor.RedGreenBlue(1.0, 1.0, 1.0), new Size(58, 58),
                                                AureaColor.RedGreenBlueAlpha(100.0 / 255.0, 162.0 / 255.0, 160.0 / 255.0, 1.0), 5.0f, 50.0f, true, true, true, new Size(75, 75),
                                                new Size(175, 175), int.MaxValue, new Size(150, 60), new Size(25, 40), new Size(0, 0), new Size(0, 0), 0.0f, new Size(0, 1), 1.0f,
                                                AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f), false, new Size(150, 100), 60.0f, 55, true,
                                                parentEdgeConfigurationLevel1, additionalEdgeConfiguration, 5, UPNodeViewAction.SelectNodeAndExpandCollapse, UPNodeViewAction.SelectNode,
                                                UPNodeViewAction.CustomViaDelegate, AureaColor.RedGreenBlueAlpha(187.0f / 255.0f, 187.0f / 255.0f, 187.0f / 255.0f, 1.0),
                                                AureaColor.RedGreenBlueAlpha(1.0, 1.0, 1.0, 1.0), 1.5f, 5, 17, AureaColor.RedGreenBlue(1.0, 1.0, 1.0), null, systemColor,
                                                null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null,
                                                null, null, null, null, null, null, null, null, null, null);

            level.AddConfig(node);

            UpdateRowConfig(
                systemColor,
                node,
                UIFont.FontWithNameSize(HelveticaNeue, 12),
                UIFont.FontWithNameSize(HelveticaNeue, 12),
                UIFont.FontWithNameSize(HelveticaNeue, 12),
                UIFont.FontWithNameSize(HelveticaNeue, 12));

            config.AddConfig(level);
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="UPMCoIEdgeViewConfig"/> class.
 /// </summary>
 public UPMCoIEdgeViewConfig()
     : this(UIFont.SystemFontOfSize(12), 5.0f, AureaColor.RedGreenBlue(2.0 / 3.0, 2.0 / 3.0, 2.0 / 3.0),
            AureaColor.RedGreenBlue(238.0f / 255.0f, 238.0f / 255.0f, 238.0f / 255.0f), 5.0f, 0.2f, /*kCALineJoinMiter*/ null, null, 0.0f, 1.0f, 0.4f, 0.0f,
            new Size(0, 1), AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f), 1.0f, 1, new Size(0, 1),
            AureaColor.RedGreenBlue(1.0, 1.0, 1.0), null, 12.0f, AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f),
            AureaColor.RedGreenBlue(255.0 / 255.0f, 90.0 / 255.0f, 16.0 / 255.0f), null, null, null, null, 1.0f, 1.0f,
            null, null, null, null, null, null, null, null)
 {
 }
예제 #3
0
 /// <summary>
 /// Rows the view configuration.
 /// </summary>
 /// <returns></returns>
 public static UPMCoITextRowViewConfig RowViewConfig()
 {
     return(new UPMCoITextRowViewConfig
     {
         Color = AureaColor.RedGreenBlue(102.0 / 255.0f, 102.0 / 255.0f, 102.0 / 255.0f),
         Font = UIFont.FontWithNameSize("HelveticaNeue", 10),
         ShadowColor = AureaColor.RedGreenBlue(1.0, 1.0, 1.0),
         ShadowOffset = new Size(0, 1)
     });
 }
예제 #4
0
 /// <summary>
 /// Selecteds the row view configuration.
 /// </summary>
 /// <returns></returns>
 public static UPMCoITextRowViewConfig SelectedRowViewConfig()
 {
     return(new UPMCoITextRowViewConfig
     {
         Color = AureaColor.UpCurrentSystemColor(),
         Font = UIFont.FontWithNameSize("HelveticaNeue", 10),
         ShadowColor = AureaColor.RedGreenBlue(1.0, 1.0, 1.0),
         ShadowOffset = new Size(0, 1)
     });
 }
        /// <summary>
        /// Initializes a new instance of the <see cref="UPMCoIViewConfigProvider"/> class.
        /// </summary>
        public UPMCoIViewConfigProvider()
        {
            var systemColor = AureaColor.UpCurrentSystemColor();

            this.configurations        = new List <UPMCoIViewConfig>();
            this.NodesViewType         = UPNodesViewType.Circle;
            this.EdgeViewType          = UPEdgeViewType.Line;
            this.ChildMoveType         = UPChildNodeMoveType.Always;
            this.MinNodes              = 3;
            this.PreAnimationDuration  = 0.25f;
            this.PostAnimationDuration = 0.25f;
            this.AnimationDuration     = 0.25f;
            this.FrameAndLabelAsBase   = true;
            this.LessOrMoreChildrenAnimationDuration = 0.4f;

            var parentEdgeConfigurationLevel1 = new UPMCoIEdgeViewConfig(UIFont.SystemFontOfSize(12), 5.0f,
                                                                         AureaColor.RedGreenBlue(2.0 / 3.0, 2.0 / 3.0, 2.0 / 3.0), AureaColor.RedGreenBlue(238.0f / 255.0f, 238.0f / 255.0f, 238.0f / 255.0f),
                                                                         5.0f, 0.2f, /*kCALineJoinMiter*/ null, null, 0.0f, 1.0f, 0.4f, 0.0f, new Size(0, 1), AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f),
                                                                         1.0f, 1.0f, new Size(0, 1), AureaColor.RedGreenBlue(1.0, 1.0, 1.0), null, 12.0f, AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f),
                                                                         AureaColor.RedGreenBlue(255.0 / 255.0, 90.0 / 255.0, 16.0 / 255.0), null, null, null, null, 1.0f, 1.0f, null, null, null, null, null, null, null, null);

            var parentEdgeConfigurationLevel2 = new UPMCoIEdgeViewConfig(UIFont.SystemFontOfSize(12), 5.0f,
                                                                         AureaColor.RedGreenBlue(2.0 / 3.0, 2.0 / 3.0, 2.0 / 3.0), AureaColor.RedGreenBlue(238.0f / 255.0f, 238.0f / 255.0f, 238.0f / 255.0f),
                                                                         3.0f, 0.2f, /*kCALineJoinMiter*/ null, null, 0.0f, 1.0f, 0.4f, 0.0f, new Size(0, 1), AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f),
                                                                         1.0f, 1.0f, new Size(0, 1), AureaColor.RedGreenBlue(1.0, 1.0, 1.0), null, 12.0f, AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f),
                                                                         AureaColor.RedGreenBlue(255.0 / 255.0f, 90.0 / 255.0f, 16.0 / 255.0f), null, null, null, null, 1.0f, 1.0f, null, null, null, null, null, null, null, null);

            var additionalEdgeConfiguration = new UPMCoIEdgeViewConfig(UIFont.SystemFontOfSize(12), 5.0f,
                                                                       AureaColor.RedGreenBlue(2.0 / 3.0, 2.0 / 3.0, 2.0 / 3.0), AureaColor.RedGreenBlue(238.0f / 255.0f, 238.0f / 255.0f, 238.0f / 255.0f),
                                                                       3.0f, 0.2f, /*kCALineJoinMiter*/ null, new List <int> {
                5, 5
            }, 0.0f, 1.0f, 0.4f, 0.0f, new Size(0, 1),
                                                                       AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f), 1.0f, 1, new Size(0, 1), AureaColor.RedGreenBlue(1.0, 1.0, 1.0),
                                                                       null, null, AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f), AureaColor.RedGreenBlue(255.0 / 255.0f, 90.0 / 255.0f, 16.0 / 255.0f),
                                                                       null, null, null, null, 1.0f, 1.0f, null, null, null, null, null, null, null, null);

            var config = new UPMCoIViewConfig();

            this.configurations.Add(config);

            Level0Config(systemColor, additionalEdgeConfiguration, config);
            Level1Config(systemColor, parentEdgeConfigurationLevel1, additionalEdgeConfiguration, config);
            Level2Config(systemColor, parentEdgeConfigurationLevel2, additionalEdgeConfiguration, config);
            Level3Config(systemColor, parentEdgeConfigurationLevel2, additionalEdgeConfiguration, config);
            Level4Config(systemColor, parentEdgeConfigurationLevel2, additionalEdgeConfiguration, config);
        }
예제 #6
0
        /// <summary>
        /// Initializes a new instance of the <see cref="UPMCoINodeViewConfig"/> class.
        /// </summary>
        public UPMCoINodeViewConfig()
            : this(AureaColor.RedGreenBlueAlpha(1.0, 1.0, 1.0, 1.0), new Size(44, 44), AureaColor.RedGreenBlueAlpha(206.0 / 255.0, 82.0 / 255.0, 126.0 / 255.0, 1.0),
                   2.0f, 50.0f, true, true, true, new Size(75, 75), new Size(75, 75), int.MaxValue, new Size(150, 60), new Size(25, 40), default(Size),
                   default(Size), 0.0f, new Size(0, 1), 1.0f, AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f), false,
                   new Size(150, 100), 60.0f, 55, true, new UPMCoIEdgeViewConfig(), null, 5,
                   UPNodeViewAction.SelectNodeAndExpandCollapse, UPNodeViewAction.SelectNode, UPNodeViewAction.CustomViaDelegate,
                   AureaColor.RedGreenBlueAlpha(187.0f / 255.0f, 187.0f / 255.0f, 187.0f / 255.0f, 1.0), AureaColor.RedGreenBlueAlpha(1.0, 1.0, 1.0, 1.0),
                   1.5f, 5, 14, AureaColor.RedGreenBlue(1.0, 1.0, 1.0), null, AureaColor.RedGreenBlue(255.0 / 255.0f, 90.0 / 255.0f, 16.0 / 255.0f),
                   null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null,
                   null, null, null, null, null, null, null, null, null, null)
        {
            UPMCoITextRowViewConfig rowConfig0 = this.TextRowConfigAtIndex(0);

            rowConfig0.Color        = AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f);
            rowConfig0.Font         = UIFont.FontWithNameSize("HelveticaNeue-Medium", 10);
            rowConfig0.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfig0.ShadowOffset = new Size(0, 1);
            rowConfig0.LineNumbers  = 1;
            UPMCoITextRowViewConfig rowConfigS0 = this.SelectedTextRowConfigAtIndex(0);

            rowConfigS0.Color        = AureaColor.RedGreenBlue(255.0 / 255.0f, 90.0 / 255.0f, 16.0 / 255.0f);
            rowConfigS0.Font         = UIFont.FontWithNameSize("HelveticaNeue-Medium", 10);
            rowConfigS0.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfigS0.ShadowOffset = new Size(0, 1);
            rowConfigS0.LineNumbers  = 1;
            UPMCoITextRowViewConfig rowConfig1 = this.TextRowConfigAtIndex(1);

            rowConfig1.Color        = AureaColor.RedGreenBlue(102.0 / 255.0f, 102.0 / 255.0f, 102.0 / 255.0f);
            rowConfig1.Font         = UIFont.FontWithNameSize("HelveticaNeue", 10);
            rowConfig1.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfig1.ShadowOffset = new Size(0, 1);
            rowConfig1.LineNumbers  = 1;
            UPMCoITextRowViewConfig rowConfigS1 = this.SelectedTextRowConfigAtIndex(1);

            rowConfigS1.Color        = AureaColor.RedGreenBlue(102.0 / 255.0f, 102.0 / 255.0f, 102.0 / 255.0f);
            rowConfigS1.Font         = UIFont.FontWithNameSize("HelveticaNeue", 10);
            rowConfigS1.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfigS1.ShadowOffset = new Size(0, 1);
            rowConfigS1.LineNumbers  = 1;
        }
        private static void UpdateRowConfig(
            AureaColor systemColor,
            UPMCoINodeViewConfig node,
            UIFont textFont0,
            UIFont selectedTextFont0,
            UIFont textFont1,
            UIFont selectedTextFont1)
        {
            var rowConfig0 = node.TextRowConfigAtIndex(0);

            rowConfig0.Color        = AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f);
            rowConfig0.Font         = textFont0;
            rowConfig0.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfig0.ShadowOffset = new Size(0, 1);
            rowConfig0.LineNumbers  = 1;

            var rowConfigS0 = node.SelectedTextRowConfigAtIndex(0);

            rowConfigS0.Color        = systemColor;
            rowConfigS0.Font         = selectedTextFont0;
            rowConfigS0.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfigS0.ShadowOffset = new Size(0, 1);
            rowConfigS0.LineNumbers  = 1;

            var rowConfig1 = node.TextRowConfigAtIndex(1);

            rowConfig1.Color        = AureaColor.RedGreenBlue(102.0 / 255.0f, 102.0 / 255.0f, 102.0 / 255.0f);
            rowConfig1.Font         = textFont1;
            rowConfig1.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfig1.ShadowOffset = new Size(0, 1);
            rowConfig1.LineNumbers  = 1;

            var rowConfigS1 = node.SelectedTextRowConfigAtIndex(1);

            rowConfigS1.Color        = systemColor;
            rowConfigS1.Font         = selectedTextFont1;
            rowConfigS1.ShadowColor  = AureaColor.RedGreenBlue(1.0, 1.0, 1.0);
            rowConfigS1.ShadowOffset = new Size(0, 1);
            rowConfigS1.LineNumbers  = 1;
        }
        private static void Level0Config(AureaColor systemColor, UPMCoIEdgeViewConfig additionalEdgeConfiguration, UPMCoIViewConfig config)
        {
            var level = new UPMCoILevelViewConfig();
            var node  = new UPMCoINodeViewConfig(AureaColor.RedGreenBlue(1.0, 1.0, 1.0), new Size(117, 117),
                                                 AureaColor.RedGreenBlueAlpha(179.0 / 255.0, 210.0 / 255.0, 103.0 / 255.0, 1.0), 8.0f, 50.0f, true, true, true, new Size(175, 175),
                                                 new Size(100, 100), int.MinValue, new Size(75, 50), new Size(40, 40), new Size(0, -25), new Size(0, 10), 0.0f, new Size(0, 1), 1.0f,
                                                 AureaColor.RedGreenBlue(219.0f / 255.0f, 219.0f / 255.0f, 219.0f / 255.0f), false, new Size(150, 100), 60.0f, 55, true, null,
                                                 additionalEdgeConfiguration, 5, UPNodeViewAction.SelectNodeAndExpandCollapse, UPNodeViewAction.SelectNode, UPNodeViewAction.RelayoutNode,
                                                 AureaColor.RedGreenBlueAlpha(187.0f / 255.0f, 187.0f / 255.0f, 187.0f / 255.0f, 1.0), AureaColor.RedGreenBlueAlpha(1.0, 1.0, 1.0, 1.0),
                                                 1.5f, 5, 26, AureaColor.RedGreenBlue(1.0, 1.0, 1.0), null, systemColor, null, null, null, null, null, null, null, null, null, null,
                                                 null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null);

            level.AddConfig(node);

            var rowConfig0 = node.TextRowConfigAtIndex(0);

            rowConfig0.Color = AureaColor.RedGreenBlue(51.0 / 255.0f, 51.0 / 255.0f, 51.0 / 255.0f);
            rowConfig0.Font  = UIFont.FontWithNameSize(HelveticaNeueBold, 13);

            var rowConfigS0 = node.SelectedTextRowConfigAtIndex(0);

            rowConfigS0.Color = systemColor;
            rowConfigS0.Font  = UIFont.FontWithNameSize(HelveticaNeueBold, 13);

            var rowConfig1 = node.TextRowConfigAtIndex(1);

            rowConfig1.Color = AureaColor.RedGreenBlue(102.0 / 255.0f, 102.0 / 255.0f, 102.0 / 255.0f);
            rowConfig1.Font  = UIFont.FontWithNameSize(HelveticaNeueMedium, 12);

            var rowConfigS1 = node.SelectedTextRowConfigAtIndex(1);

            rowConfigS1.Color = systemColor;
            rowConfigS1.Font  = UIFont.FontWithNameSize(HelveticaNeueMedium, 12);

            config.AddConfig(level);
        }