From: Pierre-Luc Beaudoin Date: Tue, 7 Apr 2009 03:33:59 +0000 (-0400) Subject: Have the demo use the new markers X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9ee1d218340ebec771c6d0ca994b6b33b8fe2433;p=libchamplain Have the demo use the new markers --- diff --git a/demos/launcher.c b/demos/launcher.c index b505168..0e01e09 100644 --- a/demos/launcher.c +++ b/demos/launcher.c @@ -84,13 +84,15 @@ create_marker_layer (ChamplainView *view) { ClutterActor *marker; ChamplainLayer *layer; - ClutterColor orange = { 0xf3, 0x94, 0x07, 0xbb }; - ClutterColor white = { 0xff, 0xff, 0xff, 0xff }; + //ClutterColor orange = { 0xf3, 0x94, 0x07, 0xbb }; + //ClutterColor white = { 0xff, 0xff, 0xff, 0xff }; layer = champlain_layer_new (); - marker = champlain_marker_new_with_text ("Montréal", "Airmole 14", NULL, - NULL); + marker = champlain_marker_new_with_text ("Montréal\nQuébec", + "Airmole 14", NULL, NULL); + champlain_marker_set_use_markup (CHAMPLAIN_MARKER (marker), TRUE); + markers[0] = CHAMPLAIN_BASE_MARKER (marker); champlain_base_marker_set_position (CHAMPLAIN_BASE_MARKER (marker), 45.528178, -73.563788); @@ -99,14 +101,12 @@ create_marker_layer (ChamplainView *view) g_signal_connect_after (marker, "button-release-event", G_CALLBACK (marker_button_release_cb), view); - marker = champlain_marker_new_with_text ("New York", "Sans 25", &white, - NULL); + marker = champlain_marker_new_full ("New York", "/usr/share/icons/Tangerine/24x24/actions/stock_home.png", NULL); markers[1] = CHAMPLAIN_BASE_MARKER (marker); champlain_base_marker_set_position (CHAMPLAIN_BASE_MARKER (marker), 40.77, -73.98); clutter_container_add (CLUTTER_CONTAINER (layer), marker, NULL); - marker = champlain_marker_new_with_text ("Saint-Tite-des-Caps", "Serif 12", - NULL, &orange); + marker = champlain_marker_new_with_image ("/usr/share/icons/Tangerine/24x24/actions/stock_home.png", NULL); markers[2] = CHAMPLAIN_BASE_MARKER (marker); champlain_base_marker_set_position (CHAMPLAIN_BASE_MARKER (marker), 47.130885, -70.764141);