Live data from Hacker News

It's 2020 and I'm using image maps

videoinu.com

11–20 of 109 posts

Re: It's 2020 and I'm using image maps

#11
post #9

I have considered recently I should make some things with imagemaps again, like there is untapped potential there I'm not clear of but that when I start working with it years of experience and new technologies will clarify.

Make a web framework that renders the UI entirely as mapped images. A PNG would probably be faster to load and render than most of today's multi-megabyte JS monstrosities.

> Make a web framework that renders the UI entirely as mapped images.

This is in fact what Microsoft Publisher (late 90s WYSIWYG web development tool) used to do if you dared to make any page elements overlap.

Re: It's 2020 and I'm using image maps

#12

I still use tables for layouting because divs and messing with positioning/floating never really clicked for me.

Nothing wrong really. Tables used to sucks in IE era.

But now IE is gone. Modern HTML Tables are fine as long as you know its limitations or basically dont try to do any fancy thing with it.

For some strange reason I see people keep saying aviod table at all cost. I dont get it. May be someone could explain it better.

Re: It's 2020 and I'm using image maps

#13
post #9

Earlier quoted context omitted.

Make a web framework that renders the UI entirely as mapped images. A PNG would probably be faster to load and render than most of today's multi-megabyte JS monstrosities.

Aaaaand it's 1996 again!

No in 1996 we did everything with frames, I once worked with a team that designed a website consisting of 200 frames.

Re: It's 2020 and I'm using image maps

#15
post #12

I still use tables for layouting because divs and messing with positioning/floating never really clicked for me.

Nothing wrong really. Tables used to sucks in IE era. But now IE is gone. Modern HTML Tables are fine as long as you know its limitations or basically dont try to do any fancy thing with it. For some strange reason I see people keep saying aviod table at all cost. I dont get it. May be someone could explain it better.

> Modern HTML Tables are fine

There are so many unpredictable edge cases to the magic of the table layout rendering algorithms that I would be hard pressed to recommend them for layout to anyone. I've seen the dark arts of what people do to make tables responsive and I want no part in it!

But honestly though there is a whole host of simple layouts that are a breeze with Flexbox or Grid that require precise contortions of the mind to produce with tables and the hacky css required to coerce them into order.

Re: It's 2020 and I'm using image maps

#16
post #12

I still use tables for layouting because divs and messing with positioning/floating never really clicked for me.

Nothing wrong really. Tables used to sucks in IE era. But now IE is gone. Modern HTML Tables are fine as long as you know its limitations or basically dont try to do any fancy thing with it. For some strange reason I see people keep saying aviod table at all cost. I dont get it. May be someone could explain it better.

One reason might be semantic markup. But with CSS display: table and related properties that's not really a problem.

Re: It's 2020 and I'm using image maps

#17
post #3

I feel like I'm missing something. It seems like declare a element, associate it with an , but then use JS to iterate over the map and build a bunch of absolutely positioned elements on top of the image. Why not just have the annotations stored outside the DOM (returned by API or whatever) and just build the absolutely positioned elements? Wouldn't that avoid the fighting with funky coordinate systems, etc.? I get wh…

If image maps only allowed rectangular areas, they wouldn't be terribly useful — you're right that it would be almost as easy to lay some transparent divs over the image.

However... image maps also allow for circular and polygonal regions, which can be really handy.

I guess you could also do that with a transparent SVG overlay, but using a map is easier.

Re: It's 2020 and I'm using image maps

#19
post #2

interesting mentions of the and tags. I have a modern app that makes use of these properties for making gif's. blink will make any content in the gif flash on the canvas and marquee will move it side to side : https://imgur.com/rgHrsoa

and can be pretty much replicated with CSS animations — there's no need for the tags anymore.

Re: It's 2020 and I'm using image maps

#20
post #4

> To make matters even more exciting, the last two coordinates might not be what you'd expect; when absolutely positioning items in CSS, right and bottom indicate the distance from the right and bottom edges respectively. In image maps, this holds no water. Instead, both horizontal coordinates are counted from the left edge and vertical coordinates from the top edge. Interesting. This order is commonly used by librar…

I think the ordering of coordinates for map regions makes more sense than the css margin/padding order:

rect: left, top, right, bottom

circle: cx,cy,r

poly: x1,y1,x2,y2,...

Post reply on HN