rsvg_processing_instruction (void *ctx, const xmlChar * target, const xmlChar * data)
{
    /* http://www.w3.org/TR/xml-stylesheet/ */
    RsvgHandle *handle = (RsvgHandle *) ctx;

    if (!strcmp ((const char *) target, "xml-stylesheet")) {
        RsvgPropertyBag *atts;
        char **xml_atts;

        xml_atts = rsvg_css_parse_xml_attribute_string ((const char *) data);
        atts = rsvg_property_bag_new ((const char **) xml_atts);

        if (atts) {
            const char *value;

            value = rsvg_property_bag_lookup (atts, "alternate");
            if (!value || (strcmp (value, "no") != 0)) {
                value = rsvg_property_bag_lookup (atts, "type");
                if (value && strcmp (value, "text/css") == 0) {
                    value = rsvg_property_bag_lookup (atts, "href");
                    if (value) {
                        GByteArray *style;

                        style =
                            _rsvg_acquire_xlink_href_resource (value,
                                                               rsvg_handle_get_base_uri (handle),
                                                               NULL);
                        if (style) {
                            rsvg_parse_cssbuffer (handle, (char *) style->data, style->len);
                            g_byte_array_free (style, TRUE);
                        }
                    }
                }
            }

            g_strfreev (xml_atts);
            rsvg_property_bag_free (atts);
        }
    }
}
rsvg_processing_instruction (void *ctx, const xmlChar * target, const xmlChar * data)
{
     
    RsvgHandle *handle = (RsvgHandle *) ctx;

    if (!strcmp ((const char *) target, "xml-stylesheet")) {
        RsvgPropertyBag *atts;
        char **xml_atts;

        xml_atts = rsvg_css_parse_xml_attribute_string ((const char *) data);
        atts = rsvg_property_bag_new ((const char **) xml_atts);

        if (atts) {
            const char *value;

            value = rsvg_property_bag_lookup (atts, "alternate");
            if (!value || (strcmp (value, "no") != 0)) {
                value = rsvg_property_bag_lookup (atts, "type");
                if (value && strcmp (value, "text/css") == 0) {
                    value = rsvg_property_bag_lookup (atts, "href");
                    if (value) {
                        GByteArray *style;

                        style =
                            _rsvg_acquire_xlink_href_resource (value,
                                                               rsvg_handle_get_base_uri (handle),
                                                               NULL);
                        if (style) {
                            rsvg_parse_cssbuffer (handle, (char *) style->data, style->len);
                            g_byte_array_free (style, TRUE);
                        }
                    }
                }
            }

            g_strfreev (xml_atts);
            rsvg_property_bag_free (atts);
        }
    }
}