Re: Animating widgets



El 15/01/11 08:01, Andy Tai escribiÃ:
A related question, one can assume that animation, when possible,  is to be
done with gtk+ on top of Clutter.  Then how can gtk+ programs be written to
support animation and to properly degrade on platforms where the animation
is not supported?  For example, with gtk+3, can it support, on showing a
window,  the window sliding in from the left when using Clutter, but the
window simply opens when running on top of the plain X11, all with the same
application logic?

Also, is gtk+ 3 "aware" of the animation events (such as callbacks when the
animation play is complete)?  Or such events are only handled at the Clutter
level, and gtk+ widgets know nothing of them?

2011/1/14 Erick PÃrez Castellanos<erick red gmail com>

Hi:

I want to know if there's anyway i can animate widgets with Gtk. For
instance, I have a GtkBin with a GtkEntry container and I want to changed
for a GtkTextView on certain event, and I want the switch to be animated,
slide in/out, fade in/out, things like that.
As far as I got with Gtk2 that's not possible so far, Am I right ?
Would this be possible with Gtk3 ?
If it is, can someone put in the right direction ?

Thxs
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Hi, I'll explain my experience!

Gtk2 does not support animations, it's a fact, so you can only make your own hacks to Gtk. Recently, I've done a news panel that consists in a slide in/slide out window that contains a webkit's webview inside for showing news to a user, and i did a slide in/slide out animation using some workarounds :S

Why I took this solution? I took that solution because python-clutter-gtk's Container isn't implemented yet and I needed to add a webkit's webview object to. So, Erick, if you can know more details about my 'dirty' implementation I can pass you some tips and/or chunks of code.

Andy, I don't know in Gtk3, but using clutter with Gtk2, animations' events are handled by clutter level, so i expect the same with Gtk3, but correct me if i'm wrong. Anyway, in my case, I know the basics of clutter, but I don't know how to do that an application made with Gtk/Clutter avoid animations if animation is not supported, if any listener in the list could put us in the right direction will be helpful!

Regards!

--
Javier HernÃndez<javiube gmail com>




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