Hi, I'm building a site using Google's new embeddable Font API, and I wanted to add these fonts to the font-family dropdown in the CKeditor UI, but there didn't seem to be an easy way to do this.
What I ultimately did was change the list at the end of line 51 of ckeditor/ckeditor/ckeditor.js to something like: i.font_names='Arial/Arial, Helvetica, sans-serif;Comic Sans MS/Comic Sans MS, cursive;Courier New/Courier New, Courier, monospace;Georgia/Georgia, serif;Lucida Sans Unicode/Lucida Sans Unicode, Lucida Grande, sans-serif;Tahoma/Tahoma, Geneva, sans-serif;Times New Roman/Times New Roman, Times, serif;Trebuchet MS/Trebuchet MS, Helvetica, sans-serif;Verdana/Verdana, Geneva, sans-serif; Josefin Sans Std Light/Josefin Sans Std Light; Molengo/Molengo; Cantarell/Cantarell';
This is a quick fix and will obviously break on update, so it'd be nice to see this feature built into the CKeditor admin UI eventually, especially for those who know that these embedded fonts will be available on every webpage of the site.
Cheers, Dakota
| Comment | File | Size | Author |
|---|---|---|---|
| Screen shot 2010-06-09 at 6.45.47 PM.png | 51.58 KB | dakotaryan |
Comments
Comment #1
mephir commentedAIn ckeditor setting you have got variable font_name. You can add it into ckeditor.config.js or in advanced javascript configuration into profile. Sample line:
You shouldn't change core files.
If you have any lack of clarity about issue, feel free to reopen it.