Пример #1
0
 public virtual void Draw(IRenderer Renderer)
 {
     if (DefaultDrawHandler != null)
     {
         DefaultDrawHandler.Draw(Renderer);
     }
 }
Пример #2
0
        public void DrawShape(IRenderer Renderer, IDrawableRect ShapeToDraw)
        {
            // Substitute the Renderer'child DrawOperations with our own,
            // smart, coordinate translating DrawOperations
            // (Scroller : TranslateTransform : DrawOperations)
            Scroller.SourceDrawOperations = Renderer.DrawOperations;
            Renderer.DrawOperations       = Scroller;

            // Draw on modified Renderer:
            // all coordinates are recalculated while drawing
            ShapeToDraw.Draw(Renderer);

            // restore the Renderer's child default DrawOperations
            Renderer.DrawOperations = Scroller.SourceDrawOperations;
        }
Пример #3
0
        public void DrawShape(IRenderer Renderer, IDrawableRect ShapeToDraw)
        {
            // Substitute the Renderer'child DrawOperations with our own,
            // smart, coordinate translating DrawOperations
            // (Scroller : TranslateTransform : DrawOperations)
            Scroller.SourceDrawOperations = Renderer.DrawOperations;
            Renderer.DrawOperations = Scroller;

            // Draw on modified Renderer:
            // all coordinates are recalculated while drawing
            ShapeToDraw.Draw(Renderer);

            // restore the Renderer's child default DrawOperations
            Renderer.DrawOperations = Scroller.SourceDrawOperations;
        }