Tinymce adding in <p> </p> tags before and after inline macros

Hi, I'm running V4.0.1 of Umbraco and when inserting macros into the HTML editor empty parapraphs are being inserted before and after the macro code such as below:

Macro inserted > Update > Save and publish (this also happens when you just click Update and reopen the HTML editor without saving)

<div class="umbMacroHolder" title="This is rendered content from macro" umbpageid="1676" umbversionid="90a0747f-dafe-4f7d-88e3-e366c823e641" onresizestart="return false;" ismacro="true" umb_macroalias="EventsList"><!-- startUmbMacro --><span>This macro does not provides rendering in WYSIWYG editor</span><!-- endUmbMacro --></div>

Reopen HTML editor

<p> </p>
<div class="umbMacroHolder" title="This is rendered content from macro" umbpageid="1676" umbversionid="90a0747f-dafe-4f7d-88e3-e366c823e641" onresizestart="return false;" ismacro="true" umb_macroalias="EventsList"><!-- startUmbMacro --><span>This macro does not provides rendering in WYSIWYG editor</span><!-- endUmbMacro --></div>
<p> </p>

I've had to edit the tinyMceConfig.config file to stop Tinymce ripping out empty table cells, and I've had a look in there and can't see anything obvious in there which would disable it. I have also looked on the Tinymce forum but with no luck.

Also, Tinymce is also wrapping img tags within parapraphs, if anyone knows how to stop this happening automatically that would be great to know.

Does anyone have any insight into how to stop Tinymce from doing these particular <p> cleanups?

Many thanks in advance,

Oliver.


This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/4224-tinymce-adding-in-p-p-tags-before-and-after-inline-macros