Web Standards Are Awful
Sunday 9th November, 2014 15:40 Comments: 0
I've decided I'm going to abandon implementing vertical scrolling text. Sure, I'm 99% there using the rather dodgy marquee tag, which seems to work fine in IE, Chrome and Firefox, but I had to add a load of line breaks to the end as a workaround because I couldn't get it to stop looping, and using JavaScript to dynamically change the scrollAmount in Firefox doesn't work (possibly broken as of Firefox 27, apparently using setAttribute may work instead). The text scrolls slightly faster in Chrome than IE too. I think I'll just fade paragraphs of text in and out, which also allows me greater control over when the text appears so I won't leave Chrome users looking at a blank page for several seconds near the end.
I didn't particularly like using the marquee tag, it's old and bad and reminds me of the IE4 days. But support for a marquee effect in CSS3 have been abandoned. They claim "a somewhat similar effect of moving text can be achieved with generic CSS animations", which is a working draft (and hasn't been updated in almost TWO YEARS). I may have a play with animations, but it would require IE users to have IE 10 or higher (I'm hoping to make something that will work in IE8 and 9, and I'm hoping to avoid using webkit and moz prefixes).
I finally got a font to work too. Apparently, IE doesn't like to load TTF files. When I converted the TTF file into an EOT file IE was happy, but Chrome wasn't (apparently IE can sometimes get unhappy too). I then converted the TTF to a WOFF file and both browsers are happy now (although I had to add the WOFF MIME type to IIS). It seems like several standards have been created that are inconsistently supported by the browsers, so developers presumably end up converting a file to all the standards and let the legacy browsers decide which formats they can use. At least WOFF, which became a W3C recommendation in December 2012 and appears to be the proper way forward, seems to be supported by all modern browsers (sorry IE8!).
I didn't particularly like using the marquee tag, it's old and bad and reminds me of the IE4 days. But support for a marquee effect in CSS3 have been abandoned. They claim "a somewhat similar effect of moving text can be achieved with generic CSS animations", which is a working draft (and hasn't been updated in almost TWO YEARS). I may have a play with animations, but it would require IE users to have IE 10 or higher (I'm hoping to make something that will work in IE8 and 9, and I'm hoping to avoid using webkit and moz prefixes).
I finally got a font to work too. Apparently, IE doesn't like to load TTF files. When I converted the TTF file into an EOT file IE was happy, but Chrome wasn't (apparently IE can sometimes get unhappy too). I then converted the TTF to a WOFF file and both browsers are happy now (although I had to add the WOFF MIME type to IIS). It seems like several standards have been created that are inconsistently supported by the browsers, so developers presumably end up converting a file to all the standards and let the legacy browsers decide which formats they can use. At least WOFF, which became a W3C recommendation in December 2012 and appears to be the proper way forward, seems to be supported by all modern browsers (sorry IE8!).