
// gcc -o test test.c  `pkg-config --libs --cflags clutter-gtk-1.0`

#include <clutter/clutter.h>

#define CONTROLS_MARGIN 32.0                   /* Pixels from the bottom, left and right */

int main (int argc, char **argv)
{
	ClutterActor *child, *layout, *stage;
	ClutterConstraint *constraint;

	clutter_init (&argc, &argv);

	stage = clutter_stage_new ();
	clutter_actor_set_size (stage, 1.0, 1.0);

	child = clutter_actor_new ();
	layout = g_object_new (CLUTTER_TYPE_ACTOR,
			       "layout-manager", clutter_bin_layout_new (CLUTTER_BIN_ALIGNMENT_CENTER, CLUTTER_BIN_ALIGNMENT_END),
			       NULL);
	clutter_actor_add_child (layout, child);

	constraint = clutter_bind_constraint_new (stage, CLUTTER_BIND_SIZE, 0.0);
	clutter_actor_add_constraint_with_name (layout, "size", constraint);

	clutter_actor_add_child (stage, layout);
	g_object_set (G_OBJECT (child),
		      "margin-bottom", CONTROLS_MARGIN,
		      "margin-left", CONTROLS_MARGIN,
		      "margin-right", CONTROLS_MARGIN,
		      NULL);

	clutter_actor_show (stage);

	clutter_main ();

	return 0;
}
