Skip to content

Commit 971bee4

Browse files
committed
Merge pull request mozilla#2451 from brendandahl/opentype-warn
Warn on opentype fonts.
2 parents b4adbe4 + 6ae1355 commit 971bee4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/fonts.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2303,6 +2303,11 @@ var Font = (function FontClosure() {
23032303
type = 'Type1';
23042304
if (subtype == 'CIDFontType0C' && type != 'CIDFontType0')
23052305
type = 'CIDFontType0';
2306+
// XXX: Temporarily change the type for open type so we trigger a warning.
2307+
// This should be removed when we add support for open type.
2308+
if (subtype === 'OpenType') {
2309+
type = 'OpenType';
2310+
}
23062311

23072312
var data;
23082313
switch (type) {
@@ -2327,7 +2332,7 @@ var Font = (function FontClosure() {
23272332
break;
23282333

23292334
default:
2330-
warn('Font ' + properties.type + ' is not supported');
2335+
warn('Font ' + type + ' is not supported');
23312336
break;
23322337
}
23332338

0 commit comments

Comments
 (0)