hildon-gtk

hildon-gtk — Additional functions for Gtk widgets

Synopsis

GtkWidget*          hildon_gtk_menu_new                 (void);
GtkWidget*          hildon_gtk_button_new               (HildonSizeType size);
GtkWidget*          hildon_gtk_toggle_button_new        (HildonSizeType size);
GtkWidget*          hildon_gtk_radio_button_new         (HildonSizeType size,
                                                         GSList *group);
GtkWidget*          hildon_gtk_radio_button_new_from_widget
                                                        (HildonSizeType size,
                                                         GtkRadioButton *radio_group_member);
GtkWidget*          hildon_gtk_tree_view_new            (HildonUIMode mode);
GtkWidget*          hildon_gtk_tree_view_new_with_model (HildonUIMode mode,
                                                         GtkTreeModel *model);
void                hildon_gtk_tree_view_set_ui_mode    (GtkTreeView *treeview,
                                                         HildonUIMode mode);
GtkWidget*          hildon_gtk_icon_view_new            (HildonUIMode mode);
GtkWidget*          hildon_gtk_icon_view_new_with_model (HildonUIMode mode,
                                                         GtkTreeModel *model);
void                hildon_gtk_icon_view_set_ui_mode    (GtkIconView *iconview,
                                                         HildonUIMode mode);
void                hildon_gtk_window_set_progress_indicator
                                                        (GtkWindow *window,
                                                         guint state);
GtkWidget*          hildon_gtk_hscale_new               (void);
GtkWidget*          hildon_gtk_vscale_new               (void);

Description

Hildon provides some functions to extend the functionality of existing Gtk widgets. This also includes convenience functions to easily perform frequent tasks.

Details

hildon_gtk_menu_new ()

GtkWidget*          hildon_gtk_menu_new                 (void);

This is a convenience function to create a GtkMenu setting its widget name to allow Hildon specific styling.

Returns : A newly created GtkMenu widget.

Since 2.2


hildon_gtk_button_new ()

GtkWidget*          hildon_gtk_button_new               (HildonSizeType size);

This is a convenience function to create a GtkButton setting its size to one of the pre-defined Hildon sizes.

Buttons created with this function also override the "gtk-button-images" setting. Images set using gtk_button_set_image() are always shown.

Buttons created using this function have "focus-on-click" set to FALSE by default.

size : Flags indicating the size of the new button
Returns : A newly created GtkButton widget.

Since 2.2


hildon_gtk_toggle_button_new ()

GtkWidget*          hildon_gtk_toggle_button_new        (HildonSizeType size);

This is a convenience function to create a GtkToggleButton setting its size to one of the pre-defined Hildon sizes.

Buttons created with this function also override the "gtk-button-images" setting. Images set using gtk_button_set_image() are always shown.

Buttons created using this function have "focus-on-click" set to FALSE by default.

size : Flags indicating the size of the new button
Returns : A newly created GtkToggleButton widget.

Since 2.2


hildon_gtk_radio_button_new ()

GtkWidget*          hildon_gtk_radio_button_new         (HildonSizeType size,
                                                         GSList *group);

This is a convenience function to create a GtkRadioButton setting its size to one of the pre-defined Hildon sizes.

Buttons created with this function also override the "gtk-button-images" setting. Images set using gtk_button_set_image() are always shown.

Buttons created using this function have "focus-on-click" set to FALSE by default.

size : Flags indicating the size of the new button
group : An existing radio button group, or NULL if you are creating a new group
Returns : A newly created GtkRadioButton widget.

Since 2.2


hildon_gtk_radio_button_new_from_widget ()

GtkWidget*          hildon_gtk_radio_button_new_from_widget
                                                        (HildonSizeType size,
                                                         GtkRadioButton *radio_group_member);

This is a convenience function to create a GtkRadioButton setting its size to one of the pre-defined Hildon sizes.

Buttons created with this function also override the "gtk-button-images" setting. Images set using gtk_button_set_image() are always shown.

Buttons created using this function have "focus-on-click" set to FALSE by default.

size : Flags indicating the size of the new button
radio_group_member : widget to get radio group from or NULL
Returns : A newly created GtkRadioButton widget.

Since 2.2


hildon_gtk_tree_view_new ()

GtkWidget*          hildon_gtk_tree_view_new            (HildonUIMode mode);

Creates a new GtkTreeView widget with the Hildon UI mode set to mode

mode : the Hildon UI mode
Returns : A newly created GtkTreeView widget.

Since 2.2


hildon_gtk_tree_view_new_with_model ()

GtkWidget*          hildon_gtk_tree_view_new_with_model (HildonUIMode mode,
                                                         GtkTreeModel *model);

Creates a new GtkTreeView widget with the Hildon UI mode set to mode and the model initialized to model.

mode : the Hildon UI mode
model : the model.
Returns : A newly created GtkTreeView widget.

Since 2.2


hildon_gtk_tree_view_set_ui_mode ()

void                hildon_gtk_tree_view_set_ui_mode    (GtkTreeView *treeview,
                                                         HildonUIMode mode);

Sets the UI mode of treeview to mode.

treeview : A GtkTreeView
mode : The new HildonUIMode

Since 2.2


hildon_gtk_icon_view_new ()

GtkWidget*          hildon_gtk_icon_view_new            (HildonUIMode mode);

Creates a new GtkIconView widget with the Hildon UI mode set to mode

mode : the Hildon UI mode
Returns : A newly created GtkIconView widget

Since 2.2


hildon_gtk_icon_view_new_with_model ()

GtkWidget*          hildon_gtk_icon_view_new_with_model (HildonUIMode mode,
                                                         GtkTreeModel *model);

Creates a new GtkIconView widget with the Hildon UI mode set to mode and the model intitialized to model.

mode : the Hildon UI mode
model : The model.
Returns : A newly created GtkIconView widget.

Since 2.2


hildon_gtk_icon_view_set_ui_mode ()

void                hildon_gtk_icon_view_set_ui_mode    (GtkIconView *iconview,
                                                         HildonUIMode mode);

Sets the UI mode of iconview to mode.

iconview : A GtkIconView
mode : The new HildonUIMode

Since 2.2


hildon_gtk_window_set_progress_indicator ()

void                hildon_gtk_window_set_progress_indicator
                                                        (GtkWindow *window,
                                                         guint state);

This functions tells the window manager to show/hide a progress indicator in the window title. It applies to HildonDialog and HildonWindow (including subclasses).

window : The window
state : The state we want to set: 1 -> show progress indicator, 0 -> hide progress indicator.

Since 2.2


hildon_gtk_hscale_new ()

GtkWidget*          hildon_gtk_hscale_new               (void);

Creates a new horizontal scale widget that lets the user select a value. The value is technically a double between 0.0 and 1.0. See gtk_adjustment_configure() for reconfiguring the adjustment.

The scale is hildonized, which means that a click or tap immediately jumps to the desired position, see gtk_range_set_jump_to_position(). Further more the value is not displayed, see gtk_scale_set_draw_value().

Returns : a new hildonized GtkHScale

Since 2.2


hildon_gtk_vscale_new ()

GtkWidget*          hildon_gtk_vscale_new               (void);

Creates a new vertical scale widget that lets the user select a value. The value is technically a double between 0.0 and 1.0. See gtk_adjustment_configure() for reconfiguring the adjustment.

The scale is hildonized, which means that a click or tap immediately jumps to the desired position, see gtk_range_set_jump_to_position(). Further more the value is not displayed, see gtk_scale_set_draw_value().

Returns : a new hildonized GtkVScale

Since 2.2

See Also

HildonButton, HildonCheckButton