5 ms·
I get tired of making this same comment on every Canvas-based thing anybody builds, but if they'd taken the 30 seconds it took to write that paragraph about how
by jasonkester 16y ago
I get tired of making this same comment on every Canvas-based thing anybody builds, but if they'd taken the 30 seconds it took to write that paragraph about how it doesn't work in IE, and instead used it to paste in the following snippet of HTML, it would actually work in Internet Explorer:
<!--[if IE]><script type="text/javascript" src="/excanvas.js"></script><![endif]-->
Like, IE5 even. Internet Explorer has had vector graphics since 1999, and it overlaps 90% with Canvas (which came out several years later).
http://excanvas.sourceforge.net/ http://excanvas.sourceforge.net/
- vdm 16y agoI'm glad you did comment, because I'm not an expert on browser vector graphics and didn't know this. Bookmarked with tags "canvas, vector, graphics, IE, js".
- jessriedel 16y agoFrom the author's tone, it seemed clear to me that this was a case of him having an axe to grind rather than being actually stymied by a serious deficiency. Not particularly constructive.
- asdgasg 16y agoYou'd be annoyed too if you were the only one in the world who seemed to know about the tag that makes IE6 behave like Chrome.
- adambyrtek 16y agoIf you only knew a tag that would magically fix all the security issues in IE6 :)
- Natsu 16y agoWell, there is the "PLAINTEXT" tag[1], but I don't know if that will actually get all of IE6's security issues, even if you put it at the very start of the document. The attributes for it are pretty weird, too. Why would you put language="javascript" inside such a tag? [1] http://www.htmlref.com/reference/appa/tag_plaintext.htm http://www.htmlref.com/reference/appa/tag_plaintext.htm
- slashclee 16y agoThis was just a quick one-off hack that I did for fun. I had no idea how many people would find it interesting. If anybody does want to fix the code so that it loads properly in IE (and doesn't break any other browsers) I'm more than willing to integrate the changes!
- jessriedel 16y agoSorry if it seemed like I was vilifying you. I have no problem with people expressing opinions; that's what personal webpages are for! I was just trying to explain to the parent.
- ugh 16y ago“Works in pretty much any modern browser except IE (because IE doesn't have support for the <canvas> tag).” Please explain to me where “tone“ is hiding in that sentence. I don’t see it. There is nothing at all judgmental about it. It’s matter of fact, I don’t even see so much as a word or phrase that could in any way be construed as a snide remark directed at IE. I can’t find any possible interpretation that would hint at any kind of axe the author might have to grind. Context doesn’t help, either. The actual tone might help but the author sadly doesn’t provide an audiobook version of the webpage. (Snap judgments. This is why we can’t have nice things.)
- jessriedel 16y agoFirst: yikes. Second: It's context. There's no need to talk about deficiencies of browser on a page trying to illustrate bittorent. He could have just said "does not work with IE".
- palish 16y agoHmmm.... Did you test it to confirm? Are you sure that one line of code is all that's necessary to get that specific demo correctly working with Internet Explorer? What about keyboard input? (Canvas is only one piece of the demo.)
- jasonkester 16y agoKeyboard events work the same on IE as they do in every other browser, so that wouldn't be an issue. The demo does not appear to be doing anything subtractive, which is the only piece of 2D vector stuff that VML doesn't do (and therefore that excanvas doesn't handle automatically). So long as they're just drawing shapes on a canvas, it should simply start working once they include the excanvas script.
- slashclee 16y agoI'm the guy who ported this to processing.js, and no, it isn't that simple. I tried just adding that one line and it didn't actually work at the time. It turns out it's slightly more involved, and as I was just trying to make this a quick proof-of-concept hack, I didn't spend the time to rewrite the loading mechanism to make it IE-compatible. You can read more about the interactions between processing.js and excanvas at http://bocoup.com/processing-js/docs/index.php?page=Using%20exCanvas.js%20with%20Processing.js http://bocoup.com/processing-js/docs/index.php?page=Using%20... if you're so inclined, but please don't think that it's just because I was too lazy to add a single line of HTML.