Skip to content
Permalink
Browse files

:hover is here!

  • Loading branch information...
sorccu committed Mar 18, 2009
1 parent 16ccb67 commit 4c41c0f5a9d5b469977fe2d21dc14696ab9ac29e
Showing with 6 additions and 5 deletions.
  1. +6 −5 js/cufon.js
@@ -890,17 +890,16 @@ Cufon.registerEngine('vml', (function() {

var shadows = options.textShadow;

for (var i = 0, l = chars.length; i < l; ++i) {
for (var i = 0, k = -1, l = chars.length; i < l; ++i) {

var glyph = font.glyphs[chars[i]] || font.missingGlyph;
var glyph = font.glyphs[chars[i]] || font.missingGlyph, shape;
if (!glyph) continue;

if (!glyph.typeRef) createType(glyph, viewBox);

var shape;

if (redraw) {
shape = canvas.childNodes[i];
// some glyphs may be missing so we can't use i
shape = canvas.childNodes[++k];
}
else {
shape = document.createElement('cvml:shape');
@@ -934,6 +933,8 @@ Cufon.registerEngine('vml', (function() {
}
canvas.appendChild(shadowNode);
}

++k;
}

advance = Number(glyph.w || font.w) + letterSpacing;

0 comments on commit 4c41c0f

Please sign in to comment.
You can’t perform that action at this time.