BamfView

BamfView — The base class for all views

Functions

Properties

gboolean active Read
char * path Read
gboolean running Read
gboolean starting Read
gboolean urgent Read
gboolean user-visible Read

Signals

void active-changed Run First
void child-added Run First
void child-moved Run First
void child-removed Run First
void closed Run Last
void icon-changed  
void name-changed  
void running-changed Run First
void starting-changed Run First
void urgent-changed Run First
void user-visible-changed Run First

Types and Values

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── BamfView
            ├── BamfApplication
            ├── BamfTab
            ╰── BamfWindow

Description

BamfView is the base class that all views need to derive from.

Functions

bamf_view_get_children ()

GList *
bamf_view_get_children (BamfView *view);

Note: Makes sever dbus calls the first time this is called on a view. Dbus messaging is reduced afterwards.

Parameters

view

a BamfView

 

Returns

Returns a list of BamfView which must be freed after usage. Elements of the list are owned by bamf and should not be unreffed.

[element-type Bamf.View][transfer container]


bamf_view_peek_children ()

GList *
bamf_view_peek_children (BamfView *view);

Note: Makes sever dbus calls the first time this is called on a view. Dbus messaging is reduced afterwards.

Parameters

view

a BamfView

 

Returns

Returns a list of BamfView which is owned by the BamfView and should not freed or modified after usage.

[element-type Bamf.View][transfer none]

Since: 0.5.2


bamf_view_has_child ()

gboolean
bamf_view_has_child (BamfView *view,
                     BamfView *child);

Parameters

view

a BamfView

 

Returns

TRUE whether the BamfView view has the specified child .


bamf_view_is_closed ()

gboolean
bamf_view_is_closed (BamfView *view);

Determines if the view is closed or not.

Parameters

view

a BamfView

 

bamf_view_is_active ()

gboolean
bamf_view_is_active (BamfView *view);

Determines if the view is currently active and focused by the user. Useful for an active window indicator.

Parameters

view

a BamfView

 

bamf_view_is_starting ()

gboolean
bamf_view_is_starting (BamfView *view);

Determines if the view is currently starting. Useful for the startup animation.

Parameters

view

a BamfView

 

bamf_view_is_running ()

gboolean
bamf_view_is_running (BamfView *view);

Determines if the view is currently running. Useful for a running window indicator.

Parameters

view

a BamfView

 

bamf_view_is_urgent ()

gboolean
bamf_view_is_urgent (BamfView *view);

Determines if the view is currently requiring attention. Useful for a running window indicator.

Parameters

view

a BamfView

 

bamf_view_is_user_visible ()

gboolean
bamf_view_is_user_visible (BamfView *view);

Parameters

view

a BamfView

 

Returns

a boolean useful for determining if a particular view is "user visible". User visible is a concept relating to whether or not a window should be shown in a launcher tasklist.

Since: 0.4.0


bamf_view_get_name ()

gchar *
bamf_view_get_name (BamfView *view);

Gets the name of a view. This name is a short name best used to represent the view with text.

Parameters

view

a BamfView

 

bamf_view_get_icon ()

gchar *
bamf_view_get_icon (BamfView *view);

Gets the icon of a view. This icon is used to visually represent the view.

Parameters

view

a BamfView

 

bamf_view_get_view_type ()

const gchar *
bamf_view_get_view_type (BamfView *view);

The view type of a window is a short string used to represent all views of the same class. These descriptions should not be used to do casting as they are not considered stable.

[virtual view_type]

Parameters

view

a BamfView

 

bamf_view_set_sticky ()

void
bamf_view_set_sticky (BamfView *view,
                      gboolean value);

bamf_view_is_sticky ()

gboolean
bamf_view_is_sticky (BamfView *view);

bamf_view_get_click_suggestion ()

BamfClickBehavior
bamf_view_get_click_suggestion (BamfView *view);

bamf_view_get_click_suggestion is deprecated and should not be used in newly-written code.


bamf_view_user_visible ()

gboolean
bamf_view_user_visible (BamfView *view);

bamf_view_user_visible has been deprecated since version 0.4.0 and should not be used in newly-written code.

[skip]

Parameters

view

a BamfView

 

Returns

a boolean useful for determining if a particular view is "user visible". User visible is a concept relating to whether or not a window should be shown in a launcher tasklist.

Types and Values

BAMF_TYPE_VIEW

#define BAMF_TYPE_VIEW (bamf_view_get_type ())

BAMF_VIEW_SIGNAL_ACTIVE_CHANGED

#define BAMF_VIEW_SIGNAL_ACTIVE_CHANGED       "active-changed"

BAMF_VIEW_SIGNAL_RUNNING_CHANGED

#define BAMF_VIEW_SIGNAL_RUNNING_CHANGED      "running-changed"

BAMF_VIEW_SIGNAL_STARTING_CHANGED

#define BAMF_VIEW_SIGNAL_STARTING_CHANGED     "starting-changed"

BAMF_VIEW_SIGNAL_URGENT_CHANGED

#define BAMF_VIEW_SIGNAL_URGENT_CHANGED       "urgent-changed"

BAMF_VIEW_SIGNAL_USER_VISIBLE_CHANGED

#define BAMF_VIEW_SIGNAL_USER_VISIBLE_CHANGED "user-visible-changed"

BAMF_VIEW_SIGNAL_NAME_CHANGED

#define BAMF_VIEW_SIGNAL_NAME_CHANGED         "name-changed"

BAMF_VIEW_SIGNAL_ICON_CHANGED

#define BAMF_VIEW_SIGNAL_ICON_CHANGED         "icon-changed"

BAMF_VIEW_SIGNAL_CHILD_ADDED

#define BAMF_VIEW_SIGNAL_CHILD_ADDED          "child-added"

BAMF_VIEW_SIGNAL_CHILD_REMOVED

#define BAMF_VIEW_SIGNAL_CHILD_REMOVED        "child-removed"

BAMF_VIEW_SIGNAL_CHILD_MOVED

#define BAMF_VIEW_SIGNAL_CHILD_MOVED          "child-moved"

BAMF_VIEW_SIGNAL_CLOSED

#define BAMF_VIEW_SIGNAL_CLOSED               "closed"

enum BamfClickBehavior

Members

BAMF_CLICK_BEHAVIOR_NONE

   

BAMF_CLICK_BEHAVIOR_OPEN

   

BAMF_CLICK_BEHAVIOR_FOCUS

   

BAMF_CLICK_BEHAVIOR_FOCUS_ALL

   

BAMF_CLICK_BEHAVIOR_MINIMIZE

   

BAMF_CLICK_BEHAVIOR_RESTORE

   

BAMF_CLICK_BEHAVIOR_RESTORE_ALL

   

BAMF_CLICK_BEHAVIOR_PICKER

   

struct BamfViewClass

struct BamfViewClass {
  GInitiallyUnownedClass parent_class;

  GList            * (*get_children)        (BamfView *view);
  gboolean           (*is_active)           (BamfView *view);
  gboolean           (*is_running)          (BamfView *view);
  gboolean           (*is_urgent)           (BamfView *view);
  gboolean           (*is_user_visible)     (BamfView *view);
  gchar            * (*get_name)            (BamfView *view);
  gchar            * (*get_icon)            (BamfView *view);
  const gchar      * (*view_type)           (BamfView *view);
  void               (*set_path)            (BamfView *view, const gchar *path);
  void               (*set_sticky)          (BamfView *view, gboolean value);
  BamfClickBehavior  (*click_behavior)      (BamfView *view);

  /*< signals >*/
  void (*active_changed)              (BamfView *view, gboolean active);
  void (*closed)                      (BamfView *view);
  void (*child_added)                 (BamfView *view, BamfView *child);
  void (*child_removed)               (BamfView *view, BamfView *child);
  void (*running_changed)             (BamfView *view, gboolean running);
  void (*urgent_changed)              (BamfView *view, gboolean urgent);
  void (*user_visible_changed)        (BamfView *view, gboolean user_visible);
  void (*name_changed)                (BamfView *view, gchar* old_name, gchar* new_name);
  void (*icon_changed)                (BamfView *view, gchar* icon);
  void (*child_moved)                 (BamfView *view, BamfView *child);

  gboolean (*is_starting)             (BamfView *view);
  void     (*starting_changed)        (BamfView *view, gboolean starting);
};

BamfView

typedef struct _BamfView BamfView;

Property Details

The “active” property

  “active”                   gboolean

active.

Owner: BamfView

Flags: Read

Default value: FALSE


The “path” property

  “path”                     char *

path.

Owner: BamfView

Flags: Read

Default value: NULL


The “running” property

  “running”                  gboolean

running.

Owner: BamfView

Flags: Read

Default value: FALSE


The “starting” property

  “starting”                 gboolean

starting.

Owner: BamfView

Flags: Read

Default value: FALSE


The “urgent” property

  “urgent”                   gboolean

urgent.

Owner: BamfView

Flags: Read

Default value: FALSE


The “user-visible” property

  “user-visible”             gboolean

user-visible.

Owner: BamfView

Flags: Read

Default value: FALSE

Signal Details

The “active-changed” signal

void
user_function (BamfView *bamfview,
               gboolean  arg1,
               gpointer  user_data)

Flags: Run First


The “child-added” signal

void
user_function (BamfView *bamfview,
               BamfView *arg1,
               gpointer  user_data)

Flags: Run First


The “child-moved” signal

void
user_function (BamfView *bamfview,
               BamfView *arg1,
               gpointer  user_data)

Flags: Run First


The “child-removed” signal

void
user_function (BamfView *bamfview,
               BamfView *arg1,
               gpointer  user_data)

Flags: Run First


The “closed” signal

void
user_function (BamfView *bamfview,
               gpointer  user_data)

Flags: Run Last


The “icon-changed” signal

void
user_function (BamfView *bamfview,
               char     *arg1,
               gpointer  user_data)

The “name-changed” signal

void
user_function (BamfView *bamfview,
               char     *arg1,
               char     *arg2,
               gpointer  user_data)

The “running-changed” signal

void
user_function (BamfView *bamfview,
               gboolean  arg1,
               gpointer  user_data)

Flags: Run First


The “starting-changed” signal

void
user_function (BamfView *bamfview,
               gboolean  arg1,
               gpointer  user_data)

Flags: Run First


The “urgent-changed” signal

void
user_function (BamfView *bamfview,
               gboolean  arg1,
               gpointer  user_data)

Flags: Run First


The “user-visible-changed” signal

void
user_function (BamfView *bamfview,
               gboolean  arg1,
               gpointer  user_data)

Flags: Run First