From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jarmo Hurri Subject: Re: Request: change SVG embedding in exported HTML Date: Sun, 24 Jul 2016 20:51:17 +0300 Message-ID: <8737myexgq.fsf@iki.fi> References: <87oa5oqzvr.fsf@iki.fi> <5c2f153b-05ad-c4b5-6384-e3e204a8f201@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46629) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bRNYu-0004R1-Oh for emacs-orgmode@gnu.org; Sun, 24 Jul 2016 13:51:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bRNYr-0003ZU-Lj for emacs-orgmode@gnu.org; Sun, 24 Jul 2016 13:51:36 -0400 Received: from plane.gmane.org ([80.91.229.3]:49618) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bRNYr-0003ZN-EW for emacs-orgmode@gnu.org; Sun, 24 Jul 2016 13:51:33 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1bRNYl-0005e4-8H for emacs-orgmode@gnu.org; Sun, 24 Jul 2016 19:51:27 +0200 Received: from 82-181-168-52.bb.dnainternet.fi ([82.181.168.52]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 24 Jul 2016 19:51:27 +0200 Received: from jarmo.hurri by 82-181-168-52.bb.dnainternet.fi with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 24 Jul 2016 19:51:27 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org Christian Moe writes: > I disagree. A switch to for SVG export (1) is not necessary for > scaling, and (2) would disable other useful features that are > presently available out of the box. > > (1) It *is* a bit easier to scale SVG with in HTML. But you > *can* scale SVG with by putting the in a container >
and scaling the container width and height. The current version of Org wraps the SVG image in a
of class figure, but at least setting the width of this class in a CSS produces no scaling effect (tested with Chrome and Safari). > This is actually simple with Org, which natively wraps the in > a
tag, and passes any attributes to the latter. > To scale an arbitrary image.svg e.g. to 100px width, try: > > #+attr_html: :width 100px > [[path/to/image.svg]] > > Alternatively, you can use #+attr_html to set an id on the figure >
, and style it with CSS. But if you need to set an id, then you will also have to do scaling on a file-by-file basis. Or? If this is so, then scaling would be a _lot_ easier using . Do we need to / could we add an option to HTML export? Either export all SVG files with or . Jarmo