mate-dialog-util

## mate-dialog-util mate-dialog-util |

## Synopsis

    #include <libmateui/libmateui.h>

    GtkWidget *         mate_ok_dialog                     (const gchar *message);
    GtkWidget *         mate_ok_dialog_parented            (const gchar *message,
                                                             GtkWindow *parent);
    GtkWidget *         mate_error_dialog                  (const gchar *error);
    GtkWidget *         mate_error_dialog_parented         (const gchar *error,
                                                             GtkWindow *parent);
    GtkWidget *         mate_warning_dialog                (const gchar *warning);
    GtkWidget *         mate_warning_dialog_parented       (const gchar *warning,
                                                             GtkWindow *parent);
    GtkWidget *         mate_question_dialog               (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data);
    GtkWidget *         mate_question_dialog_parented      (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);
    GtkWidget *         mate_question_dialog_modal         (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data);
    GtkWidget *         mate_question_dialog_modal_parented
                                                            (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);
    GtkWidget *         mate_ok_cancel_dialog              (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data);
    GtkWidget *         mate_ok_cancel_dialog_parented     (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);
    GtkWidget *         mate_ok_cancel_dialog_modal        (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data);
    GtkWidget *         mate_ok_cancel_dialog_modal_parented
                                                            (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);
    GtkWidget *         mate_request_string_dialog         (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data);
    GtkWidget *         mate_request_string_dialog_parented
                                                            (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);
    GtkWidget *         mate_request_password_dialog       (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data);
    GtkWidget *         mate_request_password_dialog_parented
                                                            (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);
    GtkWidget *         mate_request_dialog                (gboolean password,
                                                             const gchar *prompt,
                                                             const gchar *default_text,
                                                             const guint16 max_length,
                                                             MateStringCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

## Description

## Details

### mate_ok_dialog ()

    GtkWidget *         mate_ok_dialog                     (const gchar *message);

### Warning

`mate_ok_dialog` is deprecated and should not be used in newly-written code.

Creates and shows a simple message dialog.

`message` : | Message to display
Returns : | Pointer to new MATE dialog object.

### mate_ok_dialog_parented ()

    GtkWidget *         mate_ok_dialog_parented            (const gchar *message,
                                                             GtkWindow *parent);

### Warning

`mate_ok_dialog_parented` is deprecated and should not be used in newly-written code.

Creates and shows a simple message dialog.

`message` : | Message to display
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_error_dialog ()

    GtkWidget *         mate_error_dialog                  (const gchar *error);

### Warning

`mate_error_dialog` is deprecated and should not be used in newly-written code.

Creates and shows a error dialog. This is an OK dialog to display on fatally failed operations.

`error` : | Message to display
Returns : | Pointer to new MATE dialog object.

### mate_error_dialog_parented ()

    GtkWidget *         mate_error_dialog_parented         (const gchar *error,
                                                             GtkWindow *parent);

### Warning

`mate_error_dialog_parented` is deprecated and should not be used in newly-written code.

Creates and shows a error dialog. This is an OK dialog to display on fatally failed operations.

`error` : | Message to display
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_warning_dialog ()

    GtkWidget *         mate_warning_dialog                (const gchar *warning);

### Warning

`mate_warning_dialog` is deprecated and should not be used in newly-written code.

Creates and shows a warning dialog. For non-fatal warnings.

`warning` : | Message to display
Returns : | Pointer to new MATE dialog object.

### mate_warning_dialog_parented ()

    GtkWidget *         mate_warning_dialog_parented       (const gchar *warning,
                                                             GtkWindow *parent);

### Warning

`mate_warning_dialog_parented` is deprecated and should not be used in newly-written code.

Creates and shows a warning dialog. For non-fatal warnings.

`warning` : | Message to display
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_question_dialog ()

    GtkWidget *         mate_question_dialog               (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data);

### Warning

`mate_question_dialog` is deprecated and should not be used in newly-written code.

Creates a question dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'Yes', 1 for 'No'

void (* MateReplyCallback)(gint reply, gpointer data);

`question` : | Question to ask
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
Returns : | Pointer to new MATE dialog object.

### mate_question_dialog_parented ()

    GtkWidget *         mate_question_dialog_parented      (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_question_dialog_parented` is deprecated and should not be used in newly-written code.

Creates a question dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'Yes', 1 for 'No'

void (* MateReplyCallback)(gint reply, gpointer data);

`question` : | Question to ask
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_question_dialog_modal ()

    GtkWidget *         mate_question_dialog_modal         (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data);

### Warning

`mate_question_dialog_modal` is deprecated and should not be used in newly-written code.

Creates a question dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'Yes', 1 for 'No'. The dialog is created as a modal dialog and the user will have to answer this before proceeding.

void (* MateReplyCallback)(gint reply, gpointer data);

`question` : | Question to ask
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
Returns : | Pointer to new MATE dialog object.

### mate_question_dialog_modal_parented ()

    GtkWidget *         mate_question_dialog_modal_parented
                                                            (const gchar *question,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_question_dialog_modal_parented` is deprecated and should not be used in newly-written code.

Creates a question dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'Yes', 1 for 'No'. The dialog is created as a modal dialog and the user will have to answer this before proceeding.

void (* MateReplyCallback)(gint reply, gpointer data);

`question` : | Question to ask
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_ok_cancel_dialog ()

    GtkWidget *         mate_ok_cancel_dialog              (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data);

### Warning

`mate_ok_cancel_dialog` is deprecated and should not be used in newly-written code.

Creates an OK/Cancel dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'OK', 1 for 'Cancel'.

void (* MateReplyCallback)(gint reply, gpointer data);

`message` : | Message to display
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
Returns : | Pointer to new MATE dialog object.

### mate_ok_cancel_dialog_parented ()

    GtkWidget *         mate_ok_cancel_dialog_parented     (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_ok_cancel_dialog_parented` is deprecated and should not be used in newly-written code.

Creates an OK/Cancel dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'OK', 1 for 'Cancel'.

void (* MateReplyCallback)(gint reply, gpointer data);

`message` : | Message to display
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_ok_cancel_dialog_modal ()

    GtkWidget *         mate_ok_cancel_dialog_modal        (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data);

### Warning

`mate_ok_cancel_dialog_modal` is deprecated and should not be used in newly-written code.

Creates an OK/Cancel dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'OK', 1 for 'Cancel'. The dialog is created as a modal dialog and the user will have to answer this before proceeding.

void (* MateReplyCallback)(gint reply, gpointer data);

`message` : | Message to display
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
Returns : | Pointer to new MATE dialog object.

### mate_ok_cancel_dialog_modal_parented ()

    GtkWidget *         mate_ok_cancel_dialog_modal_parented
                                                            (const gchar *message,
                                                             MateReplyCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_ok_cancel_dialog_modal_parented` is deprecated and should not be used in newly-written code.

Creates and shows an OK/Cancel dialog and calls `callback` when user answers the button number is passed onto 'reply'. 0 is for 'OK', 1 for 'Cancel'. The dialog is created as a modal dialog and the user will have to answer this before proceeding.

void (* MateReplyCallback)(gint reply, gpointer data);

`message` : | Message to display
`callback` : | Callback function for handling dialog results
`data` : | Data to pass to callback
`parent` : | Parent window
Returns : | Pointer to new MATE dialog object.

### mate_request_string_dialog ()

    GtkWidget *         mate_request_string_dialog         (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data);

### Warning

`mate_request_string_dialog` is deprecated and should not be used in newly-written code.

Deprecated, use mate_request_dialog

Returns : |

### mate_request_string_dialog_parented ()

    GtkWidget *         mate_request_string_dialog_parented
                                                            (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_request_string_dialog_parented` is deprecated and should not be used in newly-written code.

Deprecated, use mate_request_dialog

Returns : |

### mate_request_password_dialog ()

    GtkWidget *         mate_request_password_dialog       (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data);

### Warning

`mate_request_password_dialog` is deprecated and should not be used in newly-written code.

Deprecated, use mate_request_dialog instead.

Returns : |

### mate_request_password_dialog_parented ()

    GtkWidget *         mate_request_password_dialog_parented
                                                            (const gchar *prompt,
                                                             MateStringCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_request_password_dialog_parented` is deprecated and should not be used in newly-written code.

Deprecated, use mate_request_dialog.

Returns : |

### mate_request_dialog ()

    GtkWidget *         mate_request_dialog                (gboolean password,
                                                             const gchar *prompt,
                                                             const gchar *default_text,
                                                             const guint16 max_length,
                                                             MateStringCallback callback,
                                                             gpointer data,
                                                             GtkWindow *parent);

### Warning

`mate_request_dialog` is deprecated and should not be used in newly-written code.

Creates and shows a MATE text entry request dialog. `callback` is called when the dialog closes, passing the text entry input or `NULL` if the user cancelled. `callback` is defined as

void (* MateStringCallback)(gchar * string, gpointer data);

`password` : | `TRUE` if on-screen text input is masked
`prompt` : | Text of the prompt to be displayed
`default_text` : | Default text in entry widget, `NULL` if none
`max_length` : | Maximum input chars allowed
`callback` : | Callback function for handling dialog results
`data` : | Data passed to the callback
`parent` : | Parent window, or `NULL` for no parent.
Returns : | Pointer to new MATE dialog object.