Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror
×
Microsoft Graphics Internet Explorer

How To Get Around the Holes In IE9 Beta's Implementation of Canvas 111

mudimba writes "Microsoft has made grand announcements about how great their implementation of the HTML5 canvas specification is. However, while I was porting a large HTML5 application to work with IE9 beta I found that there are some key features missing. Workarounds are provided where possible. (Disclaimer: I am the author of the submitted article.)"
This discussion has been archived. No new comments can be posted.

How To Get Around the Holes In IE9 Beta's Implementation of Canvas

Comments Filter:
  • by Anonymous Coward
    Doesn't everyone on slashdot use a *nix system?
    • Re: (Score:2, Insightful)

      or at the very least, install a half-decent browser on any system running windows (such as when the boss forces you to)

    • Doesn't everyone on slashdot use a *nix system?

      This is about porting a web application to the Internet Explorer 9 beta, not about using a browser on one's own system. The audience for the application is everyone, Windows and OS X users, via any browser that might be able to render it. Excluding the Windows/IE audience is rarely, if ever, a prudent position for a web application.

    • What a strange question. While it's conceivable that people out there are developing bespoke graphics web applications for themselves, by and large web developers are developing for a larger audience. What kind of system the developer uses is irrelevant, when the developer can trust that the broader audience's system profiles are fragmented. And since Microsoft is championing the "same code" mantra (which is hardly an achievement to shout to the heavens, as all the other browser vendors have had this motto

  • by suso ( 153703 ) *

    Its 2011 and (big surprise) there are still problems with IE's implementation of HTML. This has been going on since IE3 (and probably before). I think we can safely say at this point that the problem is the company and will probably never change. As they say, the day Microsoft makes a product that doesn't suck is the day they make a vacuum cleaner.

    • by DrXym ( 126579 )
      There are problems with every browser's implementation of HTML5. Test your browser here [html5test.com] and see. For all the buzzword bullshit about HTML5 from every browser maker, it's clear that pretty much all of them come up short. And that page is just looking at the top level functions, I bet there are bugs and quirks galore once you drill deeper.
      • And yet IE comes shortest, there is litterally only one feature they did right and that is the hardware accelerated CSS transitions and transformations and even there it is questionable which transitions work and which not. Everything else is either only halfway implemented or missing entirely.
        IE9 is html 4.5 at best :-)

        • Id say the wisest move would be from Microsofts side to ditch IE entirely and participate in the Webkit project like everyone else, then we finally also would have a unification in engines to big degrees!
          But hell freezes over before that happens I guess.

          • They can't let go of their Incompatibility Paradigm that gave them lock-in for 7 years.

          • This was the argument that I was making after IE 8's release, and I think the IE team has proven us wrong. I was convinced that Trident was irreparably compromised by backwards compatibility, but in IE 9 they have made great strides in interoperability with the rest of the browser vendors. It's probable that IE 9 won't get them all the way there (although they've continually surprised with adding substantial improvements with each pre-release, including the introduction of canvas when it seemed they were go

        • Comment removed based on user account deletion
      • IE always seems to have more problems than other browsers. We've seen it recently with IE7's and IE8's low scores on Acid3, which Microsoft is finally fixing in IE9. Right now, the most current stable release of nearly every browser scores 90/100 or above on Acid3, but IE8 still scores 20/100, lagging far behind everyone else. Similarly, IE9 is lagging behind on HTML5 features compared to other browsers. So, yes, every browser has problems with HTML5, but we can expect IE to have more problems than other br
        • While I look forward to HTML5 features as a web developer, I think it's hardly fair to complain that IE has incomplete support for an incomplete standard. If you look at the implementations provided by Apple and Google and Mozilla, you'll see that among (and even within) the more mature engines there are huge areas of incompatibility in HTML5 and CSS3, much of which is barely in a draft state. The IE team has (unsurprisingly and un-offensively, IMO) chosen to focus on *stable* specs for IE 9, and have execu

      • FF 3.6.8 gets 139 + 4 bonus points out of possible 300

        IE 7.0.5730 gets 12

        NOTE: the http://html5test.com/ [html5test.com] site does not keep score for any browsers.

    • Re:Gotta say it (Score:5, Insightful)

      by MemoryDragon ( 544441 ) on Friday January 14, 2011 @09:38AM (#34876546)

      Yes I find it quite amusing how Microsoft plays the we are html5 ready game currently marketingwise while they literally are three years behind the competition in many areas of html5. IE9 will be html5s IE6 all over again, as it seems to me.

      • Where are my mod points when I need them. (Sign)

        • by suso ( 153703 ) *

          You probably lose them on making comments like "Where are my mod points when I need them".

      • Care to mention any, and I mean litereally even one, place where IE9 is three years behind another browser on HTML5?

        I call bullshit. There are some places where the (4 month old) IE9 beta is behind, yes, but not by three years, or even close. There are fewer places where the (2 month old) IE9 platform preview (still beta code) is behind. Two of the issues this article mentions were fixed internally even before the article was posted.

        Yes, it would help if MS released builds more than once every 2 months. Tha

    • Re:Gotta say it (Score:4, Informative)

      by I8TheWorm ( 645702 ) * on Friday January 14, 2011 @11:41AM (#34878186) Journal

      You get that it's beta, right?

      • They aren't going to add anything anymore. It may as well be RC.

        • ?? Beta 9 and beta 10 haven't been released yet. I"m not sure where you get your facts (speculation?) from.

          • It's speculation. I guess I should have added that.

            • Fair enough.

              Mind you, I'm not really a supporter of IE9, and rarely use IE at all. I'm glad MS is getting more current with web standards though, although it never seems to be enough.

        • Dude, that may be the usual meaning of beta, but unless you have a hell of a lot closer sources than I do (possible but unlikely) that's an unjustified assertion. It's only two months since the last public Platform Preview build (the beta build is 4 months old, PP builds are usually on a roughly 8 week scedule so another could come out any day). Each PP build has added features. They've continued adding features and fixing incompatibilities well past the beta release. They *probably* won't do that into RC,

  • by BlueScreenO'Life ( 1813666 ) on Friday January 14, 2011 @09:25AM (#34876416)
    So, a browser in beta phase does not conform to a specification in draft stage!
    Who would have thought!
    • Well if all other browsers in beta and final are draft spec compliant and the so called beta browser is literally the last to the game it better ought to be better than the rest of the world or it will drown and be ignored.

      • Not arguing that. I avoid IE whenever possible but I just find it funny how we don't miss a chance to take a dig at MS.
        Amusingly enough, the link to the specification points to a page with a big warning reading "This version of the specification has been superceded!". How wise is it to spend time making a browser to implement a spec that changes so often? And complex apps that rely on it, for that matter?
    • by kikito ( 971480 )

      "Who would have thought!"

      Someone aware of Microsoft's previous track on browsers.

      Or someone who has just spent the last 2 days trying to dumb down their markup just so the dumbest browser of all time was able to render it correctly. Or someone who has just purchased a domain name (www.i8ie.com) just to express his mental state after that endeavor.

  • by captain_dope_pants ( 842414 ) on Friday January 14, 2011 @09:31AM (#34876460)
    Just the other day someone asked if I'd done any work with HTML5 and I said I was going to wait for a good while until it worked everywhere. They assured me it did, now I find the opposite.

    Glad I didn't bother starting now - procrastination has saved me yet again :)
    • It's not black or white. CSS doesn't work everywhere, in the sense that if you write CSS the way web design books explain, much CSS won't work in IE6 and IE7. If you wait until all HTML5 features work on all browsers, you'll be waiting a very, very long time.
      • But if you decide that "4 out of 6 Ain't Bad", and skip IE and your choice of one of the others, there might be as much as 5 years of dev time saved in the sense of practice and store code now, rather than waiting on a magical green light day.

        • Or you can stick to features that work in all browsers. Just because all browsers don't support all of HTML5 doesn't mean you should avoid HTML5 completely. It's simply not black or white.
        • by tepples ( 727027 )

          skip IE

          And skip nearly half of your customers.

          • well it's either that, or lose the other half to web outfits that have some guts? because those sites would be more usable, prettier, AND faster to boot, so assuming everything else is the same.... and frankly, when it's 50/50 of "internet explorer users" vs. JUST ABOUT ANYTHING, gimme the people who don't actively participate in exploding the intarwebs by being clueless and lazy. (and I bet they have less money than the other half, too, if your thoughts go along such whorish lines (mine don't)).

            if big (I m

            • by tepples ( 727027 )

              no, they'd display a big, fat warning with a helpful list of compatible browsers

              None of which you have permission to install, or whose portable version you have permission to use, due to software restriction policies in effect on the computer you're using.

              • what exactly are you talking about?

                • If the site is broken and a list of downloadable alternative browsers appears, the user may not have privileges to install the program or to run the portable version. Only an administrator can install software to Program Files, and the so-called portable version [wikipedia.org] can be blocked using Windows software restriction policies [microsoft.com].
                  • But wouldn't any admin worth their salt already have a modern browser installed?

                    Sure, employees might not be, uhm, expected to use Ebay and Facebook... but let's say, if even Google stopped caring about anything non-standard, if ALL big sites did... then you'd have Firefox etc. installed virtually everywhere 3 days after that, and two weeks later Microsoft would announce IE 10.

                    And for those places where you're not allowed to browse at work, well, screw 'em. You're not suggesting we keep all that IE-co
    • It works everywhere they have a released browser that supports it ...

      IE9 is still beta - When released it will support the bits of HTML5 that MS can be bothered to implement, and for everything else they will say, "It doesn't do that use Silverlight"

      • And IE9 won't be made to work on XP, shutting out a large segment of users. Meanwhile, the latest Firefox (and other browsers) will run on Linux, MacOS, Vista, 7, *and* XP.

        Firefox/Mozilla: Free, Open Source, standards based, actively developed, multiplatform, supports older versions of OS's, and huge market penetration. If I were developing ANY type of web application, I would absolutely use Firefox as the main target.

        • And IE9 won't be made to work on XP, shutting out a large segment of users. Meanwhile, the latest Firefox (and other browsers) will run on Linux, MacOS, Vista, 7, *and* XP.

          Firefox/Mozilla: Free, Open Source, standards based, actively developed, multiplatform, supports older versions of OS's, and huge market penetration. If I were developing ANY type of web application, I would absolutely use Firefox as the main target.

          If I were developing ANY type of web application, I would absolutely use Opera as the main target, as it has been explicitly designed from the very start to conform to W3C specifications...

    • This mess only shows that the web in is flaved by design and the "apps" are way better in just any regard. The web 3.0 really are the apps with backside server feed.

      For example there is an iPad app for weather, that is so good that we completely stopped visiting weather office website. I do not think the web will go the way of Gopher [wikipedia.org], but near future might show that HTML5 will not be needed or even wanted.
    • by xaxa ( 988988 )

      There are plenty of bits of HTML5 that you can start using now. They might not do anything on one or more browsers, but they'll be appreciated by the people that do see them. I used some HTML5 for a website we launched recently, and we haven't had any reports of problems with things like <input type="search" placeholder="Search articles"> or <article>.

      Here [diveintohtml5.org] is a good place to start.

      I did the same regarding CSS3. Columns and the :target attribute don't work in IE, but it's useful for people with b

    • IE9 is still in beta, still getting improvements made and incompatibilities removed. Despite that, it's already compatible enough that it will happily run (at good framerate) a NES emulater entirely in JavaScript, HTML5, and especially canvas. That emulator was definitely not written as an IE9 demo, either - it's just compatible with it because IE9 adheres to the standard well enough.

  • Test Cases (Score:5, Insightful)

    by Anonymous Coward on Friday January 14, 2011 @09:32AM (#34876482)

    1. He's using IE9 Beta 1, which is fairly old and out of date. He should try the latest platform preview.
    2. He should post functional test cases, like ACID does, instead of posting just the code and pictures.
    3. He should contact MS. Instead he is relying on the nerd-rage from Slashdot to get big enough for them to notice. They have an appropriate channel for this where the issue can be discussed.
    4. Despite what people think, canvas is not HTML. It's a proprietary and patented Apple technology that has been submitted to W3C for review as a potential addition to HTML. Yes, submission to W3C does require patent disclosure and royalty-free licensing when a submission becomes a part of a recommendation, but canvas has not reached that stage. Patent fears aside, as an early draft it is a standard subject to change either by W3C or by anyone who feels like interpreting the draft as they see fit, which could occur concurrently as in opposition to each other.

  • The web is still suffering from all the workarounds implemented for IE6 ... don't do workarounds, make M$ FIX the problems instead!

    • Maybe Microsoft IE team doesn't have the money or resources to develop their browser? After all, they don't get the google income of Firefox and they have to pay those horrible h264 fees. They must be borderlining on broke or something. The old guys were disbanded years ago to work on bigger projects and only college hang overs who beg for money from their parents get to touch the code nowadays. [end sarcasm]

      I honestly would expect more from an ex-market leader in web browser development. Pure laziness

  • You can (and should) submit bug reports for IE9 directly to Microsoft [microsoft.com]. Complaining on your personal blog and hoping that the magic internet fairies will take care of it is less effective at getting the problem fixed.

    • Actually, I think getting a slashdot article on the issue is a whole lot more likely to get it fixed. They do come here you know.
      • by pyalot ( 1197273 )

        They do come here you know.

        I knew it. They are among us! The truth is out there, searching for your webdev grief.

    • Since it's not a bug in the typical meaning of that word, but actual missing support of a number of features, I'm pretty sure MS is aware of them and has intentionally postponed them for IE 10 or later.

      • Or the stable release of IE9. He *is* testing a beta, remember. Beta? Beta? Remember what Beta means? (Not even the most current beta, to-boot.)

    • by kikito ( 971480 )

      Yeah, it has worked great on the last 4 versions of the browser.

  • by pyalot ( 1197273 ) on Friday January 14, 2011 @09:57AM (#34876720)
    I just got forced to adopt IE8 compatibility (outside constraints). After developing something that runs just fine in Safari/Firefox/Chrome for 4 weeks, it took me:

    The downside
    - 4 hours to get it to run in IE8
    - Data intensive JS processing/DOM manipulation is about 10x slower then in either of the alternatives
    - Since no support for CSS3 border-image is present, it makes it look ugly
    - Since DOM/JS is so slow, animations (width, height, opacity etc.) are slow as hell.
    - the HTML5 popstate event (document.location change) is not supported, hence a watchdog interval has to be installed checking the document.location.hash 20x/second
    - since IE is the only browser to enforce XHR caching, every request needs a timestamp query parameter (something that no other browser does, and which is really stupid, altough easy to provide)
    - the developer tools are difficult to use (as compared to chrome, webkit, firebug etc.)

    The Upside
    - console.log works (thank god, no more alert debugging)
    - The layout just worked (though I think that's rather a side effect of using pixel width/height zealously rather then an IE8 virtue)
    - developer tools, any, even if they work badly, but developer tools!

    Recommendation for anyone: IE is still the worst browser, and there's at least 4 alternatives which are collectively 1) faster 2) easier to develop for 3) more compatible to each other 4) prettier 5) more standards conformant
    • by Jezral ( 449476 ) <mail@tinodidriksen.com> on Friday January 14, 2011 @10:03AM (#34876792) Homepage

      - since IE is the only browser to enforce XHR caching, every request needs a timestamp query parameter (something that no other browser does, and which is really stupid, altough easy to provide)

      Or, you could use POST requests like you're supposed to. Any number of intermediary caches and load balancing tricks can play foul with GET requests, but POST is not allowed to be cached.

      With jQuery this is as simple as using $.post() instead of $.get().

      • by pyalot ( 1197273 )

        Or, you could use POST requests like you're supposed to.

        Which in my experience are really slow in browsers as compared to GETs, especially in IE.

        Any number of intermediary caches and load balancing tricks can play foul with GET requests, but POST is not allowed to be cached.

        With jQuery this is as simple as using $.post() instead of $.get().

        Which is what http cache headers (no-cache) are here for, so any number of balancing/intermediary stuff knows what to do (except of course IE, which does not seem capable to fully talk http/1.1)

        • Or, you could use POST requests like you're supposed to.

          Which in my experience are really slow in browsers as compared to GETs, especially in IE.

          That really shouldn't be the case in any browser, unless there us something wrong with the web server, browser, a proxy in between, or some difference in caching behaviour (i.e. your GET requests are being cached somewhere unbeknownst to you so appear faster than equivalent POST requests in your tests). The amount of data sent in equivalent GET and POST requests should be more-or-less the same (i.e. the same give or take a few bytes hear or there due to encoding differences). Can you cite/show any examples

    • - Data intensive JS processing/DOM manipulation is about 10x slower then in either of the alternatives

      Any significant Javascript and/or DOM manipulation is a lot slower in IE8 than the competition. IE8 is better than IE6 in this respect but still dog slow. IE9 is said to be much more comparable to the competition in this regard, but I'll wait until it is actually released to see rather than basing expectations on the beta cycle.

      Not matter how fast IE9 is though, I'll still be stuck supporting IE6 at work as there is no way our clients (large banks) will drag themselves out of the stone age in that respect

      • I had that mentality at my previous gig until we finally convinced the USAF linguist turned infrastructure director that IE6 was on the dead pool. Of course, he then designed a 2 year project to replace it with IE8 without any user testing.

        I did some work for a major bank in 2001-2002 and I understand the frustration with slow adoption. That's one of the reasons I don't work for banks anymore.

    • >- since IE is the only browser to enforce XHR caching, every request needs a timestamp query parameter (something that no other browser does, and which is really stupid, altough easy to provide) Just set the headers right, it won't cache in that case. Here is a snippet from Java/JSP response.setHeader("Cache-Control","no-cache"); //HTTP 1.1 response.setHeader("Pragma","no-cache"); //HTTP 1.0 response.setDateHeader ("Expires", -1); //prevents caching at the proxy server
    • by yuhong ( 1378501 )

      Don't forget the lack of true XHTML support forcing people to serve them as text/html.

    • Fascinating... you realize you're talking about IE8, right? As in, released-in-2009 IE8? This article is about the IE9 beta, which is already out of date at 4 months old. IE9 isn't even in RC yet, nor did this article's author use the most recent preview build

      To address your Downsides with respect to IE9:
      - I can't speak to the hours your particular site will require, but a lot of things just work in IE9 even if I have to spoof the user-agent to keep it from saying "Nope, can't do IE, go away!"

  • I won't bother spreading these news for now, since IE apologists (yes, they exist) will defend themselves by saying that IE hasn't gone RTM yet, and is expected to reach RC soon. So that features may be missing. I won't bother saying how ridiculous it is to think that MS will implement major HTML5 features to support HTML5 Canvas well in a *release candidate* since these are, again, IE apologists, of all kinds of apologists.

    But I expect a crapstorm to be unleashed once this one goes final. MS shouldn't have

    • I defended it since it's in beta, and I prefer a combination of Firefox and Chrome. I only use IE when forced to.

      So why would it take an apologist to point out the patently obvious?

    • Are you bloody serious?
      First of all, IE9 Beta already supports the majority of Canvas. This guy found a few things that didn't work right in the build he was using (far from the newest one, FYI).
      Second, IE9 has been receiving improvements to its compatibility in many areas, including Canvas, during Beta. At least one of the bugs found was known, reported, and fixed a while ago.
      Third, it *is* still in development (beta, not RC). We (the public) are about due for another preview build drop; the currently avai

    • Hum - you do realize that already at this stage, IE is the browser with the most complete implementation of HTML5 and CSS3 right?

      MS has actually contributed *most* of the compliance tests (the official ones, not ACIDs) and have disclosed where IE doesn't *yet* pass the tests. You can run those test yourself and see if your favorite browser passes *all* of them (or even more than IE): http://samples.msdn.microsoft.com/ietestcenter/#html5Canvas [microsoft.com]

      I'm posting this using Chrome and that chart seems to be about rig

  • It is probably the only way that IE will support modern features. Ever. I am serious. Google needs to start pushing this more. Maybe the embarassment will force MS to finish their HTML5 implimentation.

  • by harmonise ( 1484057 ) on Friday January 14, 2011 @11:46AM (#34878280)

    Stop coddling this company. Don't try to get around it. Code to the standards and let IE9 fail to render if they can't implement the spec properly. Google, Apple, Mozilla, and Opera all have no problem following the spec.

    • Try telling that to your clients."I'm not making it compatible with half of the browsers out there because it's too complicated".
  • Not surprisingly, IE9 Beta is a work in progress [msdn.com].
  • Microsoft Responds (Score:5, Informative)

    by TimSneath ( 139039 ) on Friday January 14, 2011 @01:05PM (#34879580)

    Hi there, thank you for the post. I just wanted to add a few observations on behalf of the Internet Explorer team.

    Firstly, no browser offers a perfect implementation of the Canvas 2D API specification to date - we've documented and shared a few examples from our test suites here: http://samples.msdn.microsoft.com/ietestcenter/#html5Canvas [microsoft.com]

    As has been well noted, the IE9 build tested was our beta.

    Secondly, in response to the specific issues raised, Giorgio Sardo has posted a response on his blog here:
          http://blogs.msdn.com/b/giorgio/archive/2011/01/14/building-great-browsers-together.aspx [msdn.com]

    We'll update this entry over time.

    Thanks for listening,

    Tim Sneath | Microsoft Corp.

  • I wonder what would have happened if MS adopted the Tasman engine used in Mac IE 5 and ported it to Windows instead of spending years fixing the Trident engine?

  • Time to go all grammar (well, vocabulary) nazi on you....

    The word you want is Disclosure, not Disclaimer.

    A disclosure is, in this case, a statement of conflict of interest: "I wrote this thing, so I might be biased about how good it is."

    A disclaimer would be: "I wrote this thing and even I don't believe it!"

    I'm pretty sure you meant the former, not the latter,

Get hold of portable property. -- Charles Dickens, "Great Expectations"

Working...