[pygtk] how to call a method of GtkWidget by using object of GtkWindow

varun_shrivastava varun.celunite at gmail.com
Mon Aug 27 18:21:06 WST 2007




varun_shrivastava wrote:
> 
> 
> Gian Mario Tagliaretti-3 wrote:
>> 
>> 2007/8/21, varun_shrivastava <shrivastavavarun at yahoo.co.in>:
>> 
>>> GtkVBox --> GtkMyDisplayable ---> GtkMyForm
>>>
>>> GtkMyDisplayable has an api
>>> gtk_my_displayable_add_command(GtkMyDisplayable
>>> *displayable, gchar *string)
>>> so i do following
>>> >>> form = mygtk.MyForm()
>>> >>>form.displayable_add_command("_____")
>>> it displays following error
>>> "form has no attribute displayable_add_command"
>> 
>> As far as I understand the method in your base class is not inherited
>> as it should, but again nobody can tell why without seeing the whole
>> picture, unless I'm missing something of course.
>> 
>> 
>> i have made the module using steps given in "extending python.pdf"
>> documentation from www.python.org
>> so have i done a mistake in writing the mygtkmodule.c file or not using
>> the cedegen scripts properly.
>> Or i there something i m missing to tell codegen scripts to auto
>> recognize the inheritance.
>> 
>> when i type command 
>>  gtkmywrap.c: gtkmy.defs gtkmy.override
>>           pygtk-codegen-2.0 --prefix pygtkmy \
>>               --override gtkmy.override \
>>              --register $(DEFS)/gtk-types.defs \
>>               --register $(DEFS)/gdk-types.defs \
>>               --register $(DEFS)/pango-types.defs \
>>               gtkmy.defs > $@ 
>> 
>> i get this as output
>> ***INFO*** The coverage of global functions is 94.12% (16/17)
>> ***INFO*** The coverage of methods is 98.60% (212/215)
>> ***INFO*** There are no declared virtual proxies.
>> ***INFO*** There are no declared virtual accessors.
>> ***INFO*** There are no declared interface proxies.
>> 
>> 
>> 
>> cheers
>> -- 
>> Gian Mario Tagliaretti
>> _______________________________________________
>> pygtk mailing list   pygtk at daa.com.au
>> http://www.daa.com.au/mailman/listinfo/pygtk
>> Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/how-to-call-a-method-of-GtkWidget-by-using-object-of-GtkWindow-tf4298164.html#a12344541
Sent from the Gtk+ - Python mailing list archive at Nabble.com.



More information about the pygtk mailing list