Ejemplo n.º 1
0
 /// <summary>
 /// Fires the OnBufferChanged event
 /// </summary>
 /// <param name="clipRectangles">The Rectangle in pixels</param>
 protected virtual void OnBufferChanged(List <Rectangle> clipRectangles)
 {
     if (BufferChanged != null)
     {
         ClipArgs e = new ClipArgs(clipRectangles);
         BufferChanged(this, e);
     }
 }
Ejemplo n.º 2
0
 public static void Clip(ClipArgs args) { args.Callback.Invoke(); }
Ejemplo n.º 3
0
        protected void MapFrame_BufferChanged(object sender, ClipArgs e)
        {
            Rectangle view = MapFrame.View;
            foreach (Rectangle clip in e.ClipRectangles)
            {
                if (clip.IsEmpty == false)
                {
                    var mapClip = new Rectangle(clip.X - view.X, clip.Y - view.Y, clip.Width, clip.Height);
                    Invalidate(mapClip);
                }
            }

        }