2007-10-09 16:44:44 +00:00
|
|
|
{
|
|
|
|
"My Scene" : {
|
|
|
|
"id" : "main-stage",
|
|
|
|
"type" : "ClutterStage",
|
2012-03-06 14:23:33 +00:00
|
|
|
"title" : { "translatable" : true, "string" : "ClutterScript test" },
|
2007-10-09 16:44:44 +00:00
|
|
|
"color" : "white",
|
2007-11-15 15:24:43 +00:00
|
|
|
"signals" : [
|
2008-05-09 13:58:04 +00:00
|
|
|
{ "name" : "key-press-event", "handler" : "clutter_main_quit" },
|
|
|
|
{ "name" : "destroy", "handler" : "clutter_main_quit" }
|
2007-11-15 15:24:43 +00:00
|
|
|
],
|
2007-10-09 16:44:44 +00:00
|
|
|
"children" : [
|
|
|
|
{
|
|
|
|
"id" : "red-button",
|
|
|
|
"type" : "ClutterRectangle",
|
|
|
|
"color" : "#ff0000ff",
|
2007-11-14 13:36:31 +00:00
|
|
|
"x" : 50, "y" : 50, "width" : 100, "height" : 100,
|
2007-10-25 14:46:02 +00:00
|
|
|
"reactive" : true,
|
2007-12-10 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-actor.c:
(clutter_actor_set_property),
(clutter_actor_get_property),
(clutter_actor_class_init): Add the rotation-* properties,
controlling the rotation angle and center on each axis. (#614)
(parse_rotation_array), (parse_rotation),
(clutter_actor_parse_custom_node),
(clutter_actor_set_custom_property),
(clutter_scriptable_iface_init): Add a new "rotation" custom
property for expressing the rotation along each axis in a
compact way:
"rotation" : [
{ "x-axis" : [ <angle>, [ <y>, <z> ] ] },
{ "y-axis" : [ <angle>, [ <x>, <z> ] ] },
{ "z-axis" : [ <angle>, [ <x>, <y> ] ] }
]
(clutter_geometry_get_type),(clutter_vertex_get_type),
(clutter_actor_box_get_type): Use the I_() macro instead of
directly calling g_intern_static_string().
* clutter/clutter-entry.c (clutter_entry_request_coords):
* clutter/clutter-label.c (clutter_label_ensure_layout),
(clutter_label_request_coords): Use CLUTTER_UNITS_FROM_DEVICE()
instead of CLUTTER_UNITS_FROM_INT(), as "device" means "pixels".
* clutter/clutter-private.h: Add the I_() macro for intern
static strings.
* tests/test-script.json: Test the newly added "rotation"
custom property.
2007-12-10 11:01:10 +00:00
|
|
|
"rotation" : [
|
|
|
|
{ "z-axis" : [ 45.0, [ 75, 75 ] ] }
|
|
|
|
],
|
2008-05-09 13:58:04 +00:00
|
|
|
"behaviours" : [ "fade-behaviour", "path-behaviour" ]
|
2007-10-09 16:44:44 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"id" : "green-button",
|
|
|
|
"type" : "ClutterRectangle",
|
|
|
|
"color" : "#00ff00ff",
|
2007-10-27 19:49:39 +00:00
|
|
|
"border-width" : 5,
|
|
|
|
"border-color" : "#00cc00ff",
|
2012-04-01 16:54:11 +00:00
|
|
|
"position" : [ 200.0, 50.0 ],
|
|
|
|
"size" : { "width" : 100.0, "height" : 100.0 },
|
2009-08-26 15:50:37 +00:00
|
|
|
"depth" : -200.0,
|
2007-12-25 20:09:20 +00:00
|
|
|
"reactive" : true,
|
2007-11-15 15:24:43 +00:00
|
|
|
"signals" : [
|
|
|
|
{ "name" : "button-press-event", "handler" : "clutter_main_quit" }
|
|
|
|
]
|
2007-10-18 12:31:07 +00:00
|
|
|
},
|
2007-10-09 16:44:44 +00:00
|
|
|
{
|
|
|
|
"id" : "red-hand",
|
|
|
|
"type" : "ClutterTexture",
|
2008-04-25 13:37:36 +00:00
|
|
|
"filename" : "redhand.png",
|
2012-04-01 16:54:11 +00:00
|
|
|
"position" : { "x" : 100.0, "y" : 100.0 },
|
2009-08-26 15:50:37 +00:00
|
|
|
"width" : "20 mm",
|
2008-06-23 15:31:12 +00:00
|
|
|
"keep-aspect-ratio" : true,
|
2009-08-26 15:50:37 +00:00
|
|
|
"anchor-x" : "5 em",
|
|
|
|
"anchor-y" : "5 pt",
|
2007-10-09 16:44:44 +00:00
|
|
|
"opacity" : 100,
|
|
|
|
"behaviours" : [ "rotate-behaviour", "fade-behaviour" ]
|
2007-10-18 12:31:07 +00:00
|
|
|
},
|
2007-11-14 13:36:31 +00:00
|
|
|
{
|
|
|
|
"id" : "red-hand-clone",
|
2009-08-26 15:50:37 +00:00
|
|
|
"type" : "ClutterClone",
|
|
|
|
"source" : "red-hand",
|
2012-04-01 16:54:11 +00:00
|
|
|
"position" : [ 250.0, 150.0 ],
|
2010-04-09 17:22:50 +00:00
|
|
|
"opacity" : 100
|
2007-11-14 13:36:31 +00:00
|
|
|
},
|
2007-10-25 14:46:02 +00:00
|
|
|
{
|
|
|
|
"id" : "label",
|
2009-08-26 15:50:37 +00:00
|
|
|
"type" : "ClutterText",
|
2007-10-25 14:46:02 +00:00
|
|
|
"x" : 50,
|
|
|
|
"y" : 200,
|
2012-03-06 14:23:33 +00:00
|
|
|
"text" : { "translatable" : true, "string" : "Clutter Script" },
|
2007-10-25 14:46:02 +00:00
|
|
|
"font-name" : "Sans 24px",
|
|
|
|
"color" : "black",
|
2009-08-26 15:50:37 +00:00
|
|
|
"line-alignment" : "center",
|
|
|
|
"line-wrap" : false,
|
2007-10-25 14:46:02 +00:00
|
|
|
"ellipsize" : "none",
|
2007-12-10 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-actor.c:
(clutter_actor_set_property),
(clutter_actor_get_property),
(clutter_actor_class_init): Add the rotation-* properties,
controlling the rotation angle and center on each axis. (#614)
(parse_rotation_array), (parse_rotation),
(clutter_actor_parse_custom_node),
(clutter_actor_set_custom_property),
(clutter_scriptable_iface_init): Add a new "rotation" custom
property for expressing the rotation along each axis in a
compact way:
"rotation" : [
{ "x-axis" : [ <angle>, [ <y>, <z> ] ] },
{ "y-axis" : [ <angle>, [ <x>, <z> ] ] },
{ "z-axis" : [ <angle>, [ <x>, <y> ] ] }
]
(clutter_geometry_get_type),(clutter_vertex_get_type),
(clutter_actor_box_get_type): Use the I_() macro instead of
directly calling g_intern_static_string().
* clutter/clutter-entry.c (clutter_entry_request_coords):
* clutter/clutter-label.c (clutter_label_ensure_layout),
(clutter_label_request_coords): Use CLUTTER_UNITS_FROM_DEVICE()
instead of CLUTTER_UNITS_FROM_INT(), as "device" means "pixels".
* clutter/clutter-private.h: Add the I_() macro for intern
static strings.
* tests/test-script.json: Test the newly added "rotation"
custom property.
2007-12-10 11:01:10 +00:00
|
|
|
"rotation" : [
|
|
|
|
{ "y-axis" : [ 60.0, [ 275, 100 ] ] },
|
|
|
|
{ "z-axis" : [ 45.0, [ 75, 75 ] ] }
|
2007-12-25 20:09:20 +00:00
|
|
|
]
|
2008-05-28 12:20:54 +00:00
|
|
|
}
|
2007-10-09 16:44:44 +00:00
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|