=== TinyMCE Custom Styles === Contributors: blackbam, Tim Reeves Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=NBW9FDZHW42GY Tags: tinymce, advanced, visual, editor, style, custom Requires at least: 3.0.1 Tested up to: 4.9.1 Stable tag: trunk License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Improve TinyMCE visual editor by adding custom editor stylesheets and a configurable styles dropdown. == Description == Clients and colleagues tend to get crazy if they have to edit HTML code on their own or if little things are not working as expected. Make your editing experience as simple and good as possible! This Plugin does two things for you: **A.** Installs two files - editor-style.css and editor-style-shared.css - into your chosen location (so you can still do updates of the Plugin), which can be edited in the backend of your site. - editor-style.css is used for styling your TinyMCE Editor - editor-style-shared.css is used for styles to be used in your theme AND in your TinyMCE editor (so you do not have to copy) Note: To use this feature, you have to write your own CSS code into these files, which is the only professional way to do it. **B.** The main feature of this Plugin is to offer a GUI to create custom style formats for TinyMCE dynamically. - Easy to add, change and delete - No editing of source code required - Note that each style can have both CSS Classes and/or CSS Inline-Styles. The latter (excepting color) will even be applied to the Formats dropdown menu items. However, I do not recommend inline styles as they are inserted into the text of the post/page and remain unchanged if you later alter the style in the plugin settings - so in general stick to Classes! **How the two stylesheets are applied** The *shared style sheet* file is enqueued to be included on frontend pages (via the usual tag in the area) using the standard WordPress function wp_enqueue_style. So, as with most other stylesheets, the statements in it will automatically apply to the whole HTML page. So define class names which will not collide with any already in use by the theme – and never define styles for html elements without a limiting class name which would apply to all elements of that tag type. Bad: li { font-size: 2em; } Good: li.myownlarge { font-size: 2em; } *Both stylesheets* are passed to tinyMCE by calling: add_filter(‘mce_css’, …) What this causes to happen is that they are linked in to the HTML document which is the source for an