75
caca_set_dither_palette(self.dither, rp, bp, gp, ap)
75
cucul_set_dither_palette(self.dither, rp, bp, gp, ap)
79
79
property brightness:
81
return caca_get_dither_brightness(self.dither)
81
return cucul_get_dither_brightness(self.dither)
82
82
def __set__(self, brightness):
83
if caca_set_dither_brightness(self.dither, brightness) == -1:
83
if cucul_set_dither_brightness(self.dither, brightness) == -1:
84
84
raise ValueError('invalid value: %r' % (brightness,))
88
return caca_get_dither_gamma(self.dither)
88
return cucul_get_dither_gamma(self.dither)
89
89
def __set__(self, gamma):
90
if caca_set_dither_gamma(self.dither, gamma) == -1:
90
if cucul_set_dither_gamma(self.dither, gamma) == -1:
91
91
raise ValueError('invalid value: %r' % (gamma,))
95
return caca_get_dither_contrast(self.dither)
95
return cucul_get_dither_contrast(self.dither)
96
96
def __set__(self, contrast):
97
if caca_set_dither_contrast(self.dither, contrast) == -1:
97
if cucul_set_dither_contrast(self.dither, contrast) == -1:
98
98
raise ValueError('invalid value: %r' % (contrast,))
100
100
property antialias:
101
101
def __get__(self):
102
return caca_get_dither_antialias(self.dither)
102
return cucul_get_dither_antialias(self.dither)
103
103
def __set__(self, antialias):
104
if caca_set_dither_antialias(self.dither, antialias) == -1:
104
if cucul_set_dither_antialias(self.dither, antialias) == -1:
105
105
raise ValueError('invalid value: %r' % (antialias,))
108
108
def __get__(self):
109
return caca_get_dither_color(self.dither)
109
return cucul_get_dither_color(self.dither)
110
110
def __set__(self, color):
111
if caca_set_dither_color(self.dither, color) == -1:
111
if cucul_set_dither_color(self.dither, color) == -1:
112
112
raise ValueError('invalid value: %r' % (color,))
114
114
property charset:
115
115
def __get__(self):
116
return caca_get_dither_charset(self.dither)
116
return cucul_get_dither_charset(self.dither)
117
117
def __set__(self, charset):
118
if caca_set_dither_charset(self.dither, charset) == -1:
118
if cucul_set_dither_charset(self.dither, charset) == -1:
119
119
raise ValueError('invalid value: %r' % (charset,))
121
121
property algorithm:
122
122
def __get__(self):
123
return caca_get_dither_algorithm(self.dither)
123
return cucul_get_dither_algorithm(self.dither)
124
124
def __set__(self, algorithm):
125
if caca_set_dither_algorithm(self.dither, algorithm) == -1:
125
if cucul_set_dither_algorithm(self.dither, algorithm) == -1:
126
126
raise ValueError('invalid value: %r' % (algorithm,))
128
128
def get_antialias_list(self):
129
return deinterlace(<char **>caca_get_dither_antialias_list(self.dither))
129
return deinterlace(<char **>cucul_get_dither_antialias_list(self.dither))
131
131
def get_charset_list(self):
132
return deinterlace(<char **>caca_get_dither_charset_list(self.dither))
132
return deinterlace(<char **>cucul_get_dither_charset_list(self.dither))
134
134
def get_algorithm_list(self):
135
return deinterlace(<char **>caca_get_dither_algorithm_list(self.dither))
135
return deinterlace(<char **>cucul_get_dither_algorithm_list(self.dither))
137
137
def get_color_list(self):
138
return deinterlace(<char **>caca_get_dither_color_list(self.dither))
138
return deinterlace(<char **>cucul_get_dither_color_list(self.dither))