Selecting the region in GtkFileSelection



Hi,

I have created a GtkFileSelection, set the filename
and want the filename region to be selected. Here's
what I am doing:

GtkWidget *a = gtk_file_selection_new("Hmmm");
gtk_file_selection_set_filename(GTK_FILE_SELECTION(a),"TestFile");
GtkWidget *ase =
(GTK_FILE_SELECTION(a))->selection_entry;
gtk_entry_set_text(GTK_ENTRY(ase),"Hope");
gtk_editable_select_region(GTK_EDITABLE(ase),0,-1);
gtk_widget_show(ase);
gtk_widget_show(a);

But this doesn't work. Any ideas what's wrong here and
how to get the filename region selected?
(I am using GTK 2.0.9)

Thanks
-Pramod


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



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