diff --git a/PIL/ImagePalette.py b/PIL/ImagePalette.py index 5aabaa138..f80259f04 100644 --- a/PIL/ImagePalette.py +++ b/PIL/ImagePalette.py @@ -22,7 +22,19 @@ from PIL import ImageColor class ImagePalette(object): - "Color palette for palette mapped images" + """ + Color palette for palette mapped images + + :param mode: The mode to use for the Palette. See: + :ref:`concept-modes`. Defaults to "RGB" + :param palette: An optional palette. If given, it must be a bytearray, + an array or a list of ints between 0-255 and of length ``size`` + times the number of colors in ``mode``. The list must be aligned + by channel (All R values must be contiguous in the list before G + and B values.) Defaults to 0 through 255 per channel. + :param size: An optional palette size. If given, it cannot be equal to + or greater than 256. Defaults to 0. + """ def __init__(self, mode="RGB", palette=None, size=0): self.mode = mode