CtkFocusable

CtkFocusable — CtkFocusable is an interface designed to allow objects to become focused

Synopsis

#include <ctk-focusable.h>

                    CtkFocusable;
                    CtkFocusableIface;
enum                CtkFocusDirection;

Object Hierarchy

  GInterface
   +----CtkFocusable

Known Implementations

CtkFocusable is implemented by CtkActor, CtkBin, CtkBox, CtkButton, CtkCheckMenuItem, CtkHBox, CtkIconView, CtkImage, CtkImageMenuItem, CtkLayerActor, CtkMenu, CtkMenuExpandable, CtkMenuItem, CtkMenuSeperator, CtkRadioMenuItem, CtkScrollView, CtkTooltip, CtkToplevel and CtkVBox.

Description

CtkFocusable is an interface layered ontop of other Ctk widgets in order to allow them to become focused in some way it also provides methods in order to manipulate and return focused status

Details

CtkFocusable

typedef struct _CtkFocusable CtkFocusable;


CtkFocusableIface

typedef struct {
  void     (*set_focused) (CtkFocusable *focusable,
                           gboolean      is_focused);

  gboolean (*get_focused) (CtkFocusable *focusable);

  gboolean (*can_focus)   (CtkFocusable *focusable);

  void     (*activate)    (CtkFocusable      *focusable);
} CtkFocusableIface;


enum CtkFocusDirection

typedef enum
{
  CTK_FOCUS_DIR_NONE,
  CTK_FOCUS_DIR_NEXT,
  CTK_FOCUS_DIR_PREV,
  CTK_FOCUS_DIR_UP,
  CTK_FOCUS_DIR_RIGHT,
  CTK_FOCUS_DIR_DOWN,
  CTK_FOCUS_DIR_LEFT
} CtkFocusDirection;