![]() |
![]() |
![]() |
plank Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Properties |
PlankDrawingDockSurfacePlankDrawingDockSurface — A dock surface is a wrapper class for a cairo_surface_t. It encapsulates a surface/context and provides utility methods. |
#define PLANK_DRAWING_TYPE_DOCK_SURFACE void plank_drawing_dock_surface_clear (PlankDrawingDockSurface *self
); PlankDrawingDockSurface * plank_drawing_dock_surface_copy (PlankDrawingDockSurface *self
); GdkPixbuf * plank_drawing_dock_surface_to_pixbuf (PlankDrawingDockSurface *self
); PlankDrawingDockSurface * plank_drawing_dock_surface_create_mask (PlankDrawingDockSurface *self
,gdouble threshold
,GdkRectangle *extent
); void plank_drawing_dock_surface_average_color (PlankDrawingDockSurface *self
,PlankDrawingColor *result
); void plank_drawing_dock_surface_fast_blur (PlankDrawingDockSurface *self
,gint radius
,gint process_count
); void plank_drawing_dock_surface_exponential_blur (PlankDrawingDockSurface *self
,gint radius
); void plank_drawing_dock_surface_gaussian_blur (PlankDrawingDockSurface *self
,gint radius
); PlankDrawingDockSurface * plank_drawing_dock_surface_new (gint width
,gint height
); PlankDrawingDockSurface * plank_drawing_dock_surface_new_with_surface (gint width
,gint height
,cairo_surface_t *model
); PlankDrawingDockSurface * plank_drawing_dock_surface_new_with_dock_surface (gint width
,gint height
,PlankDrawingDockSurface *model
); PlankDrawingDockSurface * plank_drawing_dock_surface_new_with_internal (cairo_surface_t *image
); cairo_surface_t * plank_drawing_dock_surface_get_Internal (PlankDrawingDockSurface *self
); gint plank_drawing_dock_surface_get_Width (PlankDrawingDockSurface *self
); gint plank_drawing_dock_surface_get_Height (PlankDrawingDockSurface *self
); cairo_t * plank_drawing_dock_surface_get_Context (PlankDrawingDockSurface *self
); struct PlankDrawingDockSurface; struct PlankDrawingDockSurfaceClass;
"Context" gpointer : Read / Write / Construct Only "Height" gint : Read / Write / Construct Only "Internal" gpointer : Read / Write / Construct Only "Width" gint : Read / Write / Construct Only
#define PLANK_DRAWING_TYPE_DOCK_SURFACE (plank_drawing_dock_surface_get_type ())
The type for PlankDrawingDockSurface.
void plank_drawing_dock_surface_clear (PlankDrawingDockSurface *self
);
Clears the entire surface.
|
the PlankDrawingDockSurface instance |
PlankDrawingDockSurface * plank_drawing_dock_surface_copy
(PlankDrawingDockSurface *self
);
Create a copy of the surface
|
the PlankDrawingDockSurface instance |
Returns : |
copy of this surface |
GdkPixbuf * plank_drawing_dock_surface_to_pixbuf
(PlankDrawingDockSurface *self
);
Saves the current dock surface to a GdkPixbuf.
|
the PlankDrawingDockSurface instance |
Returns : |
the GdkPixbuf |
PlankDrawingDockSurface * plank_drawing_dock_surface_create_mask (PlankDrawingDockSurface *self
,gdouble threshold
,GdkRectangle *extent
);
Computes the mask of the surface.
|
the PlankDrawingDockSurface instance |
|
. value defining the minimum opacity [0.0 .. 1.0]. [in] |
|
. bounding box of the found mask. [out] |
Returns : |
a new surface containing the mask |
void plank_drawing_dock_surface_average_color (PlankDrawingDockSurface *self
,PlankDrawingColor *result
);
Computes and returns the average color of the surface.
|
the PlankDrawingDockSurface instance |
Returns : |
the average color of the surface |
void plank_drawing_dock_surface_fast_blur (PlankDrawingDockSurface *self
,gint radius
,gint process_count
);
Performs a fast blur on the surface.
|
the PlankDrawingDockSurface instance |
|
. the radius of the blur. [in] |
|
. how many iterations to blur. [in] |
void plank_drawing_dock_surface_exponential_blur (PlankDrawingDockSurface *self
,gint radius
);
Performs an exponential blur on the surface.
|
the PlankDrawingDockSurface instance |
|
. the radius of the blur. [in] |
void plank_drawing_dock_surface_gaussian_blur (PlankDrawingDockSurface *self
,gint radius
);
Performs a gaussian blur on the surface. Note: This method is wickedly slow
|
the PlankDrawingDockSurface instance |
|
. the radius of the blur. [in] |
PlankDrawingDockSurface * plank_drawing_dock_surface_new (gint width
,gint height
);
Creates a new dock surface.
|
. width of the new surface. [in] |
|
. height of the new surface. [in] |
PlankDrawingDockSurface * plank_drawing_dock_surface_new_with_surface (gint width
,gint height
,cairo_surface_t *model
);
Creates a new dock surface compatible with an existing cairo_surface_t.
|
. width of the new surface. [in] |
|
. height of the new surface. [in] |
|
. existing cairo_surface_t to be similar to. [in] |
PlankDrawingDockSurface * plank_drawing_dock_surface_new_with_dock_surface (gint width
,gint height
,PlankDrawingDockSurface *model
);
Creates a new dock surface compatible with an existing PlankDrawingDockSurface.
|
. width of the new surface. [in] |
|
. height of the new surface. [in] |
|
. existing PlankDrawingDockSurface to be similar to. [in] |
PlankDrawingDockSurface * plank_drawing_dock_surface_new_with_internal
(cairo_surface_t *image
);
Creates a new dock surface with the given cairo_surface_t as Internal.
|
. existing cairo_surface_t as Internal. [in] |
cairo_surface_t * plank_drawing_dock_surface_get_Internal
(PlankDrawingDockSurface *self
);
Get and return the current value of the "Internal" property.
The internal cairo_surface_t backing the dock surface.
|
the PlankDrawingDockSurface instance to query |
Returns : |
the value of the "Internal" property |
gint plank_drawing_dock_surface_get_Width
(PlankDrawingDockSurface *self
);
Get and return the current value of the "Width" property.
The width of the surface.
|
the PlankDrawingDockSurface instance to query |
Returns : |
the value of the "Width" property |
gint plank_drawing_dock_surface_get_Height
(PlankDrawingDockSurface *self
);
Get and return the current value of the "Height" property.
The height of the surface.
|
the PlankDrawingDockSurface instance to query |
Returns : |
the value of the "Height" property |
cairo_t * plank_drawing_dock_surface_get_Context
(PlankDrawingDockSurface *self
);
Get and return the current value of the "Context" property.
A cairo_t for the dock surface.
|
the PlankDrawingDockSurface instance to query |
Returns : |
the value of the "Context" property |
struct PlankDrawingDockSurface;
A dock surface is a wrapper class for a cairo_surface_t. It encapsulates a surface/context and provides utility methods.
struct PlankDrawingDockSurfaceClass { GObjectClass parent_class; };
The class structure for PLANK_DRAWING_TYPE_DOCK_SURFACE
. All the fields in this structure are private and should never be accessed directly.
GObjectClass |
the parent class structure |
"Context"
property"Context" gpointer : Read / Write / Construct Only
A cairo_t for the dock surface.
"Height"
property"Height" gint : Read / Write / Construct Only
The height of the surface.
Default value: 0
"Internal"
property"Internal" gpointer : Read / Write / Construct Only
The internal cairo_surface_t backing the dock surface.
"Width"
property"Width" gint : Read / Write / Construct Only
The width of the surface.
Default value: 0