Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted October 19, 20195 yr Hi all, I currently add some custom fonts to our board using the custom css file in the theme manager. It works brilliantly, but the only issue is that to use these fonts users need to have HTML enabled so that they can refer to the custom font-family via code. Eg: <p style="font-family: 'CustomFont';">Some text</p> For security reasons I'd like to cut down on the number of users who can see/post in HTML - so I was wondering if there is a way to add this "CustomFont" in to the Font selector in the editor as shown below? I don't mind diving in to the PHP files if that is the only way to change this list, so please let me know if it is possible Cheers
October 21, 20195 yr Hello, Default fonts applications\core\interface\ckeditor\ckeditor\ckeditor.js CKEDITOR.config.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", You can add fonts in that file or in the config file \applications\core\interface\ckeditor\ckeditor\config.js
October 22, 20195 yr Author On 10/21/2019 at 6:26 AM, newbie LAC said: Hello, Default fonts applications\core\interface\ckeditor\ckeditor\ckeditor.js CKEDITOR.config.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", You can add fonts in that file or in the config file \applications\core\interface\ckeditor\ckeditor\config.js This worked! Thanks a lot I've noticed that in "CKEDITOR.config.font_names=", I can place it in to the list and it will allow users to select it and it will look OK inside of the editor, however in the font list it appears in default Arial/Verdana font. Is there a way to make this font display with its custom font/appearance in the font list?
October 22, 20195 yr Include your fonts in applications\core\interface\ckeditor\ckeditor\contents.css
October 22, 20195 yr Author 1 hour ago, newbie LAC said: Include your fonts in applications\core\interface\ckeditor\ckeditor\contents.css So, putting it in here didn't seem to change anything really - however placing it in the editor's other .css file... applications\core\interface\ckeditor\ckeditor\skins\ips\editor.css ... did work! Thanks for pointing me in the right direction. 😁
Archived
This topic is now archived and is closed to further replies.