コード例 #1
0
 public void addPlate(Plate p)
 {
     p.setXCoord(ColBorderFromX - (p.getWidth() / 2)); // Devide by 2 to center the plate.
     p.setYCoord(minColBase);
     Plates.Add(p);
     minColBase -= 23;
 }
コード例 #2
0
        public void reDrawPlates()
        {
            Graphics PlatesPlotter = MainPanel.CreateGraphics();

            for (int i = 0; i < Board.Columns.Count; i++)
            {
                for (int j = 0; j < Board.Columns[i].Plates.Count; j++)
                {
                    Plate temp = Board.Columns[i].Plates[j];
                    PlatesPlotter.FillRectangle(new SolidBrush(Color.Red), new Rectangle(temp.getXCoord(), temp.getYCoord(), temp.getWidth(), temp.getHeight()));
                }
            }
        }