[clutter] clutter_actor_get_size return wrong size

2010-04-13 Thread Sergey K
Hello!

After creating ClutterStage I trying get his size and clutter_actor_get_size 
return wrong 640x480 (i have 1280x800)

My code:

stage = clutter_stage_get_default();
clutter_stage_set_color (CLUTTER_STAGE (stage), stage_color);
clutter_stage_set_fullscreen (CLUTTER_STAGE(stage),TRUE);
gfloat width, height;
clutter_actor_get_size(stage, width, height);

What wrong with this? Some time ago it worked.

In other place i get parren stage of actor (clutter_actor_get_stage) and  
clutter_actor_get_size return correct size..


--
ps sorry for my english
-- 
To unsubscribe send a mail to clutter+unsubscr...@o-hand.com



Re: [clutter] clutter_actor_get_size return wrong size

2010-04-13 Thread Emmanuele Bassi
On Tue, 2010-04-13 at 15:14 +0400, Sergey K wrote:

 My code:
 
 stage = clutter_stage_get_default();
 clutter_stage_set_color (CLUTTER_STAGE (stage), stage_color);
 clutter_stage_set_fullscreen (CLUTTER_STAGE(stage),TRUE);
 gfloat width, height;
 clutter_actor_get_size(stage, width, height);
 
 What wrong with this? Some time ago it worked.

set_fullscreen() is an inherently asynchronous operation on x11; this
makes querying the size immediately after calling set_fullscreen(TRUE)
not possible - you have to wait the main loop to spin and the stage
window to receive an event back from the windowing system. the fact that
it worked before it was most likely the result of a bug in our previous
implementation, which also resulted in the Stage not getting the correct
size all the time.

yes, it's an implementation detail that leaked through; yes, it should
be documented.

ciao,
 Emmanuele.

-- 
Emmanuele Bassi, Open Source Software Engineer
Intel Open Source Technology Center

-- 
To unsubscribe send a mail to clutter+unsubscr...@o-hand.com