AsScreenshot

AsScreenshot — Object representing a single screenshot

Synopsis

struct              AsScreenshot;
struct              AsScreenshotClass;
enum                AsScreenshotKind;
AsScreenshot *      as_screenshot_new                   (void);
AsScreenshotKind    as_screenshot_kind_from_string      (const gchar *kind);
const gchar *       as_screenshot_kind_to_string        (AsScreenshotKind kind);
gboolean            as_screenshot_is_valid              (AsScreenshot *sshot);
AsScreenshotKind    as_screenshot_get_kind              (AsScreenshot *screenshot);
const gchar *       as_screenshot_get_caption           (AsScreenshot *screenshot);
GPtrArray *         as_screenshot_get_images            (AsScreenshot *screenshot);
void                as_screenshot_set_kind              (AsScreenshot *screenshot,
                                                         AsScreenshotKind kind);
void                as_screenshot_set_caption           (AsScreenshot *screenshot,
                                                         const gchar *caption);
void                as_screenshot_add_image             (AsScreenshot *screenshot,
                                                         AsImage *image);

Object Hierarchy

  GObject
   +----AsScreenshot

Description

Screenshots have a localized caption and also contain a number of images of different resolution.

See also: AsImage

Details

struct AsScreenshot

struct AsScreenshot;


struct AsScreenshotClass

struct AsScreenshotClass {
	GObjectClass		parent_class;
};


enum AsScreenshotKind

typedef enum {
	AS_SCREENSHOT_KIND_UNKNOWN,
	AS_SCREENSHOT_KIND_NORMAL,
	AS_SCREENSHOT_KIND_DEFAULT,
} AsScreenshotKind;

The screenshot type.

AS_SCREENSHOT_KIND_UNKNOWN

Type invalid or not known

AS_SCREENSHOT_KIND_NORMAL

Optional screenshot

AS_SCREENSHOT_KIND_DEFAULT

Screenshot to show by default

as_screenshot_new ()

AsScreenshot *      as_screenshot_new                   (void);

Creates a new AsScreenshot.

Returns :

a AsScreenshot. [transfer full]

as_screenshot_kind_from_string ()

AsScreenshotKind    as_screenshot_kind_from_string      (const gchar *kind);

Converts the text representation to an enumerated value.

kind :

the string.

Returns :

a AsScreenshotKind, or AS_SCREENSHOT_KIND_UNKNOWN if not known. [transfer full]

as_screenshot_kind_to_string ()

const gchar *       as_screenshot_kind_to_string        (AsScreenshotKind kind);

Converts the enumerated value to an text representation.

kind :

the AsScreenshotKind.

Returns :

string version of kind

as_screenshot_is_valid ()

gboolean            as_screenshot_is_valid              (AsScreenshot *sshot);

Performs a quick validation on this screenshot

Returns :

TRUE if the screenshot is a complete AsScreenshot

as_screenshot_get_kind ()

AsScreenshotKind    as_screenshot_get_kind              (AsScreenshot *screenshot);

Gets the screenshot kind.

screenshot :

a AsScreenshot instance.

Returns :

a AsScreenshotKind

as_screenshot_get_caption ()

const gchar *       as_screenshot_get_caption           (AsScreenshot *screenshot);

Gets the image caption

screenshot :

a AsScreenshot instance.

Returns :

the caption

as_screenshot_get_images ()

GPtrArray *         as_screenshot_get_images            (AsScreenshot *screenshot);

Gets the image sizes included in the screenshot.

screenshot :

a AsScreenshot instance.

Returns :

an array. [element-type AsImage][transfer none]

as_screenshot_set_kind ()

void                as_screenshot_set_kind              (AsScreenshot *screenshot,
                                                         AsScreenshotKind kind);

Sets the screenshot kind.

screenshot :

a AsScreenshot instance.

kind :

the AsScreenshotKind.

as_screenshot_set_caption ()

void                as_screenshot_set_caption           (AsScreenshot *screenshot,
                                                         const gchar *caption);

Sets a caption on the screenshot

screenshot :

a AsScreenshot instance.

caption :

the caption text.

as_screenshot_add_image ()

void                as_screenshot_add_image             (AsScreenshot *screenshot,
                                                         AsImage *image);

Adds an image to the screenshot.

screenshot :

a AsScreenshot instance.

image :

a AsImage instance.