Exemple #1
0
 protected override sealed void OnPaintBackground(PaintEventArgs e)
 {
     base.OnPaintBackground(e);
     if (view != null)
     {
         view.OnPaintBackground(new CGraphics(e.Graphics), Width, Height);
     }
 }
 protected internal override void OnPaintBackground(IGraphics g, int width, int height)
 {
     if (widths == null)
     {
         InitSizes(width, height);
     }
     for (int row = 0; row < RowCount; row++)
     {
         for (int col = 0; col < ColumnCount; col++)
         {
             Tuple <int, int> key = new Tuple <int, int>(row, col);
             if (components.ContainsKey(key))
             {
                 BasicView v = components[key];
                 g.TranslateTransform(xpos[col], ypos[row]);
                 v.OnPaintBackground(g, widths[col], heights[row]);
                 g.ResetTransform();
             }
         }
     }
 }