Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google fonts and TinyMCE

Tags:

css

fonts

tinymce

Can google fonts be used with tinyMCE? how can this be done?

like image 437
tzador Avatar asked Nov 17 '10 03:11

tzador


People also ask

How do I change font size in TinyMCE?

Font size selection The TinyMCE rich text editor comes with 7 font size options by default, ranging from 8pt to 36pt. Depending on how TinyMCE is configured, users can select a font from the menubar or toolbar (via the fontsizeselect dropdown). A user selects a font size from the fontsizeselect toolbar menu.

What is TinyMCE plugin?

TinyMCE is an incredibly powerful, flexible and customizable rich text editor. This section will help you configure and extend your editor instance. Contribute to this page.


1 Answers

There is also one more, probably the easiest way to insert google fonts into tinyMCE.

In tinyMCE.init specify as follows:

content_css : "/tinymce_stylesheet.css,http://fonts.googleapis.com/css?family=Sanchez"

And then in tinymce_stylesheet.css you can use any font you imported from Google.

One more tip: Instead of writing new stylesheet from scratch, duplicate the file:

tiny_mce/themes/advanced/skins/default/content.css

...And change the font-family there.

like image 182
kogitoja Avatar answered Oct 06 '22 20:10

kogitoja