コード例 #1
0
        /// <summary>
        /// Initializes class with graphics object</summary>
        /// <param name="graphics">Graphics object for drawing</param>
        public override void Init(D2dGraphics graphics)
        {
            base.Init(graphics);

            SelectedBrush  = graphics.CreateSolidBrush(Color.Tomato);//should have width of 3
            CollapsedBrush = graphics.CreateSolidBrush(Color.LightGray);
            InvalidBrush   = graphics.CreateSolidBrush(Color.DimGray);
            GroupBrush     = graphics.CreateLinearGradientBrush(
                new D2dGradientStop(Color.LightGoldenrodYellow, 0),
                new D2dGradientStop(Color.Khaki, 1));
            GhostGroupBrush = graphics.CreateSolidBrush(Color.FromArgb(128, Color.Gray));
            TrackBrush      = graphics.CreateSolidBrush(Color.LightGray);
            GhostTrackBrush = graphics.CreateSolidBrush(Color.FromArgb(128, Color.Gray));
            TextBrush       = graphics.CreateSolidBrush(SystemColors.WindowText);
        }