Example #1
0
 def get_colors(self):
     # Colors for provided data
     colors = [
         (0, 204, 0),  # Green
         (255, 153, 153),  # Light red
         (255, 204, 153),  # Light orange
     ]
     return next_color(colors)
 def get_colors(self):
     """Return a new shuffle list of color so we change the color
     each time."""
     return next_color([
         (254, 0, 0),
         (128, 42, 42),
         (0, 0, 200),
         (220, 220, 0),
     ])
Example #3
0
 def get_colors(self):
     """Return a new shuffle list of color so we change the color
     each time."""
     colors = COLORS[:]
     shuffle(colors)
     return next_color(colors)
Example #4
0
 def get_context_data(self, **kwargs):
     data = super(ColorsView, self).get_context_data(**kwargs)
     data["colors"] = islice(next_color(), 0, 50)
     return data
Example #5
0
 def get_colors(self):
     colors = COLORS[:]
     shuffle(colors)
     return next_color(colors)
Example #6
0
 def get_colors(self):
     return next_color()
Example #7
0
 def get_colors(self):
     return next_color()
Example #8
0
 def get_colors(self):
     colors = COLORS[3:6]
     return next_color(colors)
Example #9
0
 def get_colors(self):
     """Return a new shuffle list of color so we change the color
     each time."""
     colors = COLORS[:]
     shuffle(colors)
     return next_color(colors)
Example #10
0
 def get_context_data(self, **kwargs):
     data = super(ColorsView, self).get_context_data(**kwargs)
     data['colors'] = islice(next_color(), 0, 50)
     return data
Example #11
0
 def get_colors(self):
     return next_color(COLORS[3:])