ClutterActor has a background-color property, now; we should use it for
the Stage, re-implement the color property in terms of background-color.
and deprecate the Stage property.
Being able to easily set the number of repeats has been a request for
the animation framework for some time now. The usual way to implement
this is: connect to the ::completed signal, use a static counter, and
stop the timeline when the counter hits a specific spot.
In the same light as the :auto-reverse property, we can make it easier
to implement this common functionality by adding a :repeat-count
property that, when set, limits the amount of loops that a Timeline can
perform before stopping itself.
In fact, we can implement the :loop property in terms of the
:repeat-count property just by using a sentinel value mapping to
"infinity", and map loop=FALSE to repeat-count=0, and loop=TRUE to
repeat-count=-1.
The clutter_timeline_clone() method was a pretty dumb idea when it was
introduced, back when we still had the ClutterEffectTemplate and the
clutter_effect_* animation API. It has since become an API wart: we
cannot change or add new properties to be cloned without the risk of
breaking existing code. All in all, cloning a GObject is just a matter
of calling g_object_new() with the wanted properties.
Let's deprecate this throwback of the Olden Days™, so that we can remove
it for good once we break for 2.0.
When the ClutterTextBuffer support inside ClutterText was merged, it
introduced a regression that was identified and fixed in bug 659116.
The optimization to not paint empty ClutterText actors is only valid
is the actor is not editable, or if the cursor is not visible.
Courtesy of GLib and GTK+. The abicheck.sh is a simple, Linux-only,
script to check that we're not leaking private symbols, or that the
clutter.symbols file hasn't been updated.
In theory, it should go inside the distcheck phase.
A bunch of private symbols have escaped into the SO; let's rectify this
situation by using the '_' private prefix, or making them static as they
should have been.
ClutterActor should be emitting signals defined on the ClutterContainer
interface, as well as ensuring that manipulating the scene graph is
still possible from within them.
The new unit checks that we're emitting signals, by implementing
something similar to the Bin class available in toolkits like gtk, st,
and mx — i.e. a container that can only hold one child at any given
point.
Cogl now requires that all applications integrate their main loop with
Cogl so that it can listen for events from winsys. This patch just
adds Cogl's GSource to the main loop.
Reviewed-by: Emmanuele Bassi <ebassi@linux.intel.com>
Reviewed-by: Robert Bragg <robert@linux.intel.com>
Some of Cogl's experimental apis have changed so that the buffer apis
now need to be passed a context argument and some drawing apis have been
replaced with cogl_framebuffer_ drawing apis that take explicit
framebuffer and pipeline arguments.
These changes were made as part of Cogl moving towards a more stateless
api that doesn't rely on a global context.
This patch updates Clutter to work with the latest Cogl api and bumps
the required Cogl version to 1.9.5.
Reviewed-by: Emmanuele Bassi <ebassi@linux.intel.com>
Reviewed-by: Neil Roberts <neil@linux.intel.com>
Similar to the clutter_actor_iter_remove(), but it'll call destroy()
instead of remove_child().
We can also reimplement the ::destroy default handler using it, and make
it more compact.
There is a typo in the check for a negative index: the index variable
should be index_, not index - unfortunately, the latter can still be
resolved to index(3), so compiler and linker are perfectly happy.
https://bugzilla.gnome.org/show_bug.cgi?id=669730
An editable ClutterText will reset the selection and cursor whenever the
contents are changed — even if those contents are the same. As this may
confuse the user, we should check if we're setting the exact same string,
and bail out if necessary.
The reverse of position_to_coords().
While providing documentation on how to implement it using the
PangoLayout API, I realized that the verbosity of it all, plus the usage
of the Pango API, was not worth it, and decided to expose the method we
are using internally.
GValueArray is on its way to deprecation in GLib; as far as the
ListModel class is concerned, a plain C array of GValue is a perfectly
suitable replacement for the GValueArray usage. It actually is an
improvement, given that it's going to take less memory.