fallback

2 views
Skip to first unread message

Simon Pieters

unread,
Feb 25, 2009, 3:21:56 AM2/25/09
to cu...@googlegroups.com

Simon Pieters

unread,
Feb 25, 2009, 3:23:03 AM2/25/09
to cu...@googlegroups.com
On Wed, 25 Feb 2009 09:21:56 +0100, Simon Pieters <zco...@gmail.com> wrote:

>

Uh, let's try that again...


Hi,

It looks like the DOM generated by cufón looks like:

<h3><span class="cufon cufon-canvas" style="width: 68px; height: 24px"><canvas width="86" height="25" style="top: -1px; left: -1px"></canvas><span class="cufon-alt">Select </span></span>...

This means that if you disable CSS you get both the canvas and the "fallback".

It would be a better if you placed the fallback inside the canvas element like so:

<h3><span class="cufon cufon-canvas" style="width: 68px; height: 24px"><canvas width="86" height="25" style="top: -1px; left: -1px">Select </canvas></span>...

--
Simon Pieters


Simo Kinnunen

unread,
Feb 25, 2009, 5:23:28 AM2/25/09
to cu...@googlegroups.com
Hi Simon,

True. But unfortunately there's a bug in Opera that prevents us from
doing that, still present in Opera 10a (yes, we've reported it). Also,
having the actual text outside of the canvas element has the
additional benefit of being able to fall back to the plain text with
just CSS when printing (canvases are, after all, only low-resolution
images and they rarely look good when printed).

Besides, I don't really see why a real user would be surfing without
CSS. Mobile browsers do not usually support canvas and if they do they
probably support CSS too.

Simo
Reply all
Reply to author
Forward
0 new messages