def create_cells(self):
     gdiplus.GdipResetPath(self.path_points)
     self.cells = []
     w = self.screen_size.x / self.cellw + 2
     h = self.screen_size.y / self.cellh + 2
     x1, x2, y1, y2 = 0, 0, 0, 0
     d = self.size_point / 2
     for x in range(w):
         x2 = x * self.cellw
         for y in range(h):
             y2 = y * self.cellh
             self.cells.append(RECT(x1, y1, x2, y2))
             status = gdiplus.GdipAddPathEllipse(self.path_points, x1 - d,
                                                 y1 - d, self.size_point,
                                                 self.size_point)
             y1 = y2
         x1 = x2
 def create_lines_3(self):
     gdiplus.GdipResetPath(self.path_lines)
     w = self.screen_size.x / self.cellw + 1
     h = self.screen_size.y / self.cellh + 1
     x, x1 = 0, 0
     while x < w:
         x += 1
         x1 = x * self.cellw
         status = gdiplus.GdipAddPathLineI(self.path_lines, x1, 0, x1,
                                           self.screen_size.y)
         x += 1
         x1 = x * self.cellw
         status = gdiplus.GdipAddPathLineI(self.path_lines, x1,
                                           self.screen_size.y, x1, 0)
     y, y1 = 0, 0
     while y < h:
         y += 1
         y1 = y * self.cellh
         status = gdiplus.GdipAddPathLineI(self.path_lines,
                                           self.screen_size.x, y1, 0, y1)
         y += 1
         y1 = y * self.cellh
         status = gdiplus.GdipAddPathLineI(self.path_lines, 0, y1,
                                           self.screen_size.x, y1)