PlankItemsDockItem

PlankItemsDockItem — The base class for all dock items.

Synopsis

#define             PLANK_ITEMS_TYPE_DOCK_ITEM
void                plank_items_dock_item_handle_deleted
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_delete        (PlankItemsDockItem *self);
void                plank_items_dock_item_reset_icon_buffer
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_reset_buffers (PlankItemsDockItem *self);
PlankDrawingDockSurface * plank_items_dock_item_get_background_surface
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsDrawItemFunc draw_func,
                                                         void *draw_func_target);
PlankDrawingDockSurface * plank_items_dock_item_get_foreground_surface
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsDrawItemFunc draw_func,
                                                         void *draw_func_target);
PlankDrawingDockSurface * plank_items_dock_item_get_surface_copy
                                                        (PlankItemsDockItem *self,
                                                         gint width,
                                                         gint height,
                                                         PlankDrawingDockSurface *model);
void                plank_items_dock_item_draw_icon     (PlankItemsDockItem *self,
                                                         PlankDrawingDockSurface *surface);
void                plank_items_dock_item_clicked       (PlankItemsDockItem *self,
                                                         PlankItemsPopupButton button,
                                                         GdkModifierType mod);
PlankItemsClickAnimation plank_items_dock_item_on_clicked
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsPopupButton button,
                                                         GdkModifierType mod);
void                plank_items_dock_item_scrolled      (PlankItemsDockItem *self,
                                                         GdkScrollDirection direction,
                                                         GdkModifierType mod);
void                plank_items_dock_item_on_scrolled   (PlankItemsDockItem *self,
                                                         GdkScrollDirection direction,
                                                         GdkModifierType mod);
GeeArrayList *      plank_items_dock_item_get_menu_items
                                                        (PlankItemsDockItem *self);
gboolean            plank_items_dock_item_can_be_removed
                                                        (PlankItemsDockItem *self);
gboolean            plank_items_dock_item_can_accept_drop
                                                        (PlankItemsDockItem *self,
                                                         GeeArrayList *uris);
gboolean            plank_items_dock_item_accept_drop   (PlankItemsDockItem *self,
                                                         GeeArrayList *uris);
gchar *             plank_items_dock_item_unique_id     (PlankItemsDockItem *self);
gchar *             plank_items_dock_item_as_uri        (PlankItemsDockItem *self);
void                plank_items_dock_item_copy_values_to
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsDockItem *target);
PlankItemsDockItem * plank_items_dock_item_new          (void);
const gchar *       plank_items_dock_item_get_Icon      (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Icon      (PlankItemsDockItem *self,
                                                         const gchar *value);
GdkPixbuf *         plank_items_dock_item_get_ForcePixbuf
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_ForcePixbuf
                                                        (PlankItemsDockItem *self,
                                                         GdkPixbuf *value);
const gchar *       plank_items_dock_item_get_Text      (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Text      (PlankItemsDockItem *self,
                                                         const gchar *value);
gint64              plank_items_dock_item_get_Count     (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Count     (PlankItemsDockItem *self,
                                                         gint64 value);
gboolean            plank_items_dock_item_get_CountVisible
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_CountVisible
                                                        (PlankItemsDockItem *self,
                                                         gboolean value);
gdouble             plank_items_dock_item_get_Progress  (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Progress  (PlankItemsDockItem *self,
                                                         gdouble value);
gboolean            plank_items_dock_item_get_ProgressVisible
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_ProgressVisible
                                                        (PlankItemsDockItem *self,
                                                         gboolean value);
gint                plank_items_dock_item_get_Position  (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Position  (PlankItemsDockItem *self,
                                                         gint value);
gboolean            plank_items_dock_item_get_IsVisible (PlankItemsDockItem *self);
void                plank_items_dock_item_set_IsVisible (PlankItemsDockItem *self,
                                                         gboolean value);
PlankItemsPopupButton plank_items_dock_item_get_Button  (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Button    (PlankItemsDockItem *self,
                                                         PlankItemsPopupButton value);
PlankItemsItemState plank_items_dock_item_get_State     (PlankItemsDockItem *self);
void                plank_items_dock_item_set_State     (PlankItemsDockItem *self,
                                                         PlankItemsItemState value);
PlankItemsIndicatorState plank_items_dock_item_get_Indicator
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_Indicator (PlankItemsDockItem *self,
                                                         PlankItemsIndicatorState value);
PlankItemsClickAnimation plank_items_dock_item_get_ClickedAnimation
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_ClickedAnimation
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsClickAnimation value);
GDateTime *         plank_items_dock_item_get_AddTime   (PlankItemsDockItem *self);
void                plank_items_dock_item_set_AddTime   (PlankItemsDockItem *self,
                                                         GDateTime *value);
GDateTime *         plank_items_dock_item_get_RemoveTime
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_RemoveTime
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);
GDateTime *         plank_items_dock_item_get_LastClicked
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_LastClicked
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);
GDateTime *         plank_items_dock_item_get_LastScrolled
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_LastScrolled
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);
GDateTime *         plank_items_dock_item_get_LastUrgent
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_LastUrgent
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);
GDateTime *         plank_items_dock_item_get_LastActive
                                                        (PlankItemsDockItem *self);
void                plank_items_dock_item_set_LastActive
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);
gboolean            plank_items_dock_item_get_ValidItem (PlankItemsDockItem *self);
void                plank_items_dock_item_get_AverageIconColor
                                                        (PlankItemsDockItem *self,
                                                         PlankDrawingColor *result);
void                plank_items_dock_item_set_AverageIconColor
                                                        (PlankItemsDockItem *self,
                                                         PlankDrawingColor *value);
gchar *             plank_items_dock_item_get_DockItemFilename
                                                        (PlankItemsDockItem *self);
const gchar *       plank_items_dock_item_get_Launcher  (PlankItemsDockItem *self);
PlankItemsDockItemPreferences * plank_items_dock_item_get_Prefs
                                                        (PlankItemsDockItem *self);
GtkMenuItem *       plank_items_dock_item_create_menu_item
                                                        (const gchar *title,
                                                         const gchar *icon);
struct              PlankItemsDockItem;
struct              PlankItemsDockItemClass;
PlankDrawingDockSurface * (*PlankItemsDrawItemFunc)     (PlankItemsDockItem *item,
                                                         PlankDrawingDockSurface *source,
                                                         PlankDrawingDockSurface *target,
                                                         void *user_data);
enum                PlankItemsIndicatorState;
enum                PlankItemsItemState;
enum                PlankItemsClickAnimation;
PlankItemsPopupButton plank_items_popup_button_from_event_button
                                                        (GdkEventButton *event);
enum                PlankItemsPopupButton;

Object Hierarchy

  GObject
   +----PlankItemsDockItem
         +----PlankItemsApplicationDockItem
         +----PlankItemsFileDockItem
  GEnum
   +----PlankItemsIndicatorState
  GFlags
   +----PlankItemsItemState
  GEnum
   +----PlankItemsClickAnimation
  GFlags
   +----PlankItemsPopupButton

Properties

  "AddTime"                  GDateTime*            : Read / Write
  "AverageIconColor"         PlankDrawingColor*    : Read / Write
  "Button"                   PlankItemsPopupButton  : Read / Write
  "ClickedAnimation"         PlankItemsClickAnimation  : Read / Write
  "Count"                    gint64                : Read / Write
  "CountVisible"             gboolean              : Read / Write
  "DockItemFilename"         gchar*                : Read
  "ForcePixbuf"              GdkPixbuf*            : Read / Write
  "Icon"                     gchar*                : Read / Write
  "Indicator"                PlankItemsIndicatorState  : Read / Write
  "IsVisible"                gboolean              : Read / Write
  "LastActive"               GDateTime*            : Read / Write
  "LastClicked"              GDateTime*            : Read / Write
  "LastScrolled"             GDateTime*            : Read / Write
  "LastUrgent"               GDateTime*            : Read / Write
  "Launcher"                 gchar*                : Read
  "Position"                 gint                  : Read / Write
  "Prefs"                    PlankItemsDockItemPreferences*  : Read / Write / Construct Only
  "Progress"                 gdouble               : Read / Write
  "ProgressVisible"          gboolean              : Read / Write
  "RemoveTime"               GDateTime*            : Read / Write
  "State"                    PlankItemsItemState   : Read / Write
  "Text"                     gchar*                : Read / Write
  "ValidItem"                gboolean              : Read

Signals

  "deleted"                                        : Run Last
  "launcher-changed"                               : Run Last
  "needs-redraw"                                   : Run Last

Description

Details

PLANK_ITEMS_TYPE_DOCK_ITEM

#define PLANK_ITEMS_TYPE_DOCK_ITEM (plank_items_dock_item_get_type ())

The type for PlankItemsDockItem.


plank_items_dock_item_handle_deleted ()

void                plank_items_dock_item_handle_deleted
                                                        (PlankItemsDockItem *self);

Signal handler called when the underlying preferences file is deleted.

self :

the PlankItemsDockItem instance

plank_items_dock_item_delete ()

void                plank_items_dock_item_delete        (PlankItemsDockItem *self);

Deletes the underlying preferences file.

self :

the PlankItemsDockItem instance

plank_items_dock_item_reset_icon_buffer ()

void                plank_items_dock_item_reset_icon_buffer
                                                        (PlankItemsDockItem *self);

Resets the buffer for this item's icon and requests a redraw.

self :

the PlankItemsDockItem instance

plank_items_dock_item_reset_buffers ()

void                plank_items_dock_item_reset_buffers (PlankItemsDockItem *self);

Resets the buffers for this item's icon.

self :

the PlankItemsDockItem instance

plank_items_dock_item_get_background_surface ()

PlankDrawingDockSurface * plank_items_dock_item_get_background_surface
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsDrawItemFunc draw_func,
                                                         void *draw_func_target);

Returns the background surface for this item.

The draw_func may pass through the given previously computed surface or change it as needed. This surface will be buffered internally.

Passing null as draw_func will destroy the internal background buffer.

self :

the PlankItemsDockItem instance

draw_func :

 . function which creates/changes the background surface. [in][allow-none]

draw_func_target :

user data to pass to draw_func. [allow-none][closure]

Returns :

the background surface of this item which may not be changed

plank_items_dock_item_get_foreground_surface ()

PlankDrawingDockSurface * plank_items_dock_item_get_foreground_surface
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsDrawItemFunc draw_func,
                                                         void *draw_func_target);

Returns the foreground surface for this item.

The draw_func may pass through the given previously computed surface or change it as needed. This surface will be buffered internally.

Passing null as draw_func will destroy the internal foreground buffer.

self :

the PlankItemsDockItem instance

draw_func :

 . function which creates/changes the foreground surface. [in][allow-none]

draw_func_target :

user data to pass to draw_func. [allow-none][closure]

Returns :

the background surface of this item which may not be changed

plank_items_dock_item_get_surface_copy ()

PlankDrawingDockSurface * plank_items_dock_item_get_surface_copy
                                                        (PlankItemsDockItem *self,
                                                         gint width,
                                                         gint height,
                                                         PlankDrawingDockSurface *model);

Returns a copy of the dock surface for this item.

It will trigger an internal redraw if the requested size isn't matching the cache.

self :

the PlankItemsDockItem instance

width :

 . width of the icon surface. [in]

height :

 . height of the icon surface. [in]

model :

 . existing surface to use as basis of new surface. [in]

Returns :

the copied dock surface for this item

plank_items_dock_item_draw_icon ()

void                plank_items_dock_item_draw_icon     (PlankItemsDockItem *self,
                                                         PlankDrawingDockSurface *surface);

Draws the item's icon onto a surface.

self :

the PlankItemsDockItem instance

surface :

 . the surface to draw on. [in]

plank_items_dock_item_clicked ()

void                plank_items_dock_item_clicked       (PlankItemsDockItem *self,
                                                         PlankItemsPopupButton button,
                                                         GdkModifierType mod);

Called when an item is clicked on.

self :

the PlankItemsDockItem instance

button :

 . the button clicked. [in]

mod :

 . the modifiers. [in]

plank_items_dock_item_on_clicked ()

PlankItemsClickAnimation plank_items_dock_item_on_clicked
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsPopupButton button,
                                                         GdkModifierType mod);

Called when an item is clicked on.

self :

the PlankItemsDockItem instance

button :

 . the button clicked. [in]

mod :

 . the modifiers. [in]

plank_items_dock_item_scrolled ()

void                plank_items_dock_item_scrolled      (PlankItemsDockItem *self,
                                                         GdkScrollDirection direction,
                                                         GdkModifierType mod);

Called when an item is scrolled over.

self :

the PlankItemsDockItem instance

direction :

 . the scroll direction. [in]

mod :

 . the modifiers. [in]

plank_items_dock_item_on_scrolled ()

void                plank_items_dock_item_on_scrolled   (PlankItemsDockItem *self,
                                                         GdkScrollDirection direction,
                                                         GdkModifierType mod);

Called when an item is scrolled over.

self :

the PlankItemsDockItem instance

direction :

 . the scroll direction. [in]

mod :

 . the modifiers. [in]

plank_items_dock_item_get_menu_items ()

GeeArrayList *      plank_items_dock_item_get_menu_items
                                                        (PlankItemsDockItem *self);

Returns a list of the item's menu items.

self :

the PlankItemsDockItem instance

Returns :

the item's menu items

plank_items_dock_item_can_be_removed ()

gboolean            plank_items_dock_item_can_be_removed
                                                        (PlankItemsDockItem *self);

Returns if this item can be removed from the dock.

self :

the PlankItemsDockItem instance

Returns :

if this item can be removed from the dock

plank_items_dock_item_can_accept_drop ()

gboolean            plank_items_dock_item_can_accept_drop
                                                        (PlankItemsDockItem *self,
                                                         GeeArrayList *uris);

Returns if the item accepts a drop of the given URIs.

self :

the PlankItemsDockItem instance

uris :

 . the URIs to check. [in]

Returns :

if the item accepts a drop of the given URIs

plank_items_dock_item_accept_drop ()

gboolean            plank_items_dock_item_accept_drop   (PlankItemsDockItem *self,
                                                         GeeArrayList *uris);

Accepts a drop of the given URIs.

self :

the PlankItemsDockItem instance

uris :

 . the URIs to accept. [in]

Returns :

if the item accepted a drop of the given URIs

plank_items_dock_item_unique_id ()

gchar *             plank_items_dock_item_unique_id     (PlankItemsDockItem *self);

Returns a unique ID for this dock item.

self :

the PlankItemsDockItem instance

Returns :

a unique ID for this dock item

plank_items_dock_item_as_uri ()

gchar *             plank_items_dock_item_as_uri        (PlankItemsDockItem *self);

Returns a unique URI for this dock item.

self :

the PlankItemsDockItem instance

Returns :

a unique URI for this dock item

plank_items_dock_item_copy_values_to ()

void                plank_items_dock_item_copy_values_to
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsDockItem *target);

Copy all property value of this dockitem instance to target instance.

self :

the PlankItemsDockItem instance

target :

 . the dockitem to copy the values to. [in]

plank_items_dock_item_new ()

PlankItemsDockItem * plank_items_dock_item_new          (void);

Creates a new dock item.


plank_items_dock_item_get_Icon ()

const gchar *       plank_items_dock_item_get_Icon      (PlankItemsDockItem *self);

Get and return the current value of the "Icon" property.

The dock item's icon.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Icon" property

plank_items_dock_item_set_Icon ()

void                plank_items_dock_item_set_Icon      (PlankItemsDockItem *self,
                                                         const gchar *value);

Set the value of the "Icon" property to value.

The dock item's icon.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Icon" property

plank_items_dock_item_get_ForcePixbuf ()

GdkPixbuf *         plank_items_dock_item_get_ForcePixbuf
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "ForcePixbuf" property.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "ForcePixbuf" property

plank_items_dock_item_set_ForcePixbuf ()

void                plank_items_dock_item_set_ForcePixbuf
                                                        (PlankItemsDockItem *self,
                                                         GdkPixbuf *value);

Set the value of the "ForcePixbuf" property to value.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "ForcePixbuf" property

plank_items_dock_item_get_Text ()

const gchar *       plank_items_dock_item_get_Text      (PlankItemsDockItem *self);

Get and return the current value of the "Text" property.

The dock item's text.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Text" property

plank_items_dock_item_set_Text ()

void                plank_items_dock_item_set_Text      (PlankItemsDockItem *self,
                                                         const gchar *value);

Set the value of the "Text" property to value.

The dock item's text.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Text" property

plank_items_dock_item_get_Count ()

gint64              plank_items_dock_item_get_Count     (PlankItemsDockItem *self);

Get and return the current value of the "Count" property.

The count for the dock item.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Count" property

plank_items_dock_item_set_Count ()

void                plank_items_dock_item_set_Count     (PlankItemsDockItem *self,
                                                         gint64 value);

Set the value of the "Count" property to value.

The count for the dock item.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Count" property

plank_items_dock_item_get_CountVisible ()

gboolean            plank_items_dock_item_get_CountVisible
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "CountVisible" property.

Show the item's count or not.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "CountVisible" property

plank_items_dock_item_set_CountVisible ()

void                plank_items_dock_item_set_CountVisible
                                                        (PlankItemsDockItem *self,
                                                         gboolean value);

Set the value of the "CountVisible" property to value.

Show the item's count or not.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "CountVisible" property

plank_items_dock_item_get_Progress ()

gdouble             plank_items_dock_item_get_Progress  (PlankItemsDockItem *self);

Get and return the current value of the "Progress" property.

The progress for this dock item.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Progress" property

plank_items_dock_item_set_Progress ()

void                plank_items_dock_item_set_Progress  (PlankItemsDockItem *self,
                                                         gdouble value);

Set the value of the "Progress" property to value.

The progress for this dock item.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Progress" property

plank_items_dock_item_get_ProgressVisible ()

gboolean            plank_items_dock_item_get_ProgressVisible
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "ProgressVisible" property.

Show the item's progress or not.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "ProgressVisible" property

plank_items_dock_item_set_ProgressVisible ()

void                plank_items_dock_item_set_ProgressVisible
                                                        (PlankItemsDockItem *self,
                                                         gboolean value);

Set the value of the "ProgressVisible" property to value.

Show the item's progress or not.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "ProgressVisible" property

plank_items_dock_item_get_Position ()

gint                plank_items_dock_item_get_Position  (PlankItemsDockItem *self);

Get and return the current value of the "Position" property.

The dock item's position on the dock.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Position" property

plank_items_dock_item_set_Position ()

void                plank_items_dock_item_set_Position  (PlankItemsDockItem *self,
                                                         gint value);

Set the value of the "Position" property to value.

The dock item's position on the dock.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Position" property

plank_items_dock_item_get_IsVisible ()

gboolean            plank_items_dock_item_get_IsVisible (PlankItemsDockItem *self);

Get and return the current value of the "IsVisible" property.

Wether the item is currently visible on the dock.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "IsVisible" property

plank_items_dock_item_set_IsVisible ()

void                plank_items_dock_item_set_IsVisible (PlankItemsDockItem *self,
                                                         gboolean value);

Set the value of the "IsVisible" property to value.

Wether the item is currently visible on the dock.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "IsVisible" property

plank_items_dock_item_get_Button ()

PlankItemsPopupButton plank_items_dock_item_get_Button  (PlankItemsDockItem *self);

Get and return the current value of the "Button" property.

The buttons this item shows popup menus for.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Button" property

plank_items_dock_item_set_Button ()

void                plank_items_dock_item_set_Button    (PlankItemsDockItem *self,
                                                         PlankItemsPopupButton value);

Set the value of the "Button" property to value.

The buttons this item shows popup menus for.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Button" property

plank_items_dock_item_get_State ()

PlankItemsItemState plank_items_dock_item_get_State     (PlankItemsDockItem *self);

Get and return the current value of the "State" property.

The item's current state.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "State" property

plank_items_dock_item_set_State ()

void                plank_items_dock_item_set_State     (PlankItemsDockItem *self,
                                                         PlankItemsItemState value);

Set the value of the "State" property to value.

The item's current state.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "State" property

plank_items_dock_item_get_Indicator ()

PlankItemsIndicatorState plank_items_dock_item_get_Indicator
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "Indicator" property.

The indicator shown for the item.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Indicator" property

plank_items_dock_item_set_Indicator ()

void                plank_items_dock_item_set_Indicator (PlankItemsDockItem *self,
                                                         PlankItemsIndicatorState value);

Set the value of the "Indicator" property to value.

The indicator shown for the item.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "Indicator" property

plank_items_dock_item_get_ClickedAnimation ()

PlankItemsClickAnimation plank_items_dock_item_get_ClickedAnimation
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "ClickedAnimation" property.

The animation to show for the item's last click event.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "ClickedAnimation" property

plank_items_dock_item_set_ClickedAnimation ()

void                plank_items_dock_item_set_ClickedAnimation
                                                        (PlankItemsDockItem *self,
                                                         PlankItemsClickAnimation value);

Set the value of the "ClickedAnimation" property to value.

The animation to show for the item's last click event.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "ClickedAnimation" property

plank_items_dock_item_get_AddTime ()

GDateTime *         plank_items_dock_item_get_AddTime   (PlankItemsDockItem *self);

Get and return the current value of the "AddTime" property.

The time the item was added to the dock.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "AddTime" property

plank_items_dock_item_set_AddTime ()

void                plank_items_dock_item_set_AddTime   (PlankItemsDockItem *self,
                                                         GDateTime *value);

Set the value of the "AddTime" property to value.

The time the item was added to the dock.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "AddTime" property

plank_items_dock_item_get_RemoveTime ()

GDateTime *         plank_items_dock_item_get_RemoveTime
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "RemoveTime" property.

The time the item was removed from the dock.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "RemoveTime" property

plank_items_dock_item_set_RemoveTime ()

void                plank_items_dock_item_set_RemoveTime
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);

Set the value of the "RemoveTime" property to value.

The time the item was removed from the dock.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "RemoveTime" property

plank_items_dock_item_get_LastClicked ()

GDateTime *         plank_items_dock_item_get_LastClicked
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "LastClicked" property.

The last time the item was clicked.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "LastClicked" property

plank_items_dock_item_set_LastClicked ()

void                plank_items_dock_item_set_LastClicked
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);

Set the value of the "LastClicked" property to value.

The last time the item was clicked.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "LastClicked" property

plank_items_dock_item_get_LastScrolled ()

GDateTime *         plank_items_dock_item_get_LastScrolled
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "LastScrolled" property.

The last time the item was scrolled.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "LastScrolled" property

plank_items_dock_item_set_LastScrolled ()

void                plank_items_dock_item_set_LastScrolled
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);

Set the value of the "LastScrolled" property to value.

The last time the item was scrolled.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "LastScrolled" property

plank_items_dock_item_get_LastUrgent ()

GDateTime *         plank_items_dock_item_get_LastUrgent
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "LastUrgent" property.

The last time the item changed its urgent status.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "LastUrgent" property

plank_items_dock_item_set_LastUrgent ()

void                plank_items_dock_item_set_LastUrgent
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);

Set the value of the "LastUrgent" property to value.

The last time the item changed its urgent status.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "LastUrgent" property

plank_items_dock_item_get_LastActive ()

GDateTime *         plank_items_dock_item_get_LastActive
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "LastActive" property.

The last time the item changed its active status.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "LastActive" property

plank_items_dock_item_set_LastActive ()

void                plank_items_dock_item_set_LastActive
                                                        (PlankItemsDockItem *self,
                                                         GDateTime *value);

Set the value of the "LastActive" property to value.

The last time the item changed its active status.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "LastActive" property

plank_items_dock_item_get_ValidItem ()

gboolean            plank_items_dock_item_get_ValidItem (PlankItemsDockItem *self);

Get and return the current value of the "ValidItem" property.

Whether or not this item is valid for the .dockitem given.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "ValidItem" property

plank_items_dock_item_get_AverageIconColor ()

void                plank_items_dock_item_get_AverageIconColor
                                                        (PlankItemsDockItem *self,
                                                         PlankDrawingColor *result);

Get and return the current value of the "AverageIconColor" property.

The average color of this item's icon.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "AverageIconColor" property

plank_items_dock_item_set_AverageIconColor ()

void                plank_items_dock_item_set_AverageIconColor
                                                        (PlankItemsDockItem *self,
                                                         PlankDrawingColor *value);

Set the value of the "AverageIconColor" property to value.

The average color of this item's icon.

self :

the PlankItemsDockItem instance to modify

value :

the new value of the "AverageIconColor" property

plank_items_dock_item_get_DockItemFilename ()

gchar *             plank_items_dock_item_get_DockItemFilename
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "DockItemFilename" property.

The filename of the preferences backing file.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "DockItemFilename" property

plank_items_dock_item_get_Launcher ()

const gchar *       plank_items_dock_item_get_Launcher  (PlankItemsDockItem *self);

Get and return the current value of the "Launcher" property.

The launcher associated with this item.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Launcher" property

plank_items_dock_item_get_Prefs ()

PlankItemsDockItemPreferences * plank_items_dock_item_get_Prefs
                                                        (PlankItemsDockItem *self);

Get and return the current value of the "Prefs" property.

The underlying preferences for this item.

self :

the PlankItemsDockItem instance to query

Returns :

the value of the "Prefs" property

plank_items_dock_item_create_menu_item ()

GtkMenuItem *       plank_items_dock_item_create_menu_item
                                                        (const gchar *title,
                                                         const gchar *icon);

Creates a new menu item.

title :

 . the title of the menu item. [in]

icon :

 . the icon of the menu item. [in]

Returns :

the new menu item

struct PlankItemsDockItem

struct PlankItemsDockItem;

The base class for all dock items.


struct PlankItemsDockItemClass

struct PlankItemsDockItemClass {
	GObjectClass parent_class;
	void (*draw_icon) (PlankItemsDockItem* self, PlankDrawingDockSurface* surface);
	PlankItemsClickAnimation (*on_clicked) (PlankItemsDockItem* self, PlankItemsPopupButton button, GdkModifierType mod);
	void (*on_scrolled) (PlankItemsDockItem* self, GdkScrollDirection direction, GdkModifierType mod);
	GeeArrayList* (*get_menu_items) (PlankItemsDockItem* self);
	gboolean (*can_be_removed) (PlankItemsDockItem* self);
	gboolean (*can_accept_drop) (PlankItemsDockItem* self, GeeArrayList* uris);
	gboolean (*accept_drop) (PlankItemsDockItem* self, GeeArrayList* uris);
	gchar* (*unique_id) (PlankItemsDockItem* self);
	gboolean (*get_ValidItem) (PlankItemsDockItem* self);
};

The class structure for PLANK_ITEMS_TYPE_DOCK_ITEM. All the fields in this structure are private and should never be accessed directly.

GObjectClass parent_class;

the parent class structure

draw_icon ()

virtual method used internally

on_clicked ()

virtual method used internally

on_scrolled ()

virtual method used internally

get_menu_items ()

virtual method called by plank_items_dock_item_get_menu_items()

can_be_removed ()

virtual method called by plank_items_dock_item_can_be_removed()

can_accept_drop ()

virtual method called by plank_items_dock_item_can_accept_drop()

accept_drop ()

virtual method called by plank_items_dock_item_accept_drop()

unique_id ()

virtual method called by plank_items_dock_item_unique_id()

get_ValidItem ()

getter method for the abstract property "ValidItem"

PlankItemsDrawItemFunc ()

PlankDrawingDockSurface * (*PlankItemsDrawItemFunc)     (PlankItemsDockItem *item,
                                                         PlankDrawingDockSurface *source,
                                                         PlankDrawingDockSurface *target,
                                                         void *user_data);

Draws a modified surface onto another newly created or given surface

item :

 . the dock-item. [in]

source :

 . original surface which may not be changed. [in]

target :

 . the previously modified surface. [in][allow-none]

user_data :

data to pass to the delegate function. [closure]

Returns :

the modified surface or passed through target

enum PlankItemsIndicatorState

typedef enum {
	PLANK_ITEMS_INDICATOR_STATE_NONE,
	PLANK_ITEMS_INDICATOR_STATE_SINGLE,
	PLANK_ITEMS_INDICATOR_STATE_SINGLE_PLUS
} PlankItemsIndicatorState;

What item indicator to show.

PLANK_ITEMS_INDICATOR_STATE_NONE

None - no windows for this item.

PLANK_ITEMS_INDICATOR_STATE_SINGLE

Show a single indicator - there is 1 window for this item.

PLANK_ITEMS_INDICATOR_STATE_SINGLE_PLUS

Show multiple indicators - there are more than 1 window for this item.

enum PlankItemsItemState

typedef enum {
	PLANK_ITEMS_ITEM_STATE_NORMAL = 1 << 0,
	PLANK_ITEMS_ITEM_STATE_ACTIVE = 1 << 1,
	PLANK_ITEMS_ITEM_STATE_URGENT = 1 << 2
} PlankItemsItemState;

The current activity state of an item. The item has several states to track and can be in any combination of them.

PLANK_ITEMS_ITEM_STATE_NORMAL

The item is in a normal state.

PLANK_ITEMS_ITEM_STATE_ACTIVE

The item is currently active (a window in the group is focused).

PLANK_ITEMS_ITEM_STATE_URGENT

The item is currently urgent (a window in the group has the urgent flag).

enum PlankItemsClickAnimation

typedef enum {
	PLANK_ITEMS_CLICK_ANIMATION_NONE,
	PLANK_ITEMS_CLICK_ANIMATION_BOUNCE,
	PLANK_ITEMS_CLICK_ANIMATION_DARKEN,
	PLANK_ITEMS_CLICK_ANIMATION_LIGHTEN
} PlankItemsClickAnimation;

What type of animation to perform when an item is clicked.

PLANK_ITEMS_CLICK_ANIMATION_NONE

No animation.

PLANK_ITEMS_CLICK_ANIMATION_BOUNCE

Bounce the icon.

PLANK_ITEMS_CLICK_ANIMATION_DARKEN

Darken the icon, then restore it.

PLANK_ITEMS_CLICK_ANIMATION_LIGHTEN

Brighten the icon, then restore it.

plank_items_popup_button_from_event_button ()

PlankItemsPopupButton plank_items_popup_button_from_event_button
                                                        (GdkEventButton *event);

Convenience method to map GdkEventButton to this enum.

event :

 . the event to map. [in]

Returns :

the PopupButton representation of the event

enum PlankItemsPopupButton

typedef enum {
	PLANK_ITEMS_POPUP_BUTTON_NONE = 1 << 0,
	PLANK_ITEMS_POPUP_BUTTON_LEFT = 1 << 1,
	PLANK_ITEMS_POPUP_BUTTON_MIDDLE = 1 << 2,
	PLANK_ITEMS_POPUP_BUTTON_RIGHT = 1 << 3
} PlankItemsPopupButton;

What mouse button pops up the context menu on an item. Can be multiple buttons.

PLANK_ITEMS_POPUP_BUTTON_NONE

No button pops up the context.

PLANK_ITEMS_POPUP_BUTTON_LEFT

Left button pops up the context.

PLANK_ITEMS_POPUP_BUTTON_MIDDLE

Middle button pops up the context.

PLANK_ITEMS_POPUP_BUTTON_RIGHT

Right button pops up the context.

Property Details

The "AddTime" property

  "AddTime"                  GDateTime*            : Read / Write

The time the item was added to the dock.


The "AverageIconColor" property

  "AverageIconColor"         PlankDrawingColor*    : Read / Write

The average color of this item's icon.


The "Button" property

  "Button"                   PlankItemsPopupButton  : Read / Write

The buttons this item shows popup menus for.

Default value: PLANK_ITEMS_POPUP_BUTTON_RIGHT


The "ClickedAnimation" property

  "ClickedAnimation"         PlankItemsClickAnimation  : Read / Write

The animation to show for the item's last click event.

Default value: PLANK_ITEMS_CLICK_ANIMATION_NONE


The "Count" property

  "Count"                    gint64                : Read / Write

The count for the dock item.

Default value: 0


The "CountVisible" property

  "CountVisible"             gboolean              : Read / Write

Show the item's count or not.

Default value: FALSE


The "DockItemFilename" property

  "DockItemFilename"         gchar*                : Read

The filename of the preferences backing file.

Default value: NULL


The "ForcePixbuf" property

  "ForcePixbuf"              GdkPixbuf*            : Read / Write

ForcePixbuf.


The "Icon" property

  "Icon"                     gchar*                : Read / Write

The dock item's icon.

Default value: NULL


The "Indicator" property

  "Indicator"                PlankItemsIndicatorState  : Read / Write

The indicator shown for the item.

Default value: PLANK_ITEMS_INDICATOR_STATE_NONE


The "IsVisible" property

  "IsVisible"                gboolean              : Read / Write

Wether the item is currently visible on the dock.

Default value: TRUE


The "LastActive" property

  "LastActive"               GDateTime*            : Read / Write

The last time the item changed its active status.


The "LastClicked" property

  "LastClicked"              GDateTime*            : Read / Write

The last time the item was clicked.


The "LastScrolled" property

  "LastScrolled"             GDateTime*            : Read / Write

The last time the item was scrolled.


The "LastUrgent" property

  "LastUrgent"               GDateTime*            : Read / Write

The last time the item changed its urgent status.


The "Launcher" property

  "Launcher"                 gchar*                : Read

The launcher associated with this item.

Default value: NULL


The "Position" property

  "Position"                 gint                  : Read / Write

The dock item's position on the dock.

Default value: -1


The "Prefs" property

  "Prefs"                    PlankItemsDockItemPreferences*  : Read / Write / Construct Only

The underlying preferences for this item.


The "Progress" property

  "Progress"                 gdouble               : Read / Write

The progress for this dock item.

Default value: 0


The "ProgressVisible" property

  "ProgressVisible"          gboolean              : Read / Write

Show the item's progress or not.

Default value: FALSE


The "RemoveTime" property

  "RemoveTime"               GDateTime*            : Read / Write

The time the item was removed from the dock.


The "State" property

  "State"                    PlankItemsItemState   : Read / Write

The item's current state.

Default value: PLANK_ITEMS_ITEM_STATE_NORMAL


The "Text" property

  "Text"                     gchar*                : Read / Write

The dock item's text.

Default value: NULL


The "ValidItem" property

  "ValidItem"                gboolean              : Read

Whether or not this item is valid for the .dockitem given.

Default value: FALSE

Signal Details

The "deleted" signal

void                user_function                      (PlankItemsDockItem *dock_item,
                                                        gpointer            user_data)      : Run Last

Signal fired when the .dockitem for this item was deleted.

dock_item :

the PlankItemsDockItem instance that received the signal

user_data :

user data set when the signal handler was connected.

The "launcher-changed" signal

void                user_function                      (PlankItemsDockItem *dock_item,
                                                        gpointer            user_data)      : Run Last

Signal fired when the launcher associated with the dock item changed.

dock_item :

the PlankItemsDockItem instance that received the signal

user_data :

user data set when the signal handler was connected.

The "needs-redraw" signal

void                user_function                      (PlankItemsDockItem *dock_item,
                                                        gpointer            user_data)      : Run Last

Signal fired when the dock item needs redrawn.

dock_item :

the PlankItemsDockItem instance that received the signal

user_data :

user data set when the signal handler was connected.