Data Structures | Macros | Typedefs | Functions
minidialog.h File Reference
Pidgin (GTK+ User Interface)

API for the PidginMiniDialog Gtk widget. More...

`#include <glib-object.h>`
`#include <gtk/gtk.h>`

Go to the source code of this file.

## Data Structures
struct | PidginMiniDialog
| A widget resembling a diminutive dialog box, designed to be embedded in the PidginBuddyList. More...
struct | PidginMiniDialogClass
| The class of PidginMiniDialog objects. More...

## Macros
#define | PIDGIN_TYPE_MINI_DIALOG pidgin_mini_dialog_get_type()
#define | PIDGIN_MINI_DIALOG(obj)
#define | PIDGIN_MINI_DIALOG_CLASS(klass)
#define | PIDGIN_IS_MINI_DIALOG(obj)
#define | PIDGIN_IS_MINI_DIALOG_CLASS(klass)
#define | PIDGIN_MINI_DIALOG_GET_CLASS(obj)

## Typedefs
typedef 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. More...

## Functions
GType | pidgin_mini_dialog_get_type (void)
| Get the GType of PidginMiniDialog. More...
PidginMiniDialog * | pidgin_mini_dialog_new (const gchar *title, const gchar *description, const gchar *icon_name)
| Creates a new PidginMiniDialog with a stock icon. More...
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. More...
void | pidgin_mini_dialog_set_title (PidginMiniDialog *mini_dialog, const char *title)
| Shortcut for setting a mini-dialog's title via GObject properties. More...
void | pidgin_mini_dialog_set_description (PidginMiniDialog *mini_dialog, const char *description)
| Shortcut for setting a mini-dialog's description via GObject properties. More...
void | pidgin_mini_dialog_enable_description_markup (PidginMiniDialog *mini_dialog)
| Enable GMarkup elements in the mini-dialog's description. More...
gboolean | pidgin_mini_dialog_links_supported (void)
| Mini-dialogs support hyperlinks in their description (you should first call pidgin_mini_dialog_enable_description_markup() on a given dialog to enable them). More...
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. More...
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. More...
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. More...
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. More...
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 closed after the button is clicked.
guint | pidgin_mini_dialog_get_num_children (PidginMiniDialog *mini_dialog)
| Gets the number of widgets packed into PidginMiniDialog.contents. More...

## Detailed Description

API for the PidginMiniDialog Gtk widget.

Definition in file minidialog.h.

## Macro Definition Documentation

## ◆ PIDGIN_IS_MINI_DIALOG

#define PIDGIN_IS_MINI_DIALOG | ( |  | obj | ) |

Value:
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
PIDGIN_TYPE_MINI_DIALOG))

Definition at line 45 of file minidialog.h.

## ◆ PIDGIN_IS_MINI_DIALOG_CLASS

#define PIDGIN_IS_MINI_DIALOG_CLASS | ( |  | klass | ) |

Value:
(G_TYPE_CHECK_CLASS_TYPE ((klass), \
PIDGIN_TYPE_MINI_DIALOG))

Definition at line 49 of file minidialog.h.

## ◆ PIDGIN_MINI_DIALOG

#define PIDGIN_MINI_DIALOG | ( |  | obj | ) |

Value:
(G_TYPE_CHECK_INSTANCE_CAST ((obj), \
PIDGIN_TYPE_MINI_DIALOG, PidginMiniDialog))
PidginMiniDialog
A widget resembling a diminutive dialog box, designed to be embedded in the PidginBuddyList.
Definition: minidialog.h:80

Definition at line 37 of file minidialog.h.

## ◆ PIDGIN_MINI_DIALOG_CLASS

#define PIDGIN_MINI_DIALOG_CLASS | ( |  | klass | ) |

Value:
(G_TYPE_CHECK_CLASS_CAST ((klass), \
PIDGIN_TYPE_MINI_DIALOG, PidginMiniDialogClass))
PidginMiniDialogClass
The class of PidginMiniDialog objects.
Definition: minidialog.h:91

Definition at line 41 of file minidialog.h.

## ◆ PIDGIN_MINI_DIALOG_GET_CLASS

#define PIDGIN_MINI_DIALOG_GET_CLASS | ( |  | obj | ) |

Value:
(G_TYPE_INSTANCE_GET_CLASS ((obj), \
PIDGIN_TYPE_MINI_DIALOG, PidginMiniDialogClass))
PidginMiniDialogClass
The class of PidginMiniDialog objects.
Definition: minidialog.h:91

Definition at line 53 of file minidialog.h.

## Typedef Documentation

## ◆ PidginMiniDialogCallback

typedef 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.

Parameters

  mini_dialog | a dialog, one of whose buttons has been pressed.
  button | the button which was pressed.
  user_data | arbitrary data, supplied to pidgin_mini_dialog_add_button() when the button was created.

Definition at line 107 of file minidialog.h.

## Function Documentation

## ◆ 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.

After a button is clicked, the dialog is destroyed.

Parameters

  mini_dialog | a mini-dialog
  text | the text to display on the new button
  clicked_cb | the function to call when the button is clicked
  user_data | arbitrary data to pass to clicked_cb when it is called.

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog

Returns
  the number of widgets in mini_dialog->contents.

## ◆ pidgin_mini_dialog_get_type()

GType pidgin_mini_dialog_get_type | ( | void |  | ) |

Get the GType of PidginMiniDialog.

## ◆ 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_description_markup() on a given dialog to enable them).

## ◆ 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.

This is a shortcut for creating the dialog with `g_object_new()` then setting each property yourself.

Returns
  a new 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.

This is a shortcut for creating the dialog with `g_object_new()` then setting each property yourself.

Returns
  a new PidginMiniDialog.

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog
  custom_icon | the pixbuf to use as a custom icon

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog
  description | the new description for mini_dialog, or `NULL` to hide the description widget.

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog
  icon_name | the Gtk stock ID of an icon, or `NULL` for no icon.

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog
  cb | the callback to invoke
  user_data | the user data to pass to the callback

## ◆ 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.

Parameters

  mini_dialog | a mini-dialog
  title | the new title for mini_dialog