FontFace::FontFace(ExecutionContext* context, const AtomicString& family, const FontFaceDescriptors& descriptors) : ActiveDOMObject(context) , m_family(family) , m_status(Unloaded) { Document* document = toDocument(context); setPropertyFromString(document, descriptors.style(), CSSPropertyFontStyle); setPropertyFromString(document, descriptors.weight(), CSSPropertyFontWeight); setPropertyFromString(document, descriptors.stretch(), CSSPropertyFontStretch); setPropertyFromString(document, descriptors.unicodeRange(), CSSPropertyUnicodeRange); setPropertyFromString(document, descriptors.variant(), CSSPropertyFontVariant); setPropertyFromString(document, descriptors.featureSettings(), CSSPropertyFontFeatureSettings); suspendIfNeeded(); }
FontFace::FontFace(ExecutionContext* context, const AtomicString& family, const FontFaceDescriptors& descriptors) : ActiveDOMObject(context) , m_family(family) , m_status(Unloaded) { Document* document = toDocument(context); setPropertyFromString(document, descriptors.style(), CSSPropertyFontStyle); setPropertyFromString(document, descriptors.weight(), CSSPropertyFontWeight); // FIXME: we don't implement 'font-strech' property yet so we can't set the property. setPropertyFromString(document, descriptors.unicodeRange(), CSSPropertyUnicodeRange); setPropertyFromString(document, descriptors.variant(), CSSPropertyFontVariant); setPropertyFromString(document, descriptors.featureSettings(), CSSPropertyWebkitFontFeatureSettings); suspendIfNeeded(); }