[Gtk-sharp-list] CellRendererPixBuf with toggle event?

Christian Hoff christian_hoff at gmx.net
Wed Feb 11 13:31:17 EST 2009


Hey,

I have attached a small cell renderer which overrides Render and simply 
paints a red rectangle(but you will have to change the file to override 
Render, not OnRender).

If you need a click event, you have to override OnActivate, which isn't 
supported yet. I'm working on a patch to implement that and will write a 
mail to the list when I'm done.

Christian

Jir(í Zárevúcký wrote:
> There are some methods for drawing in Gdk.Drawable (parent class of
> Gdk.Window, which is passed as a parameter to the Render method).
>
> 2009/2/11 dabatla <dabatla at gmail.com>:
>   
>> Hi, I would like to create CellRendererPixBuf -like cell renderer, but I also
>> need a click/toggle event on it. I believe the way to proceed is to device
>> from CellRendererToggle and then just to override the Render(..) method, but
>> my problem is that I have no clue on how to render the icon or stock item i
>> need in there.
>>
>> I'm sure there is a simple way, it just seems that I can't figure it out :-(
>>
>> please help
>> --
>> View this message in context: http://www.nabble.com/CellRendererPixBuf-with-toggle-event--tp21954953p21954953.html
>> Sent from the Mono - Gtk# mailing list archive at Nabble.com.
>>
>> _______________________________________________
>> Gtk-sharp-list maillist  -  Gtk-sharp-list at lists.ximian.com
>> http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
>>
>>     
> _______________________________________________
> Gtk-sharp-list maillist  -  Gtk-sharp-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
>
>   

-------------- next part --------------
A non-text attachment was scrubbed...
Name: TestRenderer.cs
Type: text/x-csharp
Size: 1877 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/gtk-sharp-list/attachments/20090211/8add0235/attachment.bin 


More information about the Gtk-sharp-list mailing list