pluma Reference Manual: pluma-utils

## pluma-utils pluma-utils |

## Functions

#define | GBOOLEAN_TO_POINTER()
#define | GPOINTER_TO_BOOLEAN()
#define | IS_VALID_BOOLEAN()
gboolean | pluma_utils_uri_has_writable_scheme ()
gboolean | pluma_utils_uri_has_file_scheme ()
void | pluma_utils_menu_position_under_widget ()
void | pluma_utils_menu_position_under_tree_view ()
GtkWidget * | pluma_gtk_button_new_with_stock_icon ()
GtkWidget * | pluma_dialog_add_button ()
gchar * | pluma_utils_escape_underscores ()
gchar * | pluma_utils_str_middle_truncate ()
gboolean | g_utf8_caselessnmatch ()
void | pluma_utils_set_atk_name_description ()
void | pluma_utils_set_atk_relation ()
gboolean | pluma_utils_uri_exists ()
gchar * | pluma_utils_escape_search_text ()
gchar * | pluma_utils_unescape_search_text ()
void | pluma_warning ()
gchar * | pluma_utils_make_valid_utf8 ()
gchar * | pluma_utils_uri_get_dirname ()
gchar * | pluma_utils_replace_home_dir_with_tilde ()
guint | pluma_utils_get_current_workspace ()
guint | pluma_utils_get_window_workspace ()
gboolean | pluma_utils_is_valid_uri ()
gchar * | pluma_utils_make_canonical_uri_from_shell_arg ()

## Description

## Functions

### GBOOLEAN_TO_POINTER()

    #define GBOOLEAN_TO_POINTER(i) (GINT_TO_POINTER ((i) ? 2 : 1))

### GPOINTER_TO_BOOLEAN()

    #define GPOINTER_TO_BOOLEAN(i) ((gboolean) ((GPOINTER_TO_INT(i) == 2) ? TRUE : FALSE))

### IS_VALID_BOOLEAN()

    #define IS_VALID_BOOLEAN(v) (((v == TRUE) || (v == FALSE)) ? TRUE : FALSE)

### pluma_utils_uri_has_writable_scheme ()

    gboolean
    pluma_utils_uri_has_writable_scheme (const gchar *uri);

### pluma_utils_uri_has_file_scheme ()

    gboolean
    pluma_utils_uri_has_file_scheme (const gchar *uri);

### pluma_utils_menu_position_under_widget ()

    void
    pluma_utils_menu_position_under_widget
                                   (GtkMenu *menu,
                                    gint *x,
                                    gint *y,
                                    gboolean *push_in,
                                    gpointer user_data);

### pluma_utils_menu_position_under_tree_view ()

    void
    pluma_utils_menu_position_under_tree_view
                                   (GtkMenu *menu,
                                    gint *x,
                                    gint *y,
                                    gboolean *push_in,
                                    gpointer user_data);

### pluma_gtk_button_new_with_stock_icon ()

    GtkWidget *
    pluma_gtk_button_new_with_stock_icon (const gchar *label,
                                          const gchar *stock_id);

### pluma_dialog_add_button ()

    GtkWidget *
    pluma_dialog_add_button (GtkDialog *dialog,
                             const gchar *text,
                             const gchar *stock_id,
                             gint response_id);

### pluma_utils_escape_underscores ()

    gchar *
    pluma_utils_escape_underscores (const gchar *text,
                                    gssize length);

### pluma_utils_str_middle_truncate ()

    gchar *
    pluma_utils_str_middle_truncate (const gchar *string,
                                     guint truncate_length);

### g_utf8_caselessnmatch ()

    gboolean
    g_utf8_caselessnmatch (const char *s1,
                           const char *s2,
                           gssize n1,
                           gssize n2);

### pluma_utils_set_atk_name_description ()

    void
    pluma_utils_set_atk_name_description (GtkWidget *widget,
                                          const gchar *name,
                                          const gchar *description);

#### Parameters

widget | The Gtk widget for which name/description to be set |
name | Atk name string |
description | Atk description string Description : This function sets up name and description for a specified gtk widget. |

### pluma_utils_set_atk_relation ()

    void
    pluma_utils_set_atk_relation (GtkWidget *obj1,
                                  GtkWidget *obj2,
                                  AtkRelationType rel_type);

### pluma_utils_uri_exists ()

    gboolean
    pluma_utils_uri_exists (const gchar *text_uri);

### pluma_utils_escape_search_text ()

    gchar *
    pluma_utils_escape_search_text (const gchar *text);

### pluma_utils_unescape_search_text ()

    gchar *
    pluma_utils_unescape_search_text (const gchar *text);

### pluma_warning ()

    void
    pluma_warning (GtkWindow *parent,
                   const gchar *format,
                   ...);

### pluma_utils_make_valid_utf8 ()

    gchar *
    pluma_utils_make_valid_utf8 (const char *name);

### pluma_utils_uri_get_dirname ()

    gchar *
    pluma_utils_uri_get_dirname (const char *uri);

### pluma_utils_replace_home_dir_with_tilde ()

    gchar *
    pluma_utils_replace_home_dir_with_tilde
                                   (const gchar *uri);

### pluma_utils_get_current_workspace ()

    guint
    pluma_utils_get_current_workspace (GdkScreen *screen);

### pluma_utils_get_window_workspace ()

    guint
    pluma_utils_get_window_workspace (GtkWindow *gtkwindow);

### pluma_utils_is_valid_uri ()

    gboolean
    pluma_utils_is_valid_uri (const gchar *uri);

### pluma_utils_make_canonical_uri_from_shell_arg ()

    gchar *
    pluma_utils_make_canonical_uri_from_shell_arg
                                   (const gchar *str);

## Types and Values