void DrawBGBorder() { using (var border = new Pen(Color.Black, MazeSettings.CurrentBorderSize)) { MapRows.ToList().ForEach(a => MzGraphics.DrawLine(border, new PointF(MapRectF.X, a), new PointF(MapRectF.Right, a))); MapCols.ToList().ForEach(a => MzGraphics.DrawLine(border, new PointF(a, MapRectF.Y), new PointF(a, MapRectF.Bottom))); } }
void DrawBGDotted() { using (var dotted = new Pen(Color.Gray, 1)) { dotted.DashStyle = DashStyle.Dash; MapRows.ToList().Aggregate((a, n) => { var x = (a + n) / 2; MzGraphics.DrawLine(dotted, new PointF(MapRectF.X, x), new PointF(MapRectF.Right, x)); return(n); }); MapCols.ToList().Aggregate((a, n) => { var x = (a + n) / 2; MzGraphics.DrawLine(dotted, new PointF(x, MapRectF.Y), new PointF(x, MapRectF.Bottom)); return(n); }); } }