protected override void DrawShape(UICanvas c) { Kernel.PrintDebug("Drawing shaaaapppe"); ShapeDraw(c); }
//private static Pixel[] GetAllPixels(Canvas c) //{ // PrintDebug("Getting all pixels..."); // var totalPixels = c.Mode.Columns * c.Mode.Rows; // PrintDebug("Creating array"); // Pixel[] allPoints = new Pixel[totalPixels]; // int x = 0, y = 0; // for (int i = 0; i < totalPixels; i++) // { // PrintDebug("Iteration : " + i + " - x : " + x + " ; y : " + y); // allPoints[i] = new Pixel(c.GetPointColor(x, y), new Point(x, y)); // y++; // if (y >= c.Mode.Columns - 1) // Go to the line under it // { // y = 0; // ++x; // it's better than x++ for some reason. // } // } // return allPoints; //} #endregion protected abstract void DrawShape(UICanvas c);
public UIEnvironment(UICanvas c) { Canvas = c; }
protected override void DrawShape(UICanvas c) { c.DrawFilledRectangleManual(new Pen(Color.LightGreen), 0, 0, columns, rows); }