PHP Class Kirki_Fonts_Google, kirki

ファイルを表示 Open project: aristath/kirki Class Usage Examples

Public Properties

Property Type Description
$force_load_all_subsets boolean If set to true, forces loading ALL subsets.
$force_load_all_variants boolean If set to true, forces loading ALL variants.

Public Methods

Method Description
enqueue ( ) Calls all the other necessary methods to populate and create the link.
get_instance ( ) : object Get the one, true instance of this class.

Private Methods

Method Description
__construct ( ) The class constructor.
create_link ( ) Creates the google-fonts link.
generate_google_font ( array $args ) Processes the arguments of a field determines if it's a typography field and if it is, then takes appropriate actions.
loop_fields ( ) Goes through all our fields and then populates the $this->fonts property.
process_fonts ( ) Determines the vbalidity of the selected font as well as its properties.

Method Details

enqueue() public method

Calls all the other necessary methods to populate and create the link.
public enqueue ( )

get_instance() public static method

Prevents performance issues since this is only loaded once.
public static get_instance ( ) : object
return object Kirki_Fonts_Google

Property Details

$force_load_all_subsets public_oe static_oe property

If set to true, forces loading ALL subsets.
public static bool $force_load_all_subsets
return boolean

$force_load_all_variants public_oe static_oe property

If set to true, forces loading ALL variants.
public static bool $force_load_all_variants
return boolean