Re: [pygtk] CLI arguments
It is the gnome code that is doing this. I will be fixing this up when moving to gnome-libs-2. Currently the way to do this is to parse the arguments before importing gnome.ui, and remove all but the gnome/gtk ones. James. -- Email: [EMAIL PROTECTED] WWW: http://www.daa.com.au/~james/ On Mon, 28 Feb 2000, J.W. Bizzaro wrote: > I'm trying to parse the command-line for arguments, but when the argument is a > flag (starts with - or --), gtk catches it and (if it isn't a gtk flag) returns > > Error on option --bla: unknown option. > > How do I (1) turn off gtk's argument parsing or (2) make use of it in pygtk? > > Jeff > To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED] > To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]
Re: [pygtk] CLI arguments
Parse the arguments before gtk is imported, and remove your app-specific ones from sys.argv -- that is the only way I found that worked. --Rick On Mon, 28 Feb 2000, J.W. Bizzaro wrote: > I'm trying to parse the command-line for arguments, but when the argument is a > flag (starts with - or --), gtk catches it and (if it isn't a gtk flag) returns > > Error on option --bla: unknown option. > > How do I (1) turn off gtk's argument parsing or (2) make use of it in pygtk? > > Jeff > To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED] > To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]
[pygtk] CLI arguments
I'm trying to parse the command-line for arguments, but when the argument is a flag (starts with - or --), gtk catches it and (if it isn't a gtk flag) returns Error on option --bla: unknown option. How do I (1) turn off gtk's argument parsing or (2) make use of it in pygtk? Jeff To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]