Responsive 2D table

For WeatherSupermarket I need to layout a grid forecasts for five days for up to six providers, Met Office, AccuWeather etc. I have the providers vertically, each with the location, and a dropdown box to change the location. The days are laid out horizontally. This has always worked fine for Desktop browsers with plenty of… Continue reading Responsive 2D table

Assorted IE8 polyfills: forEach, trim, placeholders

I ended up using all of the following during recent development of weathersupermarket 2.0 and another site. Array.prototype.forEach() implemented using a for loop and fn.apply if (typeof Array.prototype.forEach !== ‘function’) { Array.prototype.forEach = function(callback, context) { for (var i = 0; i < this.length; i++) { callback.apply(context, [ this[i], i, this ]); } }; }… Continue reading Assorted IE8 polyfills: forEach, trim, placeholders

Scrolling waterfalls in HTML5

A number of technical domains use scrolling data displays, like the COTS octopus-760 sonar system. A typical implementation would involve a cyclic buffer (BufferedImage, pixmap etc) and two paint operations for efficiency. The means data can be inserted cheaply without the need to move the existing data. For example, this is what a cyclic buffer… Continue reading Scrolling waterfalls in HTML5

HTML support in JEditorPane

…is sadly lacking. Only HTML 3.2 features are supported, meaning HTML 4.01 niceties like having vertical-align attribute in CSS do not work. Amazingly the bug report on this is now 11 years old.

Published
Categorized as geek Tagged ,