Hmmmm.... What, exactly, do you mean by HTML snippets? In this case, the only HTML that was included in the text were <pre>
and </pre>
tags at the beginning and end, respectively. That is all that it took to cause the problem. Note, in other instances of the same class, the text field was provided with copies of HTML-encoded text -- with no problems. That suggests something about the pre tags are causing the problem.
I need the pre tags because the text is old (pre-1950) and simply formatted with carriage returns ('\n'). Otherwise, Plone renders it as HTML and takes out all the \n's and the whole text looks like a jumbled block.
NOTEZ BIEN:
I performed a few experiments, and this problem is isolated to (and so far only to) situations where the text field contains the pre tags surrounding plain text AND when the property is so loaded and the object is instantiated via the Plone API. You don't get this same problem when you create a standard Page object and use Tools | Source Code to pre/append pre tags to plain text.
The obvious work-around would be to edit the text and insert paragraph ("p") tags around the \n characters (or better yet, simply add a break tag with each \n), but I don't think that we should have to do that. What is it about the API instantiation process that causes this problem?