예제 #1
0
        public void Draw(Graphics g)
        {
            var brush = new SolidBrush(Color.FromArgb(255, 255, 255));

            g.FillRectangle(brush, ClientRectangle);
            var pen = new Pen(Color.FromArgb(0, 0, 255), 1);

            g.DrawRectangle(pen, 0, 0, SizePicture.Width, SizePicture.Height);
            if (_graphicsList != null)
            {
                _graphicsList.Draw(g);
            }
            brush.Dispose();
        }
예제 #2
0
        /// <summary>
        /// Draw graphic objects and
        /// group selection rectangle (optionally)
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void DrawArea_Paint(object sender, System.Windows.Forms.PaintEventArgs e)
        {
            SolidBrush brush = new SolidBrush(Color.FromArgb(255, 255, 255));

            e.Graphics.FillRectangle(brush,
                                     this.ClientRectangle);

            if (graphicsList != null)
            {
                graphicsList.Draw(e.Graphics);
            }

            DrawNetSelection(e.Graphics);

            brush.Dispose();
        }
예제 #3
0
파일: DrawArea.cs 프로젝트: Xaprice/XView
        /// <summary>
        /// Draw graphic objects and
        /// group selection rectangle (optionally)
        /// </summary>
        private void DrawArea_Paint(object sender, PaintEventArgs e)
        {
            e.Graphics.TranslateTransform((float)this.AutoScrollPosition.X, (float)this.AutoScrollPosition.Y);

            SolidBrush brush = new SolidBrush(Color.FromArgb(255, 255, 255));

            e.Graphics.FillRectangle(brush,
                                     this.ClientRectangle);

            if (graphicsList != null)
            {
                graphicsList.Draw(e.Graphics);
            }

            //DrawNetSelection(e.Graphics);

            brush.Dispose();
            e.Graphics.TranslateTransform(-(float)this.AutoScrollPosition.X, -(float)this.AutoScrollPosition.Y);
        }
예제 #4
0
 internal void Draw(Graphics g)
 {
     _graphicsList.Draw(g);
 }