gtk-css-engine r156 - in trunk: . libccss/cccss libccss/ccss src



Author: robsta
Date: Thu Oct  2 15:14:31 2008
New Revision: 156
URL: http://svn.gnome.org/viewvc/gtk-css-engine?rev=156&view=rev

Log:
* libccss/cccss/Makefile.am:
* libccss/cccss/example-1.c:
* libccss/cccss/cccss.c (added):
* libccss/cccss/example-2.css (added):
* libccss/cccss/foo.svg (added):
* libccss/cccss/cccss.h (added):
* libccss/cccss/example-2.c (added):
Add clutter example that involves node usage.

* libccss/ccss/ccss-parser.c: create ID selectors for IDs.

* src/gce-serialize.c: fill all node vtable fields.



Added:
   trunk/libccss/cccss/cccss.c
   trunk/libccss/cccss/cccss.h
   trunk/libccss/cccss/example-2.c
   trunk/libccss/cccss/example-2.css
   trunk/libccss/cccss/foo.svg
Modified:
   trunk/ChangeLog
   trunk/libccss/cccss/Makefile.am
   trunk/libccss/cccss/example-1.c
   trunk/libccss/ccss/ccss-parser.c
   trunk/src/gce-serialize.c

Modified: trunk/libccss/cccss/Makefile.am
==============================================================================
--- trunk/libccss/cccss/Makefile.am	(original)
+++ trunk/libccss/cccss/Makefile.am	Thu Oct  2 15:14:31 2008
@@ -4,11 +4,29 @@
 	-I$(top_srcdir)/libccss \
 	-I$(top_builddir)/libccss
 
-LDADD = \
+noinst_LTLIBRARIES = libcccss.la
+
+libcccss_la_LIBADD = \
 	$(CCSS_LIBS) \
 	./../ccss/libccss-1.la
 
-noinst_PROGRAMS = example-1
+libcccss_la_SOURCES = \
+	cccss.c \
+	cccss.h
+
+LDADD = \
+	$(libcccss_la_LIBADD) \
+	./libcccss.la
+
+noinst_PROGRAMS = \
+	example-1 \
+	example-2
 
 example_1_SOURCES = example-1.c
 
+example_2_SOURCES = example-2.c
+
+EXTRA_DIST = \
+	example-1.css \
+	example-2.css
+

Added: trunk/libccss/cccss/cccss.c
==============================================================================
--- (empty file)
+++ trunk/libccss/cccss/cccss.c	Thu Oct  2 15:14:31 2008
@@ -0,0 +1,87 @@
+/* The Clutter Cairo CSS Drawing Library.
+ * Copyright (C) 2008 Robert Staudinger
+ *
+ * This  library is free  software; you can  redistribute it and/or
+ * modify it  under  the terms  of the  GNU Lesser  General  Public
+ * License  as published  by the Free  Software  Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed  in the hope that it will be useful,
+ * but  WITHOUT ANY WARRANTY; without even  the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License  along  with  this library;  if not,  write to  the Free
+ * Software Foundation, Inc., 51  Franklin St, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+
+#include "cccss.h"
+
+typedef struct {
+	ccss_node_t	 parent;
+	ClutterActor	*actor;
+} Node;
+
+static char const *
+get_type (Node const *self)
+{
+	/* Here we could match against different kinds of actors. */
+	return "actor";
+}
+
+static char const *
+get_id (Node const *self)
+{
+	return clutter_actor_get_name (self->actor);
+}
+
+static ccss_node_class_t _node_class = {
+	.is_a			= NULL,
+	.get_container		= NULL,
+	.get_base_style		= NULL,
+	.get_id			= (ccss_node_get_id_f) get_id,
+	.get_type		= (ccss_node_get_type_f) get_type,
+	.get_class		= NULL,
+	.get_pseudo_class	= NULL,
+	.get_attribute		= NULL,
+	.get_viewport		= NULL,
+	.release		= NULL
+};
+
+gboolean
+cccss_paint (ccss_stylesheet_t const	*stylesheet,
+	     ClutterCairo		*actor,
+	     gint			 x,
+	     gint			 y,
+	     gint			 width,
+	     gint			 height)
+{
+	cairo_t			*cr;
+	ccss_style_t		 style;
+	Node			 node;
+	gboolean		 ret;
+
+	g_return_val_if_fail (stylesheet && actor, FALSE);
+
+	ccss_node_init ((ccss_node_t *) &node, &_node_class);
+	node.actor = CLUTTER_ACTOR (actor);
+
+	ccss_style_init (&style);
+	ret = ccss_stylesheet_query_apply (stylesheet,
+					   (ccss_node_t const *) &node, &style);
+	if (!ret) {
+		g_warning ("No styling information for %s#%s", 
+				"actor", 
+				clutter_actor_get_name (CLUTTER_ACTOR (actor)));
+		return FALSE;
+	}
+
+	cr = clutter_cairo_create (actor);
+	ccss_style_draw_rectangle (&style, cr, x, y, width, height);
+	cairo_destroy (cr);
+
+	return TRUE;
+}
+

Added: trunk/libccss/cccss/cccss.h
==============================================================================
--- (empty file)
+++ trunk/libccss/cccss/cccss.h	Thu Oct  2 15:14:31 2008
@@ -0,0 +1,30 @@
+/* The Clutter Cairo CSS Drawing Library.
+ * Copyright (C) 2008 Robert Staudinger
+ *
+ * This  library is free  software; you can  redistribute it and/or
+ * modify it  under  the terms  of the  GNU Lesser  General  Public
+ * License  as published  by the Free  Software  Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed  in the hope that it will be useful,
+ * but  WITHOUT ANY WARRANTY; without even  the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License  along  with  this library;  if not,  write to  the Free
+ * Software Foundation, Inc., 51  Franklin St, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+
+#ifndef CCCSS_H
+#define CCCSS_H
+
+#include <ccss/ccss.h>
+#include <clutter-cairo/clutter-cairo.h>
+
+gboolean cccss_paint (ccss_stylesheet_t const *stylesheet, ClutterCairo *actor,
+		      gint x, gint y, gint width, gint height);
+
+#endif /* CCCSS_H */
+

Modified: trunk/libccss/cccss/example-1.c
==============================================================================
--- trunk/libccss/cccss/example-1.c	(original)
+++ trunk/libccss/cccss/example-1.c	Thu Oct  2 15:14:31 2008
@@ -24,18 +24,14 @@
 
 static void
 paint_css (ccss_stylesheet_t	*stylesheet,
-	   cairo_t		*cr)
+	   cairo_t		*cr,
+	   int			 x,
+	   int			 y,
+	   int			 width,
+	   int			 height)
 {
 	ccss_selector_group_t const	*group;
 	ccss_style_t			 style;
-	cairo_surface_t			*surface;
-	int				 width;
-	int				 height;
-
-	/* We want to cover the whole actor. */
-	surface = cairo_get_target (cr);
-	width = cairo_image_surface_get_width (surface);
-	height = cairo_image_surface_get_height (surface);
 
 	/* Query the stylesheet for the type to be drawn. */
 	group = ccss_stylesheet_query_type (stylesheet, "foo");
@@ -46,7 +42,7 @@
 	ccss_selector_group_apply (group, &style);
 
 	/* Draw the style covering the actor. */
-	ccss_style_draw_rectangle (&style, cr, 0, 0, width, height);
+	ccss_style_draw_rectangle (&style, cr, x, y, width, height);
 }
 
 int
@@ -70,11 +66,11 @@
 	clutter_stage_set_color (CLUTTER_STAGE (stage), &stage_color);
 
 	actor = clutter_cairo_new (150, 30);
-	clutter_actor_set_position (actor, 50, 20);
+	clutter_actor_set_position (actor, 35, 35);
 	clutter_container_add_actor (CLUTTER_CONTAINER (stage), actor);
 
 	cr = clutter_cairo_create (CLUTTER_CAIRO (actor));
-	paint_css (stylesheet, cr);
+	paint_css (stylesheet, cr, 0, 0, 150, 30);
 	cairo_destroy (cr);
 
 	clutter_actor_show (actor);

Added: trunk/libccss/cccss/example-2.c
==============================================================================
--- (empty file)
+++ trunk/libccss/cccss/example-2.c	Thu Oct  2 15:14:31 2008
@@ -0,0 +1,95 @@
+/* The Cairo CSS Drawing Library.
+ * Copyright (C) 2008 Robert Staudinger
+ *
+ * This  library is free  software; you can  redistribute it and/or
+ * modify it  under  the terms  of the  GNU Lesser  General  Public
+ * License  as published  by the Free  Software  Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed  in the hope that it will be useful,
+ * but  WITHOUT ANY WARRANTY; without even  the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License  along  with  this library;  if not,  write to  the Free
+ * Software Foundation, Inc., 51  Franklin St, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+
+#include <stdlib.h>
+#include <cccss/cccss.h>
+#include <clutter/clutter.h>
+
+/* FIXME put your prefix here or fix the `url' functin below to resolve it. */
+#define PREFIX "/home/rstaudinger/Desktop/Devel/gtk-css-engine-build/libccss/cccss"
+
+/* Implementation of the CSS url() function. */
+static char *
+url (GSList const *args)
+{
+	g_return_val_if_fail (args, NULL);
+
+	/* The file references from the stylesheet has to be in the current dir.
+	 * Admittedly handling relative paths like this is, well, ... */
+	return g_strdup_printf ("file://%s/%s", PREFIX, (char *) args->data);
+}
+
+/* Dispatch table of CSS function implementations. */
+static ccss_function_t const _functions[] = 
+{
+	{ "url", url },
+	{ NULL }
+};
+
+static void
+create_actor (ccss_stylesheet_t	const	*stylesheet,
+	      ClutterActor		*stage,
+	      const char		*name,
+	      gint			 x,
+	      gint			 y)
+{
+	ClutterActor		*actor;
+
+	actor = clutter_cairo_new (150, 30);
+	clutter_actor_set_position (actor, x, y);
+	clutter_container_add_actor (CLUTTER_CONTAINER (stage), actor);
+	clutter_actor_show (actor);
+	/* Set name tag and paint. */
+	clutter_actor_set_name (actor, name);
+	cccss_paint (stylesheet, CLUTTER_CAIRO (actor), 0, 0, 150, 30);
+}
+
+int
+main (int	  argc,
+      char	**argv)
+{
+	ClutterActor		*stage;
+	ClutterActor		*actor;
+	ccss_stylesheet_t	*stylesheet;
+	ClutterColor		 stage_color = { 0x00, 0x00, 0x00, 0xff };
+	const char 		*names[] = { "foo", "bar", "baz", "qux", "mos" };
+
+	clutter_init (&argc, &argv);
+
+	/* Load the stylesheet. */
+	ccss_init (_functions);
+	stylesheet = ccss_stylesheet_new_from_file ("example-2.css");
+	/* ccss_stylesheet_dump (stylesheet); */
+
+	stage = clutter_stage_get_default ();
+	clutter_actor_set_size (stage, 480, 320);
+	clutter_stage_set_color (CLUTTER_STAGE (stage), &stage_color);
+
+	for (guint i = 0; i < G_N_ELEMENTS (names); i++) {
+		create_actor (stylesheet, stage, names[i], 35, 35 + (i * 50));
+	}
+
+	clutter_actor_show (stage);
+	clutter_main ();
+
+	ccss_stylesheet_free (stylesheet);
+	ccss_shutdown ();
+
+	return EXIT_SUCCESS;
+}

Added: trunk/libccss/cccss/example-2.css
==============================================================================
--- (empty file)
+++ trunk/libccss/cccss/example-2.css	Thu Oct  2 15:14:31 2008
@@ -0,0 +1,25 @@
+
+actor {
+	background-color: white;
+}
+
+actor#foo {
+	border: 2px solid red;
+	border-radius: 5px;
+}
+
+actor#bar {
+	background-color: yellow;
+}
+
+actor#baz {
+	background-color: green;
+	background-image: url(foo.svg);
+	background-size: 15 15;
+}
+
+actor#qux {
+	background-color: black;
+	border: 5px solid white;
+	border-radius: 50%;
+}

Added: trunk/libccss/cccss/foo.svg
==============================================================================
--- (empty file)
+++ trunk/libccss/cccss/foo.svg	Thu Oct  2 15:14:31 2008
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/";
+   xmlns:cc="http://creativecommons.org/ns#";
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#";
+   xmlns:svg="http://www.w3.org/2000/svg";
+   xmlns="http://www.w3.org/2000/svg";
+   xmlns:xlink="http://www.w3.org/1999/xlink";
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd";
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape";
+   width="306.42859"
+   height="183.57143"
+   id="svg2825"
+   sodipodi:version="0.32"
+   inkscape:version="0.46"
+   sodipodi:docname="foo.svg"
+   inkscape:output_extension="org.inkscape.output.svg.inkscape"
+   version="1.0">
+  <defs
+     id="defs2827">
+    <linearGradient
+       inkscape:collect="always"
+       id="linearGradient3409">
+      <stop
+         style="stop-color:#e3f8ce;stop-opacity:1"
+         offset="0"
+         id="stop3411" />
+      <stop
+         style="stop-color:#b9ee85;stop-opacity:0"
+         offset="1"
+         id="stop3413" />
+    </linearGradient>
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3409"
+       id="radialGradient3415"
+       cx="23.999998"
+       cy="41.053154"
+       fx="23.710209"
+       fy="43.914024"
+       r="19.499998"
+       gradientTransform="matrix(7.1609492,1.6056666e-8,0,0.4607807,203.13723,525.47839)"
+       gradientUnits="userSpaceOnUse" />
+    <inkscape:perspective
+       sodipodi:type="inkscape:persp3d"
+       inkscape:vp_x="0 : 526.18109 : 1"
+       inkscape:vp_y="0 : 1000 : 0"
+       inkscape:vp_z="744.09448 : 526.18109 : 1"
+       inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
+       id="perspective2833" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     gridtolerance="10000"
+     guidetolerance="10"
+     objecttolerance="10"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="0.35"
+     inkscape:cx="375"
+     inkscape:cy="520"
+     inkscape:document-units="px"
+     inkscape:current-layer="layer1"
+     showgrid="false"
+     inkscape:window-width="899"
+     inkscape:window-height="699"
+     inkscape:window-x="98"
+     inkscape:window-y="185" />
+  <metadata
+     id="metadata2830">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage"; />
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer"
+     id="layer1"
+     transform="translate(-58.214286,-87.719325)">
+    <rect
+       style="opacity:0.5;fill:url(#radialGradient3415);fill-opacity:1;stroke:none;stroke-width:1;stroke-linecap:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.34343435;display:inline"
+       id="rect3407"
+       width="229.12502"
+       height="24"
+       x="260.4375"
+       y="520.36218"
+       rx="1.0541872"
+       ry="1.0541872" />
+    <path
+       style="stroke-width:15;stroke-miterlimit:4;stroke-dasharray:none"
+       id="path2385"
+       d="M 55.987879,19.692674 C 62.942117,19.569781 70.043546,17.461052 76.638306,15.262374 C 82.802985,13.243142 89.1298,12.250711 95.279121,10.250447 C 100.43074,8.9036677 105.82154,8.101082 111.09804,8.958796 C 116.68364,9.7546615 122.07284,11.554492 127.35688,13.502021 C 133.14537,14.789777 138.36507,17.433516 143.71615,19.863658 C 147.85908,22.252031 151.89381,25.002796 156.34167,26.793981 C 160.34285,28.941413 163.87656,31.557103 166.96902,34.880511 C 170.06154,38.589782 172.6334,42.620331 175.09609,46.765991 C 177.08882,50.651487 179.05863,54.536604 181.09017,58.404587 C 182.86869,62.273718 184.80304,66.066667 186.78468,69.839091 C 188.83239,74.3391 190.50331,78.972188 192.52361,83.480712 C 194.14326,88.318979 195.66115,93.109443 197.85655,97.722964 C 199.76486,101.99485 201.90562,106.28025 204.55882,110.1462 C 207.11977,113.98828 209.0438,118.20159 211.39467,122.15938 C 213.61602,126.15952 215.70488,130.25927 218.65577,133.77946 C 221.216,136.99593 223.94131,140.17
 968 227.02698,142.91206 C 230.33204,146.11485 234.45097,148.15332 238.20051,150.71756 C 242.01895,152.67475 245.59855,154.91914 249.79777,155.97815 C 253.85498,158.29606 258.33188,159.03827 262.9088,159.4742 C 268.36837,159.85496 273.84579,159.82718 279.3155,159.83013 C 277.7915,161.6923 288.83397,156.09555 286.21195,157.58923 C 225.88355,191.9563 244.15602,182.11392 256.26557,174.19935 C 259.83143,171.45933 263.46317,168.48388 265.12366,164.19339 L 303.16714,145.78354 C 302.60317,151.46174 299.37743,154.91093 295.41896,158.71465 C 280.69889,170.37714 264.41076,183.78918 245.30099,184.5255 C 239.70373,184.49066 234.08683,184.48182 228.52265,183.79748 C 223.78437,183.05089 219.30401,181.68715 214.92171,179.72772 C 210.61889,178.13577 206.6207,175.83278 202.67732,173.50692 C 198.61124,170.98243 194.63935,168.30698 191.05943,165.11055 C 187.9805,162.07867 185.01935,158.89103 182.43322,155.42661 C 179.51649,151.63086 177.15036,147.46767 174.82679,143.29132 C 172.57957,139.37223 
 170.66397,135.26048 168.19616,131.46324 C 165.50758,127.36235 163.06202,123.02294 161.19213,118.48857 C 159.01772,113.84079 157.26424,109.08537 155.79541,104.17003 C 153.84596,99.733084 152.17144,95.206441 150.11496,90.816414 C 148.13177,87.044055 146.19778,83.248164 144.42113,79.37876 C 142.4256,75.572802 140.4992,71.745487 138.56175,67.91296 C 136.28471,64.054527 133.97395,60.249767 130.96569,56.901471 C 128.06261,54.126597 124.79761,51.844253 121.16318,50.108491 C 116.90343,47.936705 112.83966,45.396391 108.65328,43.088153 C 103.4638,40.648056 98.167544,38.565717 92.621814,37.065784 C 87.446325,35.518896 82.335677,33.640463 76.877273,33.430344 C 71.797375,33.554312 66.7901,34.374775 61.961397,35.994252 C 55.882641,37.716721 49.569251,38.575462 43.606462,40.756752 C 36.437715,42.653579 29.195646,44.711514 21.71547,44.593036 L 55.987879,19.692674 z"
+       transform="translate(58.214286,87.719325)" />
+    <path
+       style="stroke-width:15;stroke-miterlimit:4;stroke-dasharray:none"
+       id="path2387"
+       d="M 29.858597,182.53086 C 31.207522,176.66657 32.899823,170.89015 34.483202,165.08516 C 35.79715,160.44413 37.789189,156.07808 39.639842,151.64187 C 41.51909,147.60289 45.022755,145.23104 48.523129,142.76878 C 64.891382,134.12298 79.794891,124.13349 96.054869,116.15961 C 100.0239,114.59578 103.67668,112.37126 107.50628,110.46817 C 111.92744,109.26822 115.83649,107.1947 120.37232,106.31848 C 124.46779,104.53876 128.47262,103.054 132.26421,100.63886 C 136.9657,98.954533 141.51573,96.82642 146.32016,95.429527 C 151.53492,94.22982 156.91247,94.155525 162.23657,94.059784 C 167.9328,94.003461 173.62945,94.037521 179.32582,94.052622 C 185.04581,94.067907 190.76583,94.072121 196.48584,94.074727 C 197.43851,94.074993 198.39728,94.183218 199.34384,94.075527 C 199.38081,94.07132 203.97319,92.911346 204.05018,92.896042 C 206.8909,92.331301 209.81375,92.101196 212.69149,91.821698 C 217.54082,90.977106 223.43075,90.287546 227.93384,88.236739 C 232.29515,86.872823 236.01141,84.5523
 01 240.515,83.563861 C 256.19332,78.107446 281.18163,61.909386 218.78734,97.624778 C 222.18089,94.757389 225.93306,92.359856 229.25462,89.41072 C 232.69066,86.740033 235.69448,83.634711 238.2561,80.121556 C 241.27335,76.262021 244.04417,72.192973 246.63963,68.039612 C 249.09235,63.844209 251.65861,59.759899 253.70704,55.344755 C 255.96097,51.31871 257.36259,46.908331 259.02653,42.621496 C 260.33749,38.326929 261.70392,34.015221 263.61766,29.945824 C 264.78068,27.35452 264.2449,28.679825 265.2206,25.968125 L 303.34658,7.895718 C 302.61034,11.003669 303.04492,9.4910624 302.05425,12.436797 C 300.19686,16.420031 298.18331,20.390621 297.23147,24.71173 C 295.86615,29.281254 293.89177,33.651608 292.15849,38.081117 C 289.61914,42.17908 288.30778,47.027598 285.0878,50.760294 C 282.98951,55.384447 279.66705,59.235166 277.04572,63.572808 C 274.99623,65.851843 273.67652,68.695157 271.46139,70.847524 C 270.98295,71.312409 270.34458,71.589526 269.86062,72.048658 C 269.34209,72.540582 268.
 93525,73.138219 268.47257,73.683 C 264.82344,76.272331 261.7009,79.547232 257.89102,81.956139 C 240.69505,92.19298 225.90509,103.79252 207.10904,109.33755 C 202.93667,110.92571 198.95956,112.97481 194.60601,114.09191 C 189.43261,115.18169 184.32083,116.61788 179.01273,116.89498 C 173.50686,117.65021 168.08448,119.14134 162.48084,118.77747 C 156.75969,118.77275 151.03855,118.76423 145.31742,118.74959 C 139.64327,118.73934 133.96699,118.70392 128.29506,118.89103 C 123.13888,119.13949 117.92486,119.4809 113.04552,121.32191 C 108.45964,123.14078 103.70087,124.5837 99.442847,127.12752 C 95.39947,129.07918 91.227657,130.78371 86.892229,131.97471 C 82.702189,133.37658 78.552367,135.03152 74.569146,136.92206 C 70.841409,138.98728 66.889414,140.63583 63.107818,142.60041 C 49.116636,150.30622 23.661848,160.11126 87.93878,127.53428 C 84.347577,129.39646 81.038217,131.47323 78.156278,134.3158 C 75.573722,138.19607 74.26278,142.91335 72.555584,147.22237 C 70.402899,152.46092 69.247855,15
 8.55691 67.967787,164.0515 L 29.858597,182.53086 z"
+       transform="translate(58.214286,87.719325)" />
+  </g>
+</svg>

Modified: trunk/libccss/ccss/ccss-parser.c
==============================================================================
--- trunk/libccss/ccss/ccss-parser.c	(original)
+++ trunk/libccss/ccss/ccss-parser.c	Thu Oct  2 15:14:31 2008
@@ -81,7 +81,7 @@
 		break;
 	case ID_ADD_SELECTOR:
 		name = cr_string_peek_raw_str (cr_add_sel->content.id_name);
-		selector = ccss_pseudo_class_selector_new (name);
+		selector = ccss_id_selector_new (name);
 		break;
 	case ATTRIBUTE_ADD_SELECTOR:
 		name = cr_string_peek_raw_str (cr_add_sel->content.attr_sel->name);

Modified: trunk/src/gce-serialize.c
==============================================================================
--- trunk/src/gce-serialize.c	(original)
+++ trunk/src/gce-serialize.c	Thu Oct  2 15:14:31 2008
@@ -59,6 +59,7 @@
 	.get_class		= NULL,
 	.get_pseudo_class	= (ccss_node_get_pseudo_class_f) get_pseudo_class,
 	.get_attribute		= NULL,
+	.get_viewport		= NULL,
 	.release		= NULL
 };
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]