Gimp.Pattern¶
- Subclasses:
None
Methods¶
- Inherited:
Gimp.Resource (20), GObject.Object (37), Gimp.ConfigInterface (14)
- Structs:
class |
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
- Inherited:
Signals¶
- Inherited:
Fields¶
- Inherited:
Class Details¶
- class Gimp.Pattern(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
Installable object used by fill and clone tools.
- classmethod get_by_name(name)¶
- Parameters:
name (
str
) – The name of the pattern.- Returns:
The pattern.
- Return type:
Gimp.Pattern
orNone
Returns the pattern with the given name.
Returns an existing pattern having the given name. Returns
None
when no pattern exists of that name.New in version 3.0.
- get_buffer(max_width, max_height, format)¶
- Parameters:
max_width (
int
) – a maximum width for the returned buffer.max_height (
int
) – a maximum height for the returned buffer.format (
Babl.Object
) – an optionalBabl.Object
format.
- Returns:
a [class`Gegl`.Buffer].
- Return type:
Gets pixel data of the pattern within the bounding box specified by max_width and max_height. The data will be scaled down so that it fits within this size without changing its ratio. If the pattern is smaller than this size to begin with, it will not be scaled up.
If max_width or max_height are
None
, the buffer is returned in the pattern’s native size.Make sure you called [func`Gegl`.init] before calling any function using
GEGL
.