Support » Plugins » Plugin for "add_editor_style" ?

  • Resolved klynam

    (@klynam)


    Some of my clients manage their own WP content and they don’t like the fact that fonts in the WP editor are different from their website (CSS) fonts. They would like a (more) WYSIWYG display of the DEFAULT FONT / STYLE SELECTIONS (i.e. paragraph, h1, h2, h3, ul/ol, li, etc.) in the content editor.

    Researching this idea led me to the “add_editor_style” function released with WP 3.0, but I’d really prefer NOT to do that owing to issues with theme updates which would overwrite my changes. (Yes, I understand child themes but again I try to work as simply as possible and would prefer to not create child themes for each of my client websites.)

    IS THERE A PLUG-IN that simply enables this function (add_editor_style) for the DEFAULT font / style selections in the WP content editor (while ignoring ALL other CSS styles like backgrounds, images, etc.) ???

    Thank you.

Viewing 7 replies - 1 through 7 (of 7 total)
  • esmi

    (@esmi)

    Forum Moderator

    There isn’t such a plugin that I am aware of. 🙁

    Wow – that seems like it would be relatively easy to do, and something lots of people would appreciate. It’s times like this I really wish I was a PHP developer!!!

    So is there ANY type of plugin that calls / enables the “add_editor_style” function?

    esmi

    (@esmi)

    Forum Moderator

    I guess plugin authors have shied away from this as editor-style is a theme feature and not all themes have such a stylesheet. I don’t think I’ve even come across a plugin that loads editor-style.css. Again, that’s usually left to the theme.

    Hmmm – okay, thanks for the info. I’ve used quite a few themes and all of them came with CSS definitions for the basic “system” style selections (i.e. paragraph, h1, h2, etc.) But I’ve never (ever) seen ANY of a theme’s CSS font definitions reflected in the WP content editor.

    So let me backup and try the longer road. What if…

    1. I add this to my theme’s functions.php file:
    add_editor_style('editor-style.css');
    2. I create a new file called “editor-style.css” along side the “styles.css” file
    3. I copy CSS definitions for all of the basic style selections (i.e. paragraph, h1, h2, etc.) from the theme CSS into the “editor-style.css”

    Will the basic styles (from my theme) then be reflected in my WP content editor?

    esmi

    (@esmi)

    Forum Moderator

    But I’ve never (ever) seen ANY of a theme’s CSS font definitions reflected in the WP content editor.

    Try looking at some of the themes hosted on wordpress.org.

    Will the basic styles (from my theme) then be reflected in my WP content editor?

    Yes.

    Thanks for your assistance ESMI – shalom

    esmi

    (@esmi)

    Forum Moderator

    No problem. If you go ahead with creating your own editor-style.css files and hot any problems, just drop a topic into the Themes & Templates forum. The only time when we might not be able to help is when the theme you are working with is commercial or downloaded from somewhere other than wordpress.org. We don’t have access to the former and we don’t really support the latter but we might be able make general suggesti9ons. 🙂

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Plugin for "add_editor_style" ?’ is closed to new replies.