Live data from Hacker News

Are We Taking CSS Too Far?

blog.echoenduring.com

21–30 of 58 posts

Re: Are We Taking CSS Too Far?

#21

Hmm, this trend of replacing bitmap images with CSS vector graphics is interesting but a bit strange. Is SVG on the browser dead, and CSS is replacing it? It has the advantage of better support and a simpler spec, but much worse tool support than SVG, not to mention really not being designed for vector graphics.

SVG didn't gain the needed momentum as it's approach was more revolutionary instead of evolutionary. Also Internet Explorer, although I'm not sure how it fits in this situation as it surely can't support all that fancy CSS required to do advanced graphics either.

Re: Are We Taking CSS Too Far?

#22
post #10

I agree with the author wholeheartedly. I always assumed these were experimental of the "just 'cause I can" type. Trying to show off how far CSS can go, but not really in a realistic usage. I read here though that people believe this is a useful type of use. Without getting into a flame-war if it is or isn't, I think the answer there is SVG: that should be just perfect for these sort of usage.

Unfortunately, IE 8 won't render SVG at all. I suppose graphics could be designed in a vector-based tool like Illustrator that can export SVG for compatible browsers as well as raster for lte IE8.

Re: Are We Taking CSS Too Far?

#23

Somedays I just wish we had used Postscript with hyperlinks instead of HTML/CSS/Javascript.

PDF basically has the necessary features to do that already. Nothing actually stops you.

(Before you say "Ewww, PDF", recall PDF is basically Postscript, and most of the reasons you would say "Ewww, PDF" would still apply. I did say "most", there are some exceptions. Now, if you want to say, "Ewww, Adobe", I'm right there with you.)

Re: Are We Taking CSS Too Far?

#24
post #20

Earlier quoted context omitted.

adding an icon inside a button is far simpler with css buttons, stretching it vertically is obviously miles miles easier with css than with images, email is just a whole other nightmare that I really dont think should even be considered when talking about sane html / css. I dont understand how you can possibly think generating text inside images to be more readable or semantic, future proof or maintainable. nor do I…

Good points, esp re email. I'm not particularly wedded to either side of the debate really, but: > generating text inside images oh, nonono, I was thinking more in terms of INPUT.button{background-image: url(btn.php?button_attributes_in_json);} > adding an icon inside a button is far simpler with css buttons depends what wonderful CSS you're using to create your button. > generating images programatically on the serv…

>you say 'programmatically' like I'm suggesting something beyond taking a few pre-made slices and combining them into one image before serving it up. I'm not.

heh its not "hard", but its already a hell of a less convenient than what I just do now with css.

Re: Are We Taking CSS Too Far?

#25
post #6

Earlier quoted context omitted.

CSS buttons mean that web apps can create UI elements without (a) relying on ugly, unreliable browser builtin sprites, and (b) having to handcraft graphics for every label the application needs. It's not a small win; it reduces many feature requests from 30 minutes down to 2.

If you need to handcraft graphics for every label the application needs then you are doing it wrong.

there is always this point at which you start automating things, you have 1 or 2 "discount stickers" or whatever. then you start using them a lot, and at some point it becomes worth it to build a tool to automate it rather than do it by hand.

with css you do it once and its pretty much already automated, you just add a class to each "discount" or "tag" button you want.

On a side note I really despise the "you are doing it wrong" meme, it virtually always means "you arent doing it with the same concerns I have".

Re: Are We Taking CSS Too Far?

#26
I'm surprised that so many people here are saying that pure-CSS buttons are actually a good thing, because they're programmatic. Sure, they're programmatic, but the code behind them is really confusing. I'd much prefer to use a sane drawing environment like an HTML5 canvas or the Raphaël library. Raphaël is perfectly suited to this sort of thing. Anything you make in Illustrator, you can make with Raphaël, and you get nice, clean code.

Re: Are We Taking CSS Too Far?

#27
post #23

Somedays I just wish we had used Postscript with hyperlinks instead of HTML/CSS/Javascript.

PDF basically has the necessary features to do that already. Nothing actually stops you. (Before you say "Ewww, PDF", recall PDF is basically Postscript, and most of the reasons you would say "Ewww, PDF" would still apply. I did say "most", there are some exceptions. Now, if you want to say, "Ewww, Adobe", I'm right there with you.)

At the rendering level Postscript and PDF are similar, but Postscript is a complete language. You could send semantically structured content and do appropriate layout on the client device all from inside Postscript.

You'd probably want to write in some other language or tool and use Postscript as an object language, like in the day of printers.

The huge difference is that the evolution of the media would be in the hands of the content creators, not the browser writers/choosers.

I would try this fork of the multiverse.

Re: Are We Taking CSS Too Far?

#28
post #6

Earlier quoted context omitted.

CSS buttons mean that web apps can create UI elements without (a) relying on ugly, unreliable browser builtin sprites, and (b) having to handcraft graphics for every label the application needs. It's not a small win; it reduces many feature requests from 30 minutes down to 2.

If you need to handcraft graphics for every label the application needs then you are doing it wrong.

We generate them with GraphicsMagick, but I've worked on my fair share of projects with complicated web UIs, and it was definitely not the standard practice I observed to automate this stuff (I got made fun of on this project for taking a couple hours to do it). They made buttons in Photoshop.

Re: Are We Taking CSS Too Far?

#29

Somedays I just wish we had used Postscript with hyperlinks instead of HTML/CSS/Javascript.

Any further explanation? I think for most people with websites, postscript would be an absolutely terrible choice: the barrier to entry is simply too high.

(Note: I think PostScript, and stack-based languages generally, can be great fun, but really not for the average “guy making a site about his dog” sort of user)

Post reply on HN