Gimp.Image.select_color
@accepts(Gimp.Image, Gimp.ChannelOps, Gimp.Drawable, Gimp.RGB)
@returns(bool)
def select_color(self, operation, drawable, color):
# Python wrapper for gimp_image_select_color()
Create a selection by selecting all pixels (in the specified drawable) with the same (or similar) color to that specified.
This tool creates a selection over the specified image. A by-color selection is determined by the supplied color under the constraints of the current context settings. Essentially, all pixels (in the drawable) that have color sufficiently close to the specified color (as determined by the threshold and criterion context values) are included in the selection. To select transparent regions, the color specified must also have minimum alpha.
This procedure is affected by the following context setters: Gimp.context_set_antialias, Gimp.context_set_feather, Gimp.context_set_feather_radius, Gimp.context_set_sample_merged, Gimp.context_set_sample_criterion, Gimp.context_set_sample_threshold, Gimp.context_set_sample_transparent.
In the case of a merged sampling, the supplied drawable is ignored.
Since 2.8
- self
The affected image.
- operation
The selection operation.
- drawable
The affected drawable.
- color
The color to select.
- Returns