I wrote a program but have a problem. When I execute it, the main program 
doesn't appear, then when I pressed 's'( or whatever on the keyboard ) and 
press enter the file selection box( for open file ) appear with the main 
program. Then I get an error message that said;

/etc/gtk/gtkrc:1: error: unexpected character 's', expected keyword - e.g. 
'style'


This is the process from executing until error message.

$ ./program
s
/etc/gtk/gtkrc:1: error: unexpected character 's', expected keyword - e.g. 
'style'


I wrote a function to open file using gtk_file_selection_new( ) and the 
function look like this;

GtkWidget *open_file_window;
void open_file()
{
  open_file_window = gtk_file_selection_new( "Open_File" );

  gtk_signal_connect( GTK_OBJECT( open_file_window ), "destroy",
                          ( GtkSignalFunc ) delete_event, &open_file_window 
);
  gtk_signal_connect( GTK_OBJECT( GTK_FILE_SELECTION( open_file_window )->
                             ok_button ), "clicked", ( GtkSignalFunc ) 
open_file_ok,
                             open_file_window );
  gtk_signal_connect_object( GTK_OBJECT( GTK_FILE_SELECTION
                                    ( open_file_window )->cancel_button ), 
"clicked",
                                    ( GtkSignalFunc ) gtk_widget_destroy,
                                      GTK_OBJECT( open_file_window ) );

  gtk_widget_show( open_file_window );
}


The program works fine when I delete gtk_widget_show( open_file_window ) or 
the whole open_file() function. I'm not using glade and I don't know if this 
problem have something to do with other functions. I hope what I wrote here 
will enough.

Thanks for helping.

Beginner.

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


_______________________________________________
gtk-list mailing list
[EMAIL PROTECTED]
http://mail.gnome.org/mailman/listinfo/gtk-list

Reply via email to