Example #1
0
        static void UpdateInvalidArea(GdiPlusDrawBoard d, IRenderElement rootElement)
        {
            int enter_canvasX = d.OriginX;
            int enter_canvasY = d.OriginY;

            d.SetCanvasOrigin(enter_canvasX - d.Left, enter_canvasY - d.Top);

            UpdateArea u = GetFreeUpdateArea();

            u.CurrentRect = d.InvalidateArea;

            if (u.Width > 0 && u.Height > 0)
            {
                rootElement.Render(d, u);
#if DEBUG
                rootElement.dbugShowRenderPart(d, u);
#endif
            }
            else
            {
            }


            d.IsContentReady = true;
            d.SetCanvasOrigin(enter_canvasX, enter_canvasY);//restore

            ReleaseUpdateArea(u);
        }
        static void UpdateAllArea(PixelFarm.Drawing.Skia.MySkiaCanvas mycanvas, IRenderElement topWindowRenderBox)
        {
            mycanvas.OffsetCanvasOrigin(-mycanvas.Left, -mycanvas.Top);
            Rectangle rect = mycanvas.Rect;
            topWindowRenderBox.DrawToThisCanvas(mycanvas, rect);
#if DEBUG
            topWindowRenderBox.dbugShowRenderPart(mycanvas, rect);
#endif

            mycanvas.IsContentReady = true;
            mycanvas.OffsetCanvasOrigin(mycanvas.Left, mycanvas.Top);
        }
Example #3
0
        static void UpdateAllArea(PixelFarm.Drawing.Skia.MySkiaDrawBoard mycanvas, IRenderElement topWindowRenderBox)
        {
            mycanvas.OffsetCanvasOrigin(-mycanvas.Left, -mycanvas.Top);
            Rectangle rect = mycanvas.Rect;

            topWindowRenderBox.DrawToThisCanvas(mycanvas, rect);
#if DEBUG
            topWindowRenderBox.dbugShowRenderPart(mycanvas, rect);
#endif

            mycanvas.IsContentReady = true;
            mycanvas.OffsetCanvasOrigin(mycanvas.Left, mycanvas.Top);
        }
Example #4
0
        static void UpdateInvalidArea(MyScreenCanvas mycanvas, IRenderElement rootElement)
        {
            mycanvas.OffsetCanvasOrigin(-mycanvas.Left, -mycanvas.Top);
            Rectangle rect = mycanvas.InvalidateArea;

            rootElement.DrawToThisCanvas(mycanvas, rect);
#if DEBUG
            rootElement.dbugShowRenderPart(mycanvas, rect);
#endif

            mycanvas.IsContentReady = true;
            mycanvas.OffsetCanvasOrigin(mycanvas.Left, mycanvas.Top);
        }
        static void UpdateAllArea(Canvas mycanvas, IRenderElement topWindowRenderBox)
        {
            mycanvas.OffsetCanvasOrigin(-mycanvas.Left, -mycanvas.Top);
            Rectangle rect = mycanvas.Rect;

            //mycanvas.FillRectangle(Color.Blue, 50, 50, 100, 100);
            topWindowRenderBox.DrawToThisCanvas(mycanvas, rect);

#if DEBUG
            topWindowRenderBox.dbugShowRenderPart(mycanvas, rect);
#endif

            mycanvas.IsContentReady = true;
            mycanvas.OffsetCanvasOrigin(mycanvas.Left, mycanvas.Top);
        }
Example #6
0
        static void UpdateInvalidArea(GdiPlusDrawBoard mycanvas, IRenderElement rootElement)
        {
            mycanvas.OffsetCanvasOrigin(-mycanvas.Left, -mycanvas.Top);
            Rectangle rect = mycanvas.InvalidateArea;

            if (rect.Width > 0 && rect.Height > 0)
            {
                rootElement.DrawToThisCanvas(mycanvas, rect);
#if DEBUG
                rootElement.dbugShowRenderPart(mycanvas, rect);
#endif
            }
            else
            {
            }


            mycanvas.IsContentReady = true;
            mycanvas.OffsetCanvasOrigin(mycanvas.Left, mycanvas.Top);
        }
Example #7
0
        //-------
        static void UpdateAllArea(GdiPlusDrawBoard d, IRenderElement topWindowRenderBox)
        {
            int enter_canvasX = d.OriginX;
            int enter_canvasY = d.OriginY;

            d.SetCanvasOrigin(enter_canvasX - d.Left, enter_canvasY - d.Top);

            UpdateArea u = GetFreeUpdateArea();

            u.CurrentRect = d.Rect;
            topWindowRenderBox.Render(d, u);

#if DEBUG
            topWindowRenderBox.dbugShowRenderPart(d, u);
#endif

            d.IsContentReady = true;
            d.SetCanvasOrigin(enter_canvasX, enter_canvasY);//restore

            ReleaseUpdateArea(u);
        }
Example #8
0
        static void UpdateInvalidArea(MyGdiPlusCanvas mycanvas, IRenderElement rootElement)
        {
            mycanvas.OffsetCanvasOrigin(-mycanvas.Left, -mycanvas.Top);
            Rectangle rect = mycanvas.InvalidateArea;
            rootElement.DrawToThisCanvas(mycanvas, rect);
#if DEBUG
            rootElement.dbugShowRenderPart(mycanvas, rect);
#endif

            mycanvas.IsContentReady = true;
            mycanvas.OffsetCanvasOrigin(mycanvas.Left, mycanvas.Top);
        }