Class Index | File Index

Classes


Class Font

Represents a CSS Font.
Defined in: Font.js.

// Creates a new Font object
var myFont = Font({style: "bold", size: "12px", family: "Tahoma"});
// Creates a new Font with multiple families.
var myFont = Font({style: "bold", size: "12px", family: ["Tahoma", "Arial"]});
// Creates a new Font using convienence method.
var myFont = font("Tahoma", "12px", "bold");
Class Summary
Constructor Attributes Constructor Name and Description
 
Font(_details)
Method Summary
Method Attributes Method Name and Description
 
Creates a CSS string from this Font object.
Class Detail
Font(_details)

Author: Eric Berry.
Parameters:
_details
An JSON object containing the following properties:
Property Required Default
family no Tahoma
size no 12px
style no Font.Styles.normal
variant no normal
weight no Font.Weights.normal
See:
Font for more details on the CSS font property.
Method Detail
toCss()
Creates a CSS string from this Font object.
Returns:
A String in the format of: "[style] [variant] [weight] [size] [family(ies)]"

Documentation generated by JsDoc Toolkit 2.3.0 on Fri Oct 30 2009 09:09:10 GMT-0700 (PDT)