Search / Replace




Before I start implimenting my own search/replace, I wanted to see if one
already exists in a generic form.  Such as:

int 
gtk_search_replace(
    GtkText *text, 
    char *search, 
    char *replace, 
    int startpos)
{

    gtk_editable_delete_text (GTK_EDITABLE (text),
                                      startpos, startpos + strlen(search));

    gtk_editable_insert_text (GTK_EDITABLE (text),
                                      replace, strlen (replace), &startpos);

}


Not just the above, but with a window and such.

Matthew



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]