~ubuntu-branches/debian/stretch/gnac/stretch

« back to all changes in this revision

Viewing changes to src/gnac-ui-utils.h

  • Committer: Package Import Robot
  • Author(s): Khalid El Fathi
  • Date: 2012-04-14 20:15:31 UTC
  • Revision ID: package-import@ubuntu.com-20120414201531-2gcfq8fs94kgp9qr
Tags: upstream-0.2.4
ImportĀ upstreamĀ versionĀ 0.2.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * This file is part of GNAC - Gnome Audio Converter
 
3
 *
 
4
 * Copyright (C) 2007 - 2012 Gnac
 
5
 *    
 
6
 *    - DUPASQUIER  Benoit    <bdupasqu@src.gnome.org>
 
7
 *    - JOAQUIM     David     <djoaquim@src.gnome.org>
 
8
 *    - ROUX        Alexandre <alexroux@src.gnome.org>
 
9
 *
 
10
 * GNAC is free software; you can redistribute it and/or modify
 
11
 * it under the terms of the GNU General Public License as published by
 
12
 * the Free Software Foundation; either version 3 of the License, or
 
13
 * (at your option) any later version.
 
14
 *
 
15
 * GNAC is distributed in the hope that it will be useful,
 
16
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
17
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
18
 * GNU General Public License for more details.
 
19
 *
 
20
 * You should have received a copy of the GNU General Public License
 
21
 * along with GNAC; if not, write to the Free Software
 
22
 * Foundation, Inc., 51 Franklin St, Fifth Floor, 
 
23
 * Boston, MA  02110-1301  USA
 
24
 */
 
25
 
 
26
#ifndef GNAC_UI_UTILS_H
 
27
#define GNAC_UI_UTILS_H
 
28
 
 
29
#include <gtk/gtk.h>
 
30
 
 
31
G_BEGIN_DECLS
 
32
 
 
33
gint
 
34
gnac_ui_utils_get_combo_size(GtkComboBox *combo);
 
35
 
 
36
/* scale pixbuf to width x height while keeping the aspect ratio */
 
37
GdkPixbuf *
 
38
gnac_ui_utils_scale_pixbuf(GdkPixbuf *pixbuf,
 
39
                           gint       width,
 
40
                           gint       height);
 
41
 
 
42
/* add a one pixel black border around pixbuf */
 
43
GdkPixbuf *
 
44
gnac_ui_utils_add_border_to_pixbuf(GdkPixbuf *pixbuf);
 
45
 
 
46
gboolean
 
47
gnac_ui_utils_event_is_left_click(GdkEventButton *event);
 
48
 
 
49
gboolean
 
50
gnac_ui_utils_event_is_right_click(GdkEventButton *event);
 
51
 
 
52
gboolean
 
53
gnac_ui_utils_event_is_double_left_click(GdkEventButton *event);
 
54
 
 
55
gboolean
 
56
gnac_ui_utils_event_is_single_right_click(GdkEventButton *event);
 
57
 
 
58
gboolean
 
59
gnac_ui_utils_event_is_key_press(GdkEventKey *event);
 
60
 
 
61
gboolean
 
62
gnac_ui_utils_event_is_delete_key(GdkEventKey *event);
 
63
 
 
64
gboolean
 
65
gnac_ui_utils_event_is_escape_key(GdkEventKey *event);
 
66
 
 
67
gboolean
 
68
gnac_ui_utils_event_is_return_key(GdkEventKey *event);
 
69
 
 
70
GtkBuilder *
 
71
gnac_ui_utils_create_gtk_builder(const gchar *filename);
 
72
 
 
73
GObject *
 
74
gnac_ui_utils_get_object(GtkBuilder  *builder,
 
75
                         const gchar *object_name);
 
76
 
 
77
GtkWidget *
 
78
gnac_ui_utils_get_widget(GtkBuilder  *builder,
 
79
                         const gchar *widget_name);
 
80
 
 
81
GtkAction *
 
82
gnac_ui_utils_get_action(GtkBuilder  *builder,
 
83
                         const gchar *action_name);
 
84
 
 
85
void
 
86
gnac_ui_utils_set_action_sensitive(GtkBuilder  *builder,
 
87
                                   const gchar *action_name,
 
88
                                   gboolean     activate);
 
89
 
 
90
void
 
91
gnac_ui_utils_set_action_visible(GtkBuilder  *builder,
 
92
                                 const gchar *action_name,
 
93
                                 gboolean     visible);
 
94
 
 
95
void
 
96
gnac_ui_utils_set_widget_sensitive(GtkBuilder  *builder,
 
97
                                   const gchar *widget_name,
 
98
                                   gboolean     activate);
 
99
 
 
100
G_END_DECLS
 
101
 
 
102
#endif /* GNAC_UI_UTILS_H */