![]() | ![]() | ![]() | streamtuner Developers Manual | ![]() |
---|
STHandlerField — a structure for defining a stream field.
struct STHandlerField; enum STHandlerFieldFlags; STHandlerField* st_handler_field_new (int id, const char *label, GType type, STHandlerFieldFlags flags); const char* st_handler_field_get_label (STHandlerField *field); GType st_handler_field_get_type (STHandlerField *field); STHandlerFieldFlags st_handler_field_get_flags (STHandlerField *field); void st_handler_field_set_description (STHandlerField *field, const char *description); const char* st_handler_field_get_description (STHandlerField *field);
struct STHandlerField { int id; STHandlerFieldPrivate *priv; };
int id | the ID passed to st_handler_field_new() (read-only) |
STHandlerFieldPrivate *priv |
typedef enum { ST_HANDLER_FIELD_VISIBLE = 1 << 0, ST_HANDLER_FIELD_EDITABLE = 1 << 1, ST_HANDLER_FIELD_VOLATILE = 1 << 2, ST_HANDLER_FIELD_NO_DEDICATED_COLUMN = 1 << 3, ST_HANDLER_FIELD_START_HIDDEN = 1 << 4 } STHandlerFieldFlags;
ST_HANDLER_FIELD_VISIBLE | specifies that the field should be visible in the user interface. |
ST_HANDLER_FIELD_EDITABLE | specifies that the user may edit the field value. |
ST_HANDLER_FIELD_VOLATILE | specifies that the field value should not be saved to permanent storage. |
ST_HANDLER_FIELD_NO_DEDICATED_COLUMN | specifies that the field should not have a dedicated column in the stream list. |
ST_HANDLER_FIELD_START_HIDDEN | specifies that the field should be hidden by default. |
STHandlerField* st_handler_field_new (int id, const char *label, GType type, STHandlerFieldFlags flags);
Creates a new STHandlerField.
id : | the numeric ID of the field. Handler fields must be numbered from 0 to n_fields - 1. |
label : | the field label. |
type : | the field type. Must be G_TYPE_BOOLEAN, G_TYPE_INT, G_TYPE_UINT, G_TYPE_DOUBLE, G_TYPE_STRING, or, if the ST_HANDLER_FIELD_EDITABLE flag is not set, GDK_TYPE_PIXBUF or G_TYPE_VALUE_ARRAY. |
flags : | the field flags. |
Returns : | the newly created STHandlerField. |
const char* st_handler_field_get_label (STHandlerField *field);
Gets the label of field.
field : | a field. |
Returns : | the label of field. |
GType st_handler_field_get_type (STHandlerField *field);
Gets the value type of field.
field : | a field. |
Returns : | the type of value held by field. |
STHandlerFieldFlags st_handler_field_get_flags (STHandlerField *field);
Gets the flags of field.
field : | a field. |
Returns : | the flags of field. |
void st_handler_field_set_description (STHandlerField *field, const char *description);
Sets the description of field.
field : | a field. |
description : | the field description, or NULL to unset. |
const char* st_handler_field_get_description (STHandlerField *field);
Gets the description of field.
field : | a field. |
Returns : | the description of field, or NULL if not set. |
<< STHandler | st-handlers >> |