JanaGtkYearView

JanaGtkYearView

Synopsis

                    JanaGtkYearView;
GtkWidget *         jana_gtk_year_view_new              (guint months_per_row,
                                                         JanaTime *year);
void                jana_gtk_year_view_add_store        (JanaGtkYearView *self,
                                                         JanaGtkEventStore *store);
void                jana_gtk_year_view_remove_store     (JanaGtkYearView *self,
                                                         JanaGtkEventStore *store);
void                jana_gtk_year_view_set_year         (JanaGtkYearView *self,
                                                         JanaTime *year);
JanaTime *          jana_gtk_year_view_get_year         (JanaGtkYearView *self);
void                jana_gtk_year_view_set_months_per_row
                                                        (JanaGtkYearView *self,
                                                         guint months_per_row);
gint                jana_gtk_year_view_get_selected_month
                                                        (JanaGtkYearView *self);
void                jana_gtk_year_view_set_selected_month
                                                        (JanaGtkYearView *self,
                                                         gint month);
void                jana_gtk_year_view_set_highlighted_time
                                                        (JanaGtkYearView *self,
                                                         JanaTime *time);

Object Hierarchy

  GObject
   +----GInitiallyUnowned
         +----GtkWidget
               +----GtkContainer
                     +----GtkTable
                           +----JanaGtkYearView

Implemented Interfaces

JanaGtkYearView implements AtkImplementorIface and GtkBuildable.

Properties

  "highlighted-time"         GObject*              : Read / Write
  "months-per-row"           guint                 : Write
  "year"                     GObject*              : Read / Write

Signals

  "selection-changed"                              : Run Last

Description

Details

JanaGtkYearView

typedef struct _JanaGtkYearView JanaGtkYearView;


jana_gtk_year_view_new ()

GtkWidget *         jana_gtk_year_view_new              (guint months_per_row,
                                                         JanaTime *year);

Create a new widget that provides a summary of events over year.

months_per_row :

Number of months to pack into a row

year :

The year to count events in

Returns :

A new JanaGtkYearView widget.

jana_gtk_year_view_add_store ()

void                jana_gtk_year_view_add_store        (JanaGtkYearView *self,
                                                         JanaGtkEventStore *store);

Adds store to the list of JanaGtkEventStore objects used in visualising the year.

self :

A JanaGtkYearView

store :

A JanaGtkEventStore

jana_gtk_year_view_remove_store ()

void                jana_gtk_year_view_remove_store     (JanaGtkYearView *self,
                                                         JanaGtkEventStore *store);

Removes store from the list of JanaGtkEventStore objects used in visualising the year. If store has not previously been added with jana_gtk_year_view_add_store(), nothing happens.

self :

A JanaGtkYearView

store :

A JanaGtkEventStore

jana_gtk_year_view_set_year ()

void                jana_gtk_year_view_set_year         (JanaGtkYearView *self,
                                                         JanaTime *year);

Set the year for self to count events in.

self :

A JanaGtkYearView

year :

The year to count events in

jana_gtk_year_view_get_year ()

JanaTime *          jana_gtk_year_view_get_year         (JanaGtkYearView *self);

Gets the year self is counting events in.

self :

A JanaGtkYearView

Returns :

The year self is counting events in.

jana_gtk_year_view_set_months_per_row ()

void                jana_gtk_year_view_set_months_per_row
                                                        (JanaGtkYearView *self,
                                                         guint months_per_row);

Set the number of months for self to pack into a row.

self :

A JanaGtkYearView

months_per_row :

Months to pack per row, between 1 and 12, inclusive

jana_gtk_year_view_get_selected_month ()

gint                jana_gtk_year_view_get_selected_month
                                                        (JanaGtkYearView *self);

Gets the currently selected month, between 0 and 12 inclusive. 0 corresponds to there being no event selected.

self :

A JanaGtkYearView

Returns :

The selected month, 1 - 12, or 0 if there is no selected month.

jana_gtk_year_view_set_selected_month ()

void                jana_gtk_year_view_set_selected_month
                                                        (JanaGtkYearView *self,
                                                         gint month);

Sets or clears the selected month.

self :

A JanaGtkYearView

month :

A month (1 - 12), or 0 to clear the selection

jana_gtk_year_view_set_highlighted_time ()

void                jana_gtk_year_view_set_highlighted_time
                                                        (JanaGtkYearView *self,
                                                         JanaTime *time);

Sets a time to be highlighted. This can be used to highlight the current time, for example.

self :

A JanaGtkYearView

time :

A JanaTime

Property Details

The "highlighted-time" property

  "highlighted-time"         GObject*              : Read / Write

A time that should be highlighted, for example, the current time.


The "months-per-row" property

  "months-per-row"           guint                 : Write

Months to display per row.

Allowed values: [1,12]

Default value: 3


The "year" property

  "year"                     GObject*              : Read / Write

Year to count events in.

Signal Details

The "selection-changed" signal

void                user_function                      (JanaGtkYearView *janagtkyearview,
                                                        gint             arg1,
                                                        gpointer         user_data)            : Run Last

janagtkyearview :

the object which received the signal.

user_data :

user data set when the signal handler was connected.