Fonts Plugin 4.2.3 has 3 actions and 15 filters, read directly from its source code on Nov 17, 2026. The list updates automatically when a new version is released.
How to use these hooks
Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.
// Run your own code when Fonts Plugin fires an action
add_action( 'ogf_after_inline_styles', function() {
// Your code runs here.
}, 10, 1 );
// Change a value Fonts Plugin is about to use
add_filter( 'ogf_load_classic_editor_integration', function( $value, $screen ) {
// Change $value here.
return $value;
}, 10, 2 );Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.
All hooks
-
/** * Short-circuit Classic Editor integration for a screen. */ apply_filters( 'ogf_load_classic_editor_integration', null, $screen ); -
plinth_setting_control
filterapply_filters( 'plinth_setting_control', $html, $key, $this->definitions[ $key ] ); -
ogf_{$font_id}_stack
filterapply_filters( "ogf_{$font_id}_stack", $stack ); -
ogf_after_inline_styles
actiondo_action( 'ogf_after_inline_styles' ); -
ogf_classic_font_formats
filterapply_filters( 'ogf_classic_font_formats', 'Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Trebuchet MS=trebuchet ms,geneva;Ver... ); -
ogf_classic_font_sizes
filterapply_filters( 'ogf_classic_font_sizes', $args ); -
apply_filters( 'ogf_default_font_style_choices', $choices ); -
apply_filters( 'ogf_default_font_weight_choices', $choices ); -
apply_filters( 'ogf_default_text_transform_choices', $choices ); -
ogf_elements
filterapply_filters( 'ogf_elements', $elements ); -
ogf_gutenberg_elements
filterapply_filters( 'ogf_gutenberg_elements', $elements ); -
ogf_gutenberg_inline_styles
actiondo_action( 'ogf_gutenberg_inline_styles' ); -
ogf_inline_styles
actiondo_action( 'ogf_inline_styles' ); -
ogf_show_news
filterapply_filters( 'ogf_show_news', true ); -
ogf_system_fonts
filterapply_filters( 'ogf_system_fonts', $system_fonts ); -
apply_filters( 'ogf_typography_control_settings', array( 'family' => $id . '_font', 'weight' => $id . '_font_weight', 'style' => $id . '_font_style', 'size' => $id . '_font_size', 'size_tablet' => $id . '_font_size_tablet', 'size_mobile' => $id . '_font_size_mobile', 'line_height' => $id . '_line_height', 'line_height_tablet' => $id . '_line_height_tablet', 'line_height_mobile' => $id . '_line_height_mobile', 'color' => $id . '_font_color', 'l... ); -
plinth_setting_label
filterapply_filters( 'plinth_setting_label', $label_html, $key, $def );
Generated from Fonts Plugin's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.
Can't find the right hook?
We can build the customisation for you. Describe what you need: