<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="MSHTML 6.00.6001.18203" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Thanks; but I'm surprisingly familar with SVG,
Adobe PDF, PostScript, Display PostScript, VML, ...;</FONT></DIV>
<DIV><FONT face=Arial size=2>this is about making image maps able to cope with
rescaled pixmaps; and making it easier to generate</FONT></DIV>
<DIV><FONT face=Arial size=2>and maintain the coordinates needed to create an
image map. -- it doesn't have much to do with the</FONT></DIV>
<DIV><FONT face=Arial size=2>image data itself. I have done the
equivalent using SVG,</FONT></DIV>
<DIV><FONT face=Arial size=2>VML, and JavaScript. The result for me
was not a simple intelligible clear-text HTML document; with
this</FONT></DIV>
<DIV><FONT face=Arial size=2>approach (HTML Imagemap, but with percent units for
coordinates) it would be as close to such a simple ideal as I can imagine it to
be, given you are describing an image's internal borders with</FONT></DIV>
<DIV><FONT face=Arial size=2>numeric values.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>If pressed, one could convert any HTML
document entirely into SVG; with far more control of text at the</FONT></DIV>
<DIV><FONT face=Arial size=2>graphic level ( the same being true more-so of
PostScript/PDF). But this costs you. The day that HTML is no longer</FONT></DIV>
<DIV><FONT face=Arial size=2>"hand-writable" would be a sad day indeed; that is
one of it's great beauties. CSS (Cascading Style Sheets)</FONT></DIV>
<DIV><FONT face=Arial size=2>saved it from that path of destruction once
already. </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Ironically, I eschew imagemaps whenever possible.
But sometimes a picture is worth a thousand words. Especially if
you</FONT></DIV>
<DIV><FONT face=Arial size=2>can point and click on parts of it. A great public
site for demonstrating that is the FOTW (Flags Of The World) site at <A
href="http://flagspot.net">http://flagspot.net</A></FONT></DIV>
<DIV><FONT face=Arial size=2>One example out of thousands -- <A
href="http://flagspot.net/flags/sk(.html">http://flagspot.net/flags/sk(.html</A> .
That being said ...</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Imagine HTML didn't have image maps until today and
that you were going to add the feature. Unlike when image maps</FONT></DIV>
<DIV><FONT face=Arial size=2>were originally introduced, you know that plain
images are easily and frequently displayed at different sizes on
devices of very different scale (instead of being able to assume everyone is
using an X11 Windows display with a large monitor and mapping their pixmap files
one-to-one to display pixels). I'd bet </FONT></DIV>
<DIV><FONT face=Arial size=2>you would end up supporting percent units for
your image map regions' coordinates. </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I jotted something together ( I tend to think
things out by prototyping them) that provides more context for the
discussion</FONT></DIV>
<DIV><FONT face=Arial size=2>a while ago at <A
href="http://home.comcast.net/~urbanjost/IMG/semaphore.html">http://home.comcast.net/~urbanjost/IMG/semaphore.html</A>.
</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>That reminds me -- visual cueing by changing the
opacity of the region you are currently hovering over would be a nice
enhancement;</FONT></DIV>
<DIV><FONT face=Arial size=2>that's one significant advantage SVG/PDF/VML/CANVAS
methods would still have. </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<BLOCKQUOTE dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=jrm@google.com href="mailto:jrm@google.com">Jim Meehan</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=ian@hixie.ch
href="mailto:ian@hixie.ch">Ian Hickson</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Cc:</B> <A title=urbanjost@comcast.net
href="mailto:urbanjost@comcast.net">John S. Urban</A> ; <A
title=help@lists.whatwg.org
href="mailto:help@lists.whatwg.org">help@lists.whatwg.org</A> ; <A
title=djolenene@yahoo.co.uk href="mailto:djolenene@yahoo.co.uk">Dorde
Nenezic</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Wednesday, February 11, 2009 10:52
AM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [html5] (no subject)</DIV>
<DIV><BR></DIV>The discussion about images sounds like you're slowly
re-inventing PostScript with its inline images. There is an elaborate
commenting system, the Document Structuring Convention, that added more and
more information in these "comments." Just as things were getting really crazy
with the DSC, PDF came along and solved all those problems in a much cleaner
way, and it pretty much marked the end of hand-written PostScript. (The
Acrobat Distiller compiled PostScript into PDF, and the Acrobat Reader
converted PDF into PostScript for sending to PostScript printers.)
<DIV><BR></DIV>
<DIV>So I second Ian's suggestion to consider SVG, which was a
post-PostScript, post-PDF invention. I'm not familiar with the details of SVG,
and in a quick look at some documents on the Web (e.g., Wikipedia), I didn't
see anything about inline images (image = "raster image," which is the
opposite of "vector graphics"), or even scalable non-inline images, but
perhaps they're there. In any case, there's already a pretty good wheel; no
need to re-invent it.</DIV>
<DIV><BR></DIV>
<DIV>--Jim Meehan</DIV>
<DIV>(@Adobe 1993-2004)<BR><BR>
<DIV class=gmail_quote>On Wed, Feb 11, 2009 at 1:37 AM, Ian Hickson <SPAN
dir=ltr><ian@hixie.ch></SPAN> wrote:<BR>
<BLOCKQUOTE class=gmail_quote
style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">On
Tue, 6 Jan 2009, John S. Urban wrote:<BR>> ><BR>> > Percents
aren't allowed currently... what do browsers do with percentage<BR>> >
values? Is it useful?<BR>><BR>> As most browsers seem to implement
them,percent values are useful in<BR>> that you do not have to redo the
coordinates for different sizes of the<BR>> same image. So if you have a
small map for small screens, and a large<BR>> one for accessibility
purposes or for larger screens, the same <MAP> can<BR>> be used
without re-doing the coordinates; whereas pixel values<BR>> (currently)
need redone for each pixmap file.<BR><BR>Fair enough. I've added a comment
in the spec suggesting that we might<BR>want to add this at some future
point. I haven't added it yet because<BR>image maps aren't resized that
often as far as I can tell and I'm trying<BR>to not add new features at this
point.<BR><BR><BR>> I find this behavior useful enough to have made a
limited-case<BR>> JavaScript function to supply the desired behavior,
which I use in<BR>> several projects. But this (seemingly simple?)
behavior would make a<BR>> generic, clean and easily understood way to
rescale maps to new images<BR>> sizes. I meant the example URI to
show the usefulness of such a<BR>> feature; but I might have made the
image too simple. The method shown in<BR>> the example has proven to be
very useful with floor plans, maps of<BR>> geographic locations, ...
.<BR><BR>I can imagine it would be quite useful, yes. Have you considered
using SVG<BR>for this kind of thing, by the way?<BR><BR><BR>> PS: I
have been experimenting with replacing the image maps with<BR>>
<CANVAS> elements, but found I had to create my own routines to
detect<BR>> if I was in a polygon or not to do so. SVG supports the
features I need<BR>> to make a scaleable vector-based drawing with
clippable regions, but<BR>> requires external files and so on. Am I
correct, or is there a way to<BR>> use MAP and AREA with a CANVAS ? If
there is, that would be another<BR>> reason to support scaling
coordinates; as vector drawings are very well<BR>> suited to dynamic
rescaling (and zooming and clipping, for that matter).<BR><BR>There's no way
to use <map> with <canvas> currently. We will be
supporting<BR><svg> embedded in the same HTML file
though.<BR><BR><BR>> PSS: If you make multiple files displaying
differently-sized images of<BR>> the same "picture", and put a single
<MAP> in another file, experience<BR>> shows some browsers seem to
have trouble with that. If the URI is<BR>> anything other than a "#NAME"
reference, some browsers fail. This means<BR>> it is much more work to
update an imagemap used in multiple documents.<BR><BR>In HTML5, the
usemap="" attribute is no longer a URI at all (just an ID<BR>ref with a
leading "#" for historical reasons).<BR><FONT color=#888888><BR>--<BR>Ian
Hickson U+1047E
)\._.,--....,'``.
fL<BR><A href="http://ln.hixie.ch/"
target=_blank>http://ln.hixie.ch/</A> U+263A
/, _.. \ _\
;`._ ,.<BR>Things that are impossible just take longer.
`._.-(,_..'--(,_..'`-.;.'<BR>_______________________________________________<BR>Help
mailing list<BR><A
href="mailto:Help@lists.whatwg.org">Help@lists.whatwg.org</A><BR><A
href="http://lists.whatwg.org/listinfo.cgi/help-whatwg.org"
target=_blank>http://lists.whatwg.org/listinfo.cgi/help-whatwg.org</A><BR></FONT></BLOCKQUOTE></DIV><BR></DIV></BLOCKQUOTE></BODY></HTML>