GiwClock

GiwClock — a clock widget

Stability Level

Stable, unless otherwise indicated

Synopsis


#include <giwclock.h>


                    GiwClock;
GtkWidget*          giw_clock_new                       (void);
void                giw_clock_get_time                  (GiwClock *clock,
                                                         guint *hours,
                                                         guint *minutes,
                                                         guint *seconds);
void                giw_clock_set_time                  (GiwClock *clock,
                                                         guint hours,
                                                         guint minutes,
                                                         guint seconds);
void                giw_clock_enable_alarm              (GiwClock *clock,
                                                         gboolean option);
void                giw_clock_set_alarm                 (GiwClock *clock,
                                                         guint hours,
                                                         guint minutes,
                                                         guint seconds);
void                giw_clock_stop                      (GiwClock *clock);
void                giw_clock_start                     (GiwClock *clock);

Object Hierarchy


  GObject
   +----GInitiallyUnowned
         +----GtkObject
               +----GtkWidget
                     +----GiwClock

Implemented Interfaces

GiwClock implements AtkImplementorIface.

Signals


  "alarm"                                          : Run First / Action

Description

GiwClock is a clock, with 60 ticks and three needles. It can be created with a giw_clock_new(), an cofigured with the functions below.

Details

GiwClock

typedef struct _GiwClock GiwClock;


giw_clock_new ()

GtkWidget*          giw_clock_new                       (void);

Creates a new clock, with initial time of 00:00:00, and it starts counting time automatically.

Returns : a new clock, or NULL.

Since 0.2.1


giw_clock_get_time ()

void                giw_clock_get_time                  (GiwClock *clock,
                                                         guint *hours,
                                                         guint *minutes,
                                                         guint *seconds);

clock :
hours :
minutes :
seconds :

giw_clock_set_time ()

void                giw_clock_set_time                  (GiwClock *clock,
                                                         guint hours,
                                                         guint minutes,
                                                         guint seconds);

clock :
hours :
minutes :
seconds :

giw_clock_enable_alarm ()

void                giw_clock_enable_alarm              (GiwClock *clock,
                                                         gboolean option);

clock :
option :

giw_clock_set_alarm ()

void                giw_clock_set_alarm                 (GiwClock *clock,
                                                         guint hours,
                                                         guint minutes,
                                                         guint seconds);

clock :
hours :
minutes :
seconds :

giw_clock_stop ()

void                giw_clock_stop                      (GiwClock *clock);

clock :

giw_clock_start ()

void                giw_clock_start                     (GiwClock *clock);

clock :

Signal Details

The "alarm" signal

void                user_function                      (GiwClock *giwclock,
                                                        gpointer  user_data)      : Run First / Action

giwclock : the object which received the signal.
user_data : user data set when the signal handler was connected.