Пример #1
0
        public void DrawActiveRectangle(Graphics graph, Rectangle rect, HightlightStyle state, bool bSubRect)
        {
            if (bSubRect == true)
            {
                rect.Width--;
                rect.Height--;
            }

            DrawActiveRectangle(graph, rect, state);
        }
Пример #2
0
        /// <summary>
        /// Draw Active rectangle by blue colors
        /// </summary>
        /// <param name="graph"></param>
        /// <param name="rect"></param>
        public void DrawActiveRectangle(Graphics graph, Rectangle rect, HightlightStyle state)
        {
            Color highlight = (state == HightlightStyle.Active) ?
                              Color.FromArgb(182, 189, 210) : Color.FromArgb(212, 213, 216);

            Color highBorder = Color.FromArgb(10, 36, 106);

            SolidBrush high    = new SolidBrush(highlight);
            SolidBrush bord    = new SolidBrush(highBorder);
            Pen        penBord = new Pen(bord);

            graph.FillRectangle(high, rect);
            graph.DrawRectangle(penBord, rect);

            penBord.Dispose();
            bord.Dispose();
            high.Dispose();
        }
Пример #3
0
 /// <summary>
 /// Draw Active rectangle.
 /// </summary>
 /// <param name="graph">Graphic context where premitive must be draw</param>
 /// <param name="rect">Destination Rectangle</param>
 /// <param name="state">State of rectangle. Influence on colors by which rectangle
 /// will be drawed</param>
 /// <param name="bSubRect">Indicate do we need rectangle width and height fix</param>
 public void DrawActiveRectangle( Graphics graph, Rectangle rect, HightlightStyle state, bool bSubRect )
 {
     Rectangle rc = ( bSubRect ) ? FixRectangleHeightWidth( rect ) : rect;
       DrawActiveRectangle( graph, rc, state );
 }
Пример #4
0
        /// <summary>
        /// Draw Active rectangle by blue colors
        /// </summary>
        /// <param name="graph">Graphic context where premitive must be draw</param>
        /// <param name="rect">Destination Rectangle</param>
        /// <param name="state">State of rectangle. Influence on colors by which rectangle
        /// will be drawed</param>
        public void DrawActiveRectangle( Graphics graph, Rectangle rect, HightlightStyle state )
        {
            Color highlight = ( state == HightlightStyle.Active ) ?
            ColorUtil.VSNetBackgroundColor : ColorUtil.VSNetSelectionColor;
              //        Color.FromArgb( 182, 189, 210 ) : Color.FromArgb(212,213,216);

              Color highBorder = SystemColors.Highlight;
              //Color.FromArgb( 10, 36, 106 );

              SolidBrush high = new SolidBrush( highlight );
              SolidBrush bord = new SolidBrush( highBorder );
              Pen penBord = new Pen( bord );

              graph.FillRectangle( high, rect );
              graph.DrawRectangle( penBord, rect );

              penBord.Dispose();
              bord.Dispose();
              high.Dispose();
        }
Пример #5
0
        /// <summary>
        /// Draw Active rectangle.
        /// </summary>
        /// <param name="graph">Graphic context where premitive must be draw</param>
        /// <param name="rect">Destination Rectangle</param>
        /// <param name="state">State of rectangle. Influence on colors by which rectangle
        /// will be drawed</param>
        /// <param name="bSubRect">Indicate do we need rectangle width and height fix</param>
        public void DrawActiveRectangle(Graphics graph, Rectangle rect, HightlightStyle state, bool bSubRect)
        {
            Rectangle rc = (bSubRect) ? FixRectangleHeightWidth(rect) : rect;

            DrawActiveRectangle(graph, rc, state);
        }