From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id QFEyGaFaTWPZSwEAbAwnHQ (envelope-from ) for ; Mon, 17 Oct 2022 15:37:37 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 4HoEGaFaTWNsjgAAauVa8A (envelope-from ) for ; Mon, 17 Oct 2022 15:37:37 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 108A58F14 for ; Mon, 17 Oct 2022 15:37:37 +0200 (CEST) Received: from localhost ([::1]:60788 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1okQJD-0001vz-5F for larch@yhetil.org; Mon, 17 Oct 2022 09:37:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54792) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1okQF3-0001og-B2 for emacs-orgmode@gnu.org; Mon, 17 Oct 2022 09:33:19 -0400 Received: from mail-ed1-x534.google.com ([2a00:1450:4864:20::534]:37473) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1okQEe-00047H-MI for emacs-orgmode@gnu.org; Mon, 17 Oct 2022 09:33:01 -0400 Received: by mail-ed1-x534.google.com with SMTP id m16so16077112edc.4 for ; Mon, 17 Oct 2022 06:32:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=VYSKIOiCiH+ZmrI+psfYi8LAfqP6oaNPWVezbJ7fgPM=; b=ewnNhtsHL3FjHAMbQZXCyvhN+QmEyHMGymzVl+ybD+ht43mrN8kcUgG5tNuIxCbonw wbOQUyRaV1hydKyiCstx8DoxuCAweqJiFcK4YnQQZrIUPIv+vV5gqUJslSVNfiZouejS EhAae8NpTSK3fgFbzUdg+1305TCiHKfxK+jeHBXdL2/FQ7dhJaeNgY08flPMTIYSo980 7CRSh2cN9cMx3z4xLz4FqxCBE7roa6iQ96xv7H7DIpVTnRZIsOM6kP1gtlLUxI13VJOS 6rZRY/H/i2SxQFr9uNVJcZBHPWU4k10B6xpG4L8oVYwHDVhqhR9W00iLfNpYDqL79uWc aftA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=VYSKIOiCiH+ZmrI+psfYi8LAfqP6oaNPWVezbJ7fgPM=; b=VBVXV8VUvqaWSsG/EcZ8LV0kYIbLtmtkrPXv409urznc3S+VJGbwMx9Fk3kkOsliHe Vz8RQ1bxurQA6VHKWq8fQe1u4NfBZ6GPEq8l69x1wK0xVUsR6iPut8nSLTModV2sfx3U YvYu27ypnAwn9cF1W7rgrISSgvWALHO3yXDhiJ3iHwVIrNWQmjyPjRkbOzvyOV09i4hU bJyxiA1/vyHgk/ASZ35OLbglm8kL33bWA9YzbQ6TXtcJeihzWRq+ww8U+HQ6R6UC8GIl NQ4kFu/NbW/TxsxMq6x0aTvHQYAEtxXmBMTpjhUPdHeclGkj7ckJ9IVKE1NS/0gxXGY4 rtuA== X-Gm-Message-State: ACrzQf3xcHZ5RhmkEmj10iZU+twzrAFh7s0qwfWZ3BoKXW62zqDjuSVz Nz6ejrNZ7TZEMLya6iYdI1PCNCMBCfmRRXbX/hQ= X-Google-Smtp-Source: AMsMyM7pMCei6hoJjl00IjVt3gMM9QbgJhj963L7nL4uDp/1tVcIvxhGdxPVEOML4yhgQxHXPxpxahj6Ov+vAAkHePo= X-Received: by 2002:a05:6402:3551:b0:45d:a52f:2d77 with SMTP id f17-20020a056402355100b0045da52f2d77mr3193750edd.67.1666013569768; Mon, 17 Oct 2022 06:32:49 -0700 (PDT) MIME-Version: 1.0 References: <87o7uhp1n7.fsf@lrde.epita.fr> <875ygmzunb.fsf@localhost> In-Reply-To: <875ygmzunb.fsf@localhost> From: Chris Clark Date: Mon, 17 Oct 2022 09:32:38 -0400 Message-ID: Subject: Re: Org 9.5 broke the rendering of my SVG images To: Ihor Radchenko Cc: Alexandre Duret-Lutz , emacs-orgmode@gnu.org, tec@tecosaur.com Content-Type: multipart/alternative; boundary="0000000000000461fa05eb3b0336" Received-SPF: pass client-ip=2a00:1450:4864:20::534; envelope-from=cfclrk@gmail.com; helo=mail-ed1-x534.google.com X-Spam_score_int: -1 X-Spam_score: -0.2 X-Spam_bar: / X-Spam_report: (-0.2 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HK_RANDOM_ENVFROM=0.898, HK_RANDOM_FROM=0.999, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1666013857; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=VYSKIOiCiH+ZmrI+psfYi8LAfqP6oaNPWVezbJ7fgPM=; b=ldI6IEe2DoE4ss8Ul/au/3ac9xZ0gDSLE5g6WXl7SSG7DuROrBkfHnfQNIXC7COdVY4Qu0 0+xKerbq0YnRhlIp/MSa7EQL2WKdYSd0je1iV8YsC4U1QIYMSXkXvT3mil2tN2CdjSzB5g 5q0JgkN0wDiK1AJt3Xwwm+j2BCj2zm+alBwbGwGDt53QPAr0JygNbBtQYdgP0eEN4SvX6J 53t0ZREB1ybKGJZDJl+lWMt2DagW1MytkQ/DFe1Dk92gbpWKxfrVjeEYNve87Q5rD3ih7e nGdDiHfOKHnkA4bqnMN2UjWxcGV8KSKF6tFc05oqEwWOKTzjC5jZW6pgIJ3YnA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666013857; a=rsa-sha256; cv=none; b=d0HHF3MdXVS29jyHOoVDmU0S2Mm59B2uU6TZGC/x+n3NSfXLitfgP8by9eqkuU1Woj1lug 7cuzcVRtymXUHLUhk5aNc6Kx4LmXJZ2xy/vDQNFiQNsRXhv4m8WHrUL/rJ2XxqXl/XeMyX 6elPmHKAl02j6VPA1b1eHRTm/PBxCfC8dRApyvdl5sjULx0jxxFLoAXU5spKlEwPKnLnmr L780eWT972RKxImt7NKPwklxTlhXgsDVW6+vTvsjNkEuWHf2pFQszSf+EG0k4dEl0EWy69 UUd/7QEy5DWKE2cUoj+jlJLYDNll6k4cNytDyAW3iBQ6d7I5CMP7Sx0IVrjzkQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=ewnNhtsH; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -5.22 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=ewnNhtsH; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 108A58F14 X-Spam-Score: -5.22 X-Migadu-Scanner: scn0.migadu.com X-TUID: kT3ma/PGL6FR --0000000000000461fa05eb3b0336 Content-Type: text/plain; charset="UTF-8" Would the HTML tag be appropriate in this case? For example, here's a tiny example of using the tag with an external CSS stylesheet: https://plnkr.co/edit/i8RFDW?preview On Fri, Oct 14, 2022 at 4:32 AM Ihor Radchenko wrote: > Alexandre Duret-Lutz writes: > > > In Org 9.5, SVG images started being exported by the HTML exporter as > > rather than . > > > > The patch causing that was > > https://list.orgmode.org/87k0pemj6d.fsf@gmail.com/T/ > > with two arguments: > > 1) do not have an alt attribute > > 2) will not render some SVG file correctly if it has no viewBox > > (I'm assuming that the issue shown in that message is a missing > viewBox). > > > > The reason I've noticed this change is that it broke my web pages. On > > my pages, I use SVG to display many automata, and they all share a > > common stylesheet. That stylesheet is not inlined into the SVG, rather, > > it is a separate file included in the SVG files with > > > > so that the browser only need to download it once. > > > > Infortunately, does not allow external stylesheets to be > > processed, so my stylesheets are now ignored. Note that one can also > > build SVG images that include other SVG images, or SVG images that have > > animations that start when you hover on some elements. All those > > usages would break with . > > > > I've seen that very issue was discussed back in 2016 > > https://list.orgmode.org/871t2iq353.fsf@iki.fi/T/ > > where Christian Moe pointed out exactly this: > > > >> (2) You can also do other things with that you cannot with > >> , like manipulating the SVG with Javascript and styling it with > >> an external stylesheet (linked from the SVG, not the web page). > > > > So in the interest of allowing users to build documents where SVG > > files are not static, self-contained images, it seems to me that Org > > probably needs some way to specify whether SVG images should be > > exported as or (or maybe even inlined). > > Confirmed. > This is clearly a regression and should be fixed. > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at . > Support Org development at , > or support my work at > > --0000000000000461fa05eb3b0336 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Would the HTML <svg> tag be appropriate in this= case?

For example, here's a tiny example of u= sing the <svg> tag with an external CSS stylesheet: https://plnkr.co/edit/i8RFDW?preview

On Fri, Oct 14, 2022 at 4:32 AM Ihor Radchenko <yantar92@gmail.com> wrote:
Alexandre Duret-Lutz <adl@lrde.epita.fr> write= s:

> In Org 9.5, SVG images started being exported by the HTML exporter as<= br> > <img> rather than <object>.
>
> The patch causing that was
>=C2=A0 =C2=A0https://list.orgmode.org/87k0pe= mj6d.fsf@gmail.com/T/
> with two arguments:
> 1) <object> do not have an alt attribute
> 2) <object> will not render some SVG file correctly if it has no= viewBox
>=C2=A0 =C2=A0 (I'm assuming that the issue shown in that message is= a missing viewBox).
>
> The reason I've noticed this change is that it broke my web pages.= =C2=A0 On
> my pages, I use SVG to display many automata, and they all share a
> common stylesheet.=C2=A0 That stylesheet is not inlined into the SVG, = rather,
> it is a separate file included in the SVG files with
>=C2=A0 =C2=A0<?xml-stylesheet href=3D"filename.css" type= =3D"text/css"?>
> so that the browser only need to download it once.
>
> Infortunately, <img> does not allow external stylesheets to be > processed, so my stylesheets are now ignored.=C2=A0 Note that one can = also
> build SVG images that include other SVG images, or SVG images that hav= e
> animations that start when you hover on some elements.=C2=A0 All those=
> usages would break with <img>.
>
> I've seen that very issue was discussed back in 2016
> https://list.orgmode.org/871t2iq353.fsf@iki.fi= /T/
> where Christian Moe pointed out exactly this:
>
>> (2) You can also do other things with <object> that you cann= ot with
>> <img>, like manipulating the SVG with Javascript and styling= it with
>> an external stylesheet (linked from the SVG, not the web page). >
> So in the interest of allowing users to build documents where SVG
> files are not static, self-contained images, it seems to me that Org > probably needs some way to specify whether SVG images should be
> exported as <img> or <object> (or maybe even inlined).

Confirmed.
This is clearly a regression and should be fixed.

--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,=
or support my work at <https://liberapay.com/yantar92>

--0000000000000461fa05eb3b0336--