minidialog.h
Go to the documentation of this file.
/* pidgin
*
* Pidgin is the legal property of its developers, whose names are too numerous
* to list here. Please refer to the COPYRIGHT file distributed with this
* source distribution.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
*/
#ifndef __PIDGIN_MINI_DIALOG_H__
#define __PIDGIN_MINI_DIALOG_H__
#include <glib-object.h>
#include <gtk/gtk.h>
G_BEGIN_DECLS
#define PIDGIN_TYPE_MINI_DIALOG pidgin_mini_dialog_get_type()
#define PIDGIN_MINI_DIALOG(obj) \
(G_TYPE_CHECK_INSTANCE_CAST ((obj), \
PIDGIN_TYPE_MINI_DIALOG, PidginMiniDialog))
#define PIDGIN_MINI_DIALOG_CLASS(klass) \
(G_TYPE_CHECK_CLASS_CAST ((klass), \
PIDGIN_TYPE_MINI_DIALOG, PidginMiniDialogClass))
#define PIDGIN_IS_MINI_DIALOG(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
PIDGIN_TYPE_MINI_DIALOG))
#define PIDGIN_IS_MINI_DIALOG_CLASS(klass) \
(G_TYPE_CHECK_CLASS_TYPE ((klass), \
PIDGIN_TYPE_MINI_DIALOG))
#define PIDGIN_MINI_DIALOG_GET_CLASS(obj) \
(G_TYPE_INSTANCE_GET_CLASS ((obj), \
PIDGIN_TYPE_MINI_DIALOG, PidginMiniDialogClass))
typedef struct {
GtkVBox parent;
GtkBox *contents;
gpointer priv;
} PidginMiniDialog;
typedef struct {
GtkBoxClass parent_class;
void (*_purple_reserved1) (void);
void (*_purple_reserved2) (void);
void (*_purple_reserved3) (void);
void (*_purple_reserved4) (void);
} PidginMiniDialogClass;
typedef void (*PidginMiniDialogCallback)(PidginMiniDialog *mini_dialog,
GtkButton *button, gpointer user_data);
GType pidgin_mini_dialog_get_type (void);
PidginMiniDialog *pidgin_mini_dialog_new(const gchar *title,
const gchar *description, const gchar *icon_name);
PidginMiniDialog *pidgin_mini_dialog_new_with_custom_icon(const gchar *title,
const gchar *description, GdkPixbuf *custom_icon);
void pidgin_mini_dialog_set_title(PidginMiniDialog *mini_dialog,
const char *title);
void pidgin_mini_dialog_set_description(PidginMiniDialog *mini_dialog,
const char *description);
void pidgin_mini_dialog_enable_description_markup(PidginMiniDialog *mini_dialog);
gboolean pidgin_mini_dialog_links_supported(void);
void pidgin_mini_dialog_set_link_callback(PidginMiniDialog *mini_dialog, GCallback cb, gpointer user_data);
void pidgin_mini_dialog_set_icon_name(PidginMiniDialog *mini_dialog,
const char *icon_name);
void pidgin_mini_dialog_set_custom_icon(PidginMiniDialog *mini_dialog,
GdkPixbuf *custom_icon);
void pidgin_mini_dialog_add_button(PidginMiniDialog *mini_dialog,
const char *text, PidginMiniDialogCallback clicked_cb,
gpointer user_data);
void pidgin_mini_dialog_add_non_closing_button(PidginMiniDialog *mini_dialog,
const char *text, PidginMiniDialogCallback clicked_cb,
gpointer user_data);
guint pidgin_mini_dialog_get_num_children(PidginMiniDialog *mini_dialog);
G_END_DECLS
#endif /* __PIDGIN_MINI_DIALOG_H__ */
pidgin_mini_dialog_set_custom_icon
void pidgin_mini_dialog_set_custom_icon(PidginMiniDialog *mini_dialog, GdkPixbuf *custom_icon)
Shortcut for setting a mini-dialog's custom icon via GObject properties.
pidgin_mini_dialog_set_title
void pidgin_mini_dialog_set_title(PidginMiniDialog *mini_dialog, const char *title)
Shortcut for setting a mini-dialog's title via GObject properties.
pidgin_mini_dialog_new
PidginMiniDialog * pidgin_mini_dialog_new(const gchar *title, const gchar *description, const gchar *icon_name)
Creates a new PidginMiniDialog with a stock icon.
pidgin_mini_dialog_add_non_closing_button
void pidgin_mini_dialog_add_non_closing_button(PidginMiniDialog *mini_dialog, const char *text, PidginMiniDialogCallback clicked_cb, gpointer user_data)
Equivalent to pidgin_mini_dialog_add_button(), the only difference is that the mini-dialog won't be c...
pidgin_mini_dialog_get_type
GType pidgin_mini_dialog_get_type(void)
Get the GType of PidginMiniDialog.
pidgin_mini_dialog_new_with_custom_icon
PidginMiniDialog * pidgin_mini_dialog_new_with_custom_icon(const gchar *title, const gchar *description, GdkPixbuf *custom_icon)
Creates a new PidginMiniDialog with a custom icon.
pidgin_mini_dialog_get_num_children
guint pidgin_mini_dialog_get_num_children(PidginMiniDialog *mini_dialog)
Gets the number of widgets packed into PidginMiniDialog.contents.
PidginMiniDialogCallback
void(* PidginMiniDialogCallback)(PidginMiniDialog *mini_dialog, GtkButton *button, gpointer user_data)
The type of a callback triggered by a button in a mini-dialog being pressed.
Definition: minidialog.h:107
pidgin_mini_dialog_links_supported
gboolean pidgin_mini_dialog_links_supported(void)
Mini-dialogs support hyperlinks in their description (you should first call pidgin_mini_dialog_enable...
pidgin_mini_dialog_set_link_callback
void pidgin_mini_dialog_set_link_callback(PidginMiniDialog *mini_dialog, GCallback cb, gpointer user_data)
Sets a callback which gets invoked when a hyperlink in the dialog's description is clicked on.
pidgin_mini_dialog_set_description
void pidgin_mini_dialog_set_description(PidginMiniDialog *mini_dialog, const char *description)
Shortcut for setting a mini-dialog's description via GObject properties.
pidgin_mini_dialog_set_icon_name
void pidgin_mini_dialog_set_icon_name(PidginMiniDialog *mini_dialog, const char *icon_name)
Shortcut for setting a mini-dialog's icon via GObject properties.
pidgin_mini_dialog_add_button
void pidgin_mini_dialog_add_button(PidginMiniDialog *mini_dialog, const char *text, PidginMiniDialogCallback clicked_cb, gpointer user_data)
Adds a new button to a mini-dialog, and attaches the supplied callback to its clicked signal.
pidgin_mini_dialog_enable_description_markup
void pidgin_mini_dialog_enable_description_markup(PidginMiniDialog *mini_dialog)
Enable GMarkup elements in the mini-dialog's description.
PidginMiniDialogClass
The class of PidginMiniDialog objects.
Definition: minidialog.h:91
PidginMiniDialog
A widget resembling a diminutive dialog box, designed to be embedded in the PidginBuddyList.
Definition: minidialog.h:80
PidginMiniDialog::contents
GtkBox * contents
A GtkVBox into which extra widgets for the dialog should be packed.
Definition: minidialog.h:85