Constructor
+ + + +new FontFaceObserver(family, descriptors)
+ + + + + + + + + + + + + + +Parameters:
+ + +| Name | + + +Type | + + + + + +Description | +
|---|---|---|
family |
+
+
+ + + +string + + + + | + + + + + +font-family name (required) | +
descriptors |
+
+
+ + + +Descriptors + + + + | + + + + + +an object describing the variation +(optional). The object can contain `weight`, `style`, and `stretch` +properties. If a property is not present it will default to `normal`. | +
Members
+ + + +DEFAULT_TIMEOUT :number
+ + + + + + +Type:
+-
+
- + +number + + + +
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
HAS_SAFARI_10_BUG :null|boolean
+ + + + + + +Type:
+-
+
- + +null +| + +boolean + + + +
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
HAS_WEBKIT_FALLBACK_BUG :null|boolean
+ + + + + + +Type:
+-
+
- + +null +| + +boolean + + + +
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
SUPPORTS_NATIVE_FONT_LOADING :null|boolean
+ + + + + + +Type:
+-
+
- + +null +| + +boolean + + + +
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
SUPPORTS_STRETCH :null|boolean
+ + + + + + +Type:
+-
+
- + +null +| + +boolean + + + +
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Methods
+ + + + + + + +(static) getNavigatorVendor() → {string}
+ + + + + + + + + + + + + + + + + + +-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +string + + + +
(static) getUserAgent() → {string}
+ + + + + + + + + + + + + + + + + + +-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +string + + + +
(static) hasSafari10Bug() → {boolean}
+ + + + + + +-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +boolean + + + +
(static) hasWebKitFallbackBug() → {boolean}
+ + + + + + +-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +boolean + + + +
(static) supportsNativeFontLoading() → {boolean}
+ + + + + + +-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +boolean + + + +
(static) supportStretch() → {boolean}
+ + + + + + +-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +boolean + + + +
load(textopt, timeoutopt) → {Promise.<FontFaceObserver>}
+ + + + + + + + + + + + + + +Parameters:
+ + +| Name | + + +Type | + + +Attributes | + + + + +Description | +
|---|---|---|---|
text |
+
+
+ + + +string + + + + | + + +
+
+ <optional> + + + + + + |
+
+
+
+
+ Optional test string to use for detecting if a font +is available. | +
timeout |
+
+
+ + + +number + + + + | + + +
+
+ <optional> + + + + + + |
+
+
+
+
+ Optional timeout for giving up on font load +detection and rejecting the promise (defaults to 3 seconds). | +
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Source: +
- + + + + + + + +
Returns:
+ + + + +-
+
- + Type + +
- + +Promise.<FontFaceObserver> + + + +