* SVG support in Emacs: what happened?
@ 2007-01-19 10:00 Benjamin Hawkes-Lewis
2007-01-19 19:43 ` Paul Pogonyshev
2007-01-19 22:22 ` Richard Stallman
0 siblings, 2 replies; 11+ messages in thread
From: Benjamin Hawkes-Lewis @ 2007-01-19 10:00 UTC (permalink / raw)
I see that /etc/TODO still includes "Add support for SVG (Scalable
Vector Graphics) rendering to Emacs." In 2004, some hacky code was
actually written to do this using librsvg:
http://lists.gnu.org/archive/html/emacs-devel/2004-09/msg00886.html
Does anyone know if there is some fundamental roadblock against patching
current Emacs CVS with something like this code?
SVG support would allow the use of scalable SVG icons (increasingly the
icon format of choice) in the Emacs toolbar, rendering SVG web content
with Emacs/W3, and perhaps previewing for SVG authors.
--
Benjamin Hawkes-Lewis
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-19 10:00 SVG support in Emacs: what happened? Benjamin Hawkes-Lewis
@ 2007-01-19 19:43 ` Paul Pogonyshev
2007-01-19 22:22 ` Richard Stallman
1 sibling, 0 replies; 11+ messages in thread
From: Paul Pogonyshev @ 2007-01-19 19:43 UTC (permalink / raw)
Cc: Benjamin Hawkes-Lewis
Benjamin Hawkes-Lewis wrote:
> I see that /etc/TODO still includes "Add support for SVG (Scalable
> Vector Graphics) rendering to Emacs." In 2004, some hacky code was
> actually written to do this using librsvg:
>
> http://lists.gnu.org/archive/html/emacs-devel/2004-09/msg00886.html
That was my patch. The only obstacle I see is the `imminent' release
we hear about for the last 2 or 3 years.
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-19 10:00 SVG support in Emacs: what happened? Benjamin Hawkes-Lewis
2007-01-19 19:43 ` Paul Pogonyshev
@ 2007-01-19 22:22 ` Richard Stallman
2007-01-19 23:48 ` Benjamin Hawkes-Lewis
1 sibling, 1 reply; 11+ messages in thread
From: Richard Stallman @ 2007-01-19 22:22 UTC (permalink / raw)
Cc: emacs-devel
I see that /etc/TODO still includes "Add support for SVG (Scalable
Vector Graphics) rendering to Emacs." In 2004, some hacky code was
actually written to do this using librsvg:
http://lists.gnu.org/archive/html/emacs-devel/2004-09/msg00886.html
It sounds like you're saying this code is not well written.
Is that what you mean?
1. If it isn't well written, it is not the right solution.
2. If it is well written, we could add it (after the release), if we
get legal papers from the authors.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-19 22:22 ` Richard Stallman
@ 2007-01-19 23:48 ` Benjamin Hawkes-Lewis
2007-01-20 0:10 ` Paul Pogonyshev
2007-01-20 7:49 ` Richard Stallman
0 siblings, 2 replies; 11+ messages in thread
From: Benjamin Hawkes-Lewis @ 2007-01-19 23:48 UTC (permalink / raw)
Cc: Paul Pogonyshev, emacs-devel
Richard Stallman wrote:
> It sounds like you're saying this code is not well written.
> Is that what you mean?
Ah. No. I'm very sorry if that sounded like my personal judgement on the
code, especially as I wouldn't even claim the expertise to make such a
judgement.
My use of the adjective "hacky" was just an attempt to summarize how the
original author (Paul Pogonyshev) described the code: "Here is the first
shot. It is extremely non-portable, hackish and ugly, but it works!"
At the time, you wrote "I don't have time to read the code":
http://lists.gnu.org/archive/html/emacs-devel/2004-09/msg00903.html
So I didn't have anything else to go on other than Paul's own verdict.
Many apologies to Paul if he likewise assumed I was taking it upon
myself to criticize his code.
> 2. If it is well written, we could add it (after the release), if we
> get legal papers from the authors.
I asked if there was "some fundamental roadblock against patching
current Emacs CVS with something like this code". Paul just said he sees
no obstacle. Back in 2004, Paul said: "I may be willing to have a try
[at creating a patch], provided that 'librsvg' usage is acceptable." As
far as I can tell from your comments in the original thread, librsvg
usage /is/ acceptable.
If that's so, the remaining questions are:
1. What does the code need to make it "portable"?
2. What makes it "ugly", other than non-portability?
3. Is Paul (or anyone else) (in 2007) "willing to have a try" at turning
it from a "first shot" into a final patch?
--
Benjamin Hawkes-Lewis
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-19 23:48 ` Benjamin Hawkes-Lewis
@ 2007-01-20 0:10 ` Paul Pogonyshev
2007-01-20 13:36 ` Eli Zaretskii
2007-01-20 7:49 ` Richard Stallman
1 sibling, 1 reply; 11+ messages in thread
From: Paul Pogonyshev @ 2007-01-20 0:10 UTC (permalink / raw)
Cc: Benjamin Hawkes-Lewis, rms
Benjamin Hawkes-Lewis wrote:
> [...]
>
> Many apologies to Paul if he likewise assumed I was taking it upon
> myself to criticize his code.
No offence taken.
> > 2. If it is well written, we could add it (after the release), if we
> > get legal papers from the authors.
>
> I asked if there was "some fundamental roadblock against patching
> current Emacs CVS with something like this code". Paul just said he sees
> no obstacle. Back in 2004, Paul said: "I may be willing to have a try
> [at creating a patch], provided that 'librsvg' usage is acceptable." As
> far as I can tell from your comments in the original thread, librsvg
> usage /is/ acceptable.
>
> If that's so, the remaining questions are:
>
> 1. What does the code need to make it "portable"?
Probably input of someone on Windows. I'm sure it won't compile there
simply because I made no effort for this.
> 2. What makes it "ugly", other than non-portability?
It doesn't support scaling (which is natural for SVG), as far as I remember
it doesn't support transparency but uses some ad-hoc background color. And
likely more problems.
> 3. Is Paul (or anyone else) (in 2007) "willing to have a try" at turning
> it from a "first shot" into a final patch?
Not as I know. I'm not going to work on it until Emacs trunk is
"unfrozen". It might as well take another year or two, so it is
meaningless for me (as not a core Emacs developer) to spend time on it.
Feel free to take it. I assigned copyright to FSF on Emacs changes, so
this patch can be assumed as copyrighted by FSF.
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-19 23:48 ` Benjamin Hawkes-Lewis
2007-01-20 0:10 ` Paul Pogonyshev
@ 2007-01-20 7:49 ` Richard Stallman
2007-01-20 19:45 ` Paul Pogonyshev
1 sibling, 1 reply; 11+ messages in thread
From: Richard Stallman @ 2007-01-20 7:49 UTC (permalink / raw)
Cc: emacs-devel, pogonyshev
Paul, what do you think now? Is this code good enough to use?
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-20 0:10 ` Paul Pogonyshev
@ 2007-01-20 13:36 ` Eli Zaretskii
2007-01-20 19:48 ` Paul Pogonyshev
2007-01-21 6:49 ` Richard Stallman
0 siblings, 2 replies; 11+ messages in thread
From: Eli Zaretskii @ 2007-01-20 13:36 UTC (permalink / raw)
Cc: bhawkeslewis, rms, emacs-devel
> From: Paul Pogonyshev <pogonyshev@gmx.net>
> Date: Sat, 20 Jan 2007 02:10:34 +0200
> Cc: Benjamin Hawkes-Lewis <bhawkeslewis@googlemail.com>, rms@gnu.org
> >
> > 1. What does the code need to make it "portable"?
>
> Probably input of someone on Windows. I'm sure it won't compile there
> simply because I made no effort for this.
The patch indeed needs some work to avoid breaking the Windows port.
As posted, the patch will try to compile the SVG code unconditionally,
since it uses very strange conditionals to enable SVG:
#if 1 || defined (HAVE_RSVG)
If these are replaced with the usual "#if HAVE_RSVG", then I think
MS-Windows will not be a problem.
One other issue would be to see whether the configure test is okay.
For example, do we really want to use pkg-config for that? do all
platforms that have SVG also have pkg-config?
> > 3. Is Paul (or anyone else) (in 2007) "willing to have a try" at turning
> > it from a "first shot" into a final patch?
>
> Not as I know. I'm not going to work on it until Emacs trunk is
> "unfrozen". It might as well take another year or two, so it is
> meaningless for me (as not a core Emacs developer) to spend time on it.
FWIW, I don't think we should add this code during the pretest.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-20 7:49 ` Richard Stallman
@ 2007-01-20 19:45 ` Paul Pogonyshev
0 siblings, 0 replies; 11+ messages in thread
From: Paul Pogonyshev @ 2007-01-20 19:45 UTC (permalink / raw)
Cc: Benjamin Hawkes-Lewis
Richard Stallman wrote:
> Paul, what do you think now? Is this code good enough to use?
No. But I think it is a good starting point to implement support
for SVG after the release.
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-20 13:36 ` Eli Zaretskii
@ 2007-01-20 19:48 ` Paul Pogonyshev
2007-01-20 22:38 ` Jason Rumney
2007-01-21 6:49 ` Richard Stallman
1 sibling, 1 reply; 11+ messages in thread
From: Paul Pogonyshev @ 2007-01-20 19:48 UTC (permalink / raw)
Cc: bhawkeslewis, rms
Eli Zaretskii wrote:
> > From: Paul Pogonyshev <pogonyshev@gmx.net>
> > Date: Sat, 20 Jan 2007 02:10:34 +0200
> > Cc: Benjamin Hawkes-Lewis <bhawkeslewis@googlemail.com>, rms@gnu.org
> > >
> > > 1. What does the code need to make it "portable"?
> >
> > Probably input of someone on Windows. I'm sure it won't compile there
> > simply because I made no effort for this.
>
> The patch indeed needs some work to avoid breaking the Windows port.
> As posted, the patch will try to compile the SVG code unconditionally,
> since it uses very strange conditionals to enable SVG:
>
> #if 1 || defined (HAVE_RSVG)
I added this because I didn't run `autoconf' or `autoheader, it was
mentioned in my message. Of course it should be replaced with a proper
condition.
Also, drawing code is not portable and was adapted from some existing
code for X. Don't remember which exactly.
> One other issue would be to see whether the configure test is okay.
> For example, do we really want to use pkg-config for that? do all
> platforms that have SVG also have pkg-config?
AFAIK, librsvg tests for pkg-config in its own `configure' script.
> > > 3. Is Paul (or anyone else) (in 2007) "willing to have a try" at turning
> > > it from a "first shot" into a final patch?
> >
> > Not as I know. I'm not going to work on it until Emacs trunk is
> > "unfrozen". It might as well take another year or two, so it is
> > meaningless for me (as not a core Emacs developer) to spend time on it.
>
> FWIW, I don't think we should add this code during the pretest.
Sure we shouldn't. I just wish pretest doesn't take forever.
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-20 19:48 ` Paul Pogonyshev
@ 2007-01-20 22:38 ` Jason Rumney
0 siblings, 0 replies; 11+ messages in thread
From: Jason Rumney @ 2007-01-20 22:38 UTC (permalink / raw)
Cc: Eli Zaretskii, bhawkeslewis, rms, emacs-devel
Paul Pogonyshev wrote:
> Also, drawing code is not portable and was adapted from some existing
> code for X. Don't remember which exactly.
>
Drawing code is generally fairly easy to port. It just involves changing
names of functions, and sometimes adjusting representations of
co-ordinates (eg rectangles in some APIs are [x1, y1, x2, y2] while
others use [x1, y1, w, h].
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: SVG support in Emacs: what happened?
2007-01-20 13:36 ` Eli Zaretskii
2007-01-20 19:48 ` Paul Pogonyshev
@ 2007-01-21 6:49 ` Richard Stallman
1 sibling, 0 replies; 11+ messages in thread
From: Richard Stallman @ 2007-01-21 6:49 UTC (permalink / raw)
Cc: emacs-devel, bhawkeslewis, pogonyshev
FWIW, I don't think we should add this code during the pretest.
I agree. It is a new feature, not a bug fix.
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2007-01-21 6:49 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-19 10:00 SVG support in Emacs: what happened? Benjamin Hawkes-Lewis
2007-01-19 19:43 ` Paul Pogonyshev
2007-01-19 22:22 ` Richard Stallman
2007-01-19 23:48 ` Benjamin Hawkes-Lewis
2007-01-20 0:10 ` Paul Pogonyshev
2007-01-20 13:36 ` Eli Zaretskii
2007-01-20 19:48 ` Paul Pogonyshev
2007-01-20 22:38 ` Jason Rumney
2007-01-21 6:49 ` Richard Stallman
2007-01-20 7:49 ` Richard Stallman
2007-01-20 19:45 ` Paul Pogonyshev
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).