gtkconvwin.h
Go to the documentation of this file.
1 
6 /* pidgin
7  *
8  * Pidgin is the legal property of its developers, whose names are too numerous
9  * to list here. Please refer to the COPYRIGHT file distributed with this
10  * source distribution.
11  *
12  * This program is free software; you can redistribute it and/or modify
13  * it under the terms of the GNU General Public License as published by
14  * the Free Software Foundation; either version 2 of the License, or
15  * (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * You should have received a copy of the GNU General Public License
23  * along with this program; if not, write to the Free Software
24  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
25  */
26 #ifndef _PIDGIN_CONVERSATION_WINDOW_H_
27 #define _PIDGIN_CONVERSATION_WINDOW_H_
28 
29 typedef struct _PidginWindow PidginWindow;
30 
31 
32 /**************************************************************************
33  * @name Structures
34  **************************************************************************/
42 {
43  GtkWidget *window;
44  GtkWidget *notebook;
45  GList *gtkconvs;
46 
47  struct
48  {
49  GtkWidget *menubar;
50 
51  GtkWidget *view_log;
52 
53  GtkWidget *send_file;
54  GtkWidget *add_pounce;
55  GtkWidget *get_info;
56  GtkWidget *invite;
57 
58  GtkWidget *alias;
59  GtkWidget *block;
60  GtkWidget *unblock;
61  GtkWidget *add;
62  GtkWidget *remove;
63 
64  GtkWidget *insert_link;
65  GtkWidget *insert_image;
66 
67  GtkWidget *logging;
68  GtkWidget *sounds;
69  GtkWidget *show_formatting_toolbar;
70  GtkWidget *show_timestamps;
71  GtkWidget *show_icon;
72 
73  GtkWidget *send_to;
74 
75  GtkWidget *tray;
76 
77  GtkWidget *typing_icon;
78 
79  GtkItemFactory *item_factory;
80 
81  } menu;
82 
83  struct
84  {
85  GtkWidget *search;
86 
87  } dialogs;
88 
89  /* Tab dragging stuff. */
90  gboolean in_drag;
91  gboolean in_predrag;
92 
93  gint drag_tab;
94 
95  gint drag_min_x, drag_max_x, drag_min_y, drag_max_y;
96 
97  gint drag_motion_signal;
98  gint drag_leave_signal;
99 
100  /* Media menu options. */
101  GtkWidget *audio_call;
102  GtkWidget *video_call;
103  GtkWidget *audio_video_call;
104 };
105 
108 /**************************************************************************
109  * @name GTK+ Conversation Window API
110  **************************************************************************/
113 PidginWindow * pidgin_conv_window_new(void);
114 void pidgin_conv_window_destroy(PidginWindow *win);
115 GList *pidgin_conv_windows_get_list(void);
116 void pidgin_conv_window_show(PidginWindow *win);
117 void pidgin_conv_window_hide(PidginWindow *win);
118 void pidgin_conv_window_raise(PidginWindow *win);
119 void pidgin_conv_window_switch_gtkconv(PidginWindow *win, PidginConversation *gtkconv);
120 void pidgin_conv_window_add_gtkconv(PidginWindow *win, PidginConversation *gtkconv);
121 void pidgin_conv_window_remove_gtkconv(PidginWindow *win, PidginConversation *gtkconv);
122 PidginConversation *pidgin_conv_window_get_gtkconv_at_index(const PidginWindow *win, int index);
123 PidginConversation *pidgin_conv_window_get_active_gtkconv(const PidginWindow *win);
124 PurpleConversation *pidgin_conv_window_get_active_conversation(const PidginWindow *win);
125 gboolean pidgin_conv_window_is_active_conversation(const PurpleConversation *conv);
126 gboolean pidgin_conv_window_has_focus(PidginWindow *win);
127 PidginWindow *pidgin_conv_window_get_at_xy(int x, int y);
128 GList *pidgin_conv_window_get_gtkconvs(PidginWindow *win);
129 guint pidgin_conv_window_get_gtkconv_count(PidginWindow *win);
130 
131 PidginWindow *pidgin_conv_window_first_with_type(PurpleConversationType type);
132 PidginWindow *pidgin_conv_window_last_with_type(PurpleConversationType type);
133 
136 /**************************************************************************
137  * @name GTK+ Conversation Placement API
138  **************************************************************************/
141 typedef void (*PidginConvPlacementFunc)(PidginConversation *);
142 
143 GList *pidgin_conv_placement_get_options(void);
144 void pidgin_conv_placement_add_fnc(const char *id, const char *name, PidginConvPlacementFunc fnc);
145 void pidgin_conv_placement_remove_fnc(const char *id);
146 const char *pidgin_conv_placement_get_name(const char *id);
147 PidginConvPlacementFunc pidgin_conv_placement_get_fnc(const char *id);
148 void pidgin_conv_placement_set_current_func(PidginConvPlacementFunc func);
149 PidginConvPlacementFunc pidgin_conv_placement_get_current_func(void);
150 void pidgin_conv_placement_place(PidginConversation *gtkconv);
151 
154 #endif /* _PIDGIN_CONVERSATION_WINDOW_H_ */
A GTK+ representation of a graphical window containing one or more conversations. ...
Definition: gtkconvwin.h:41
GtkWidget * window
The window.
Definition: gtkconvwin.h:43
A GTK+ conversation pane.
Definition: gtkconv.h:115
PurpleConversationType
A type of conversation.
Definition: conversation.h:51
GtkWidget * notebook
The notebook of conversations.
Definition: gtkconvwin.h:44
A core representation of a conversation between two or more people.
Definition: conversation.h:335