Hi, Jianchun Zhou Try to use the next line:
/* Get the stage and set its size and color: */ ClutterActor *stage = clutter_stage_get_default (); clutter_stage_set_title (CLUTTER_STAGE (stage), "Hello World"); <--- here Good luck, Vlad Volodin p.s. by the way, I have a title from your code, it is a program name: gcc `pkg-config clutter-0.8 --libs --cflags` main.c ./a.out the title is "./a.out" 2009/5/11 Jianchun Zhou <[email protected]>: > Hi, all: > > I am new to clutter, and now I am learning programming with it. > > But when I run a program produced by the source code as below, I got a > window without titlebar: > > #include <clutter/clutter.h> > > #include <stdlib.h> > > static gboolean > on_stage_button_press (ClutterStage *stage, ClutterEvent *event, gpointer > data) > { > gint x = 0; > gint y = 0; > clutter_event_get_coords (event, &x, &y); > > > g_print ("Stage clicked at (%d, %d)\n", x, y); > > return TRUE; /* Stop further handling of this event. */ > } > > int main(int argc, char *argv[]) > { > ClutterColor stage_color = { 0x00, 0x00, 0x00, 0xff }; /* Black */ > > > clutter_init (&argc, &argv); > > /* Get the stage and set its size and color: */ > ClutterActor *stage = clutter_stage_get_default (); > clutter_actor_set_size (stage, 200, 200); > clutter_stage_set_color (CLUTTER_STAGE (stage), &stage_color); > > > /* Show the stage: */ > clutter_actor_show (stage); > > /* Connect a signal handler to handle mouse clicks and key presses on the > stage: */ > g_signal_connect (stage, "button-press-event", > G_CALLBACK (on_stage_button_press), NULL); > > > /* Start the main loop, so we can respond to events: */ > clutter_main (); > > return EXIT_SUCCESS; > > } > > And now I am wondering where is it? > > > -- > Best Regards > -- To unsubscribe send a mail to [email protected]
