## GOSearchReplace GOSearchReplace |

## Synopsis

                        GOSearchReplace;
    gboolean            go_search_match_string              (GOSearchReplace *sr,
                                                             const char *src);
    GQuark              go_search_replace_error_quark       (void);
    char *              go_search_replace_string            (GOSearchReplace *sr,
                                                             const char *src);
    gboolean            go_search_replace_verify            (GOSearchReplace *sr,
                                                             gboolean repl,
                                                             GError **err);

## Object Hierarchy

      GObject
       +----GOSearchReplace

## Properties

      "ignore-case"              gboolean              : Read / Write
      "is-regexp"                gboolean              : Read / Write
      "match-words"              gboolean              : Read / Write
      "preserve-case"            gboolean              : Read / Write
      "replace-text"             gchar*                : Read / Write
      "search-text"              gchar*                : Read / Write

## Description

## Details

### GOSearchReplace

    typedef struct {
    	char *search_text;
    	char *replace_text;

    	GORegexp *comp_search;
    	gboolean is_regexp; /* Search text is a regular expression.  */
    	gboolean ignore_case; /* Consider "a" and "A" the same.  */
    	gboolean preserve_case; /* Like Emacs' case-replace.  */
    	gboolean match_words; /* Like grep -w.  */
    } GOSearchReplace;

char *`search_text`; | string to replace.
char *`replace_text`; | string to use as replacement/
GORegexp *`comp_search`; | GORegexp
gboolean `is_regexp`; | search text is a regular expression.
gboolean `ignore_case`; | consider "a" and "A" the same.
gboolean `preserve_case`; | like Emacs' case-replace.
gboolean `match_words`; | like grep -w.

### go_search_match_string ()

    gboolean            go_search_match_string              (GOSearchReplace *sr,
                                                             const char *src);

### go_search_replace_error_quark ()

    GQuark              go_search_replace_error_quark       (void);

### go_search_replace_string ()

    char *              go_search_replace_string            (GOSearchReplace *sr,
                                                             const char *src);

### go_search_replace_verify ()

    gboolean            go_search_replace_verify            (GOSearchReplace *sr,
                                                             gboolean repl,
                                                             GError **err);

`sr` : | Search-and-Replace info to be checked
`repl` : | Check replacement part too.
`err` : | Location to store error message.
Returns : | `TRUE` if search-and-replace data is valid.

## Property Details

### The `"ignore-case"` property

      "ignore-case"              gboolean              : Read / Write

Ignore the case of letters.

Default value: FALSE

### The `"is-regexp"` property

      "is-regexp"                gboolean              : Read / Write

Is the search text a regular expression.

Default value: FALSE

### The `"match-words"` property

      "match-words"              gboolean              : Read / Write

Match whole words only.

Default value: FALSE

### The `"preserve-case"` property

      "preserve-case"            gboolean              : Read / Write

Preserve the case of letters.

Default value: FALSE

### The `"replace-text"` property

      "replace-text"             gchar*                : Read / Write

The text to replace with.

Default value: NULL

### The `"search-text"` property

      "search-text"              gchar*                : Read / Write

The text to search for.

Default value: NULL