Closed Bug 63164 Opened 25 years ago Closed 25 years ago

editorshell.CreateElementsWithDefaults() should be able to create non html elements.

Categories

(Core :: DOM: Editor, defect)

defect
Not set
normal

Tracking

()

VERIFIED WONTFIX

People

(Reporter: dmcnamara, Assigned: cmanske)

Details

As the editor can now handle non-html elements it follows that editorshell.CreateElementsWithDefaults() should be able to create non html elements. To reproduce: call editorshell.CreateElementsWithDefaults("duck") What happens: It currently throws a component error. Build: Mozilla 0.6
Assignee: beppe → cmanske
The error probably occurs because CreateElementWithDefaults() calls CreateHTMLContent() internally. Reassigning to cmanske@netscape.com ... I think he may have been the original author of this method. In the meantime I believe you can accomplish what you want to do by using document.createElement("duck") and then using editorShell.InsertElement() to insert it into the document.
i just tried document.createElement("duck") and that doesn't work either. i suspect editorshell.CreateElementsWithDefaults() actually calls document.createElement() on a lower level.
The editor can handle non-html elements? I don't think so -- the "rules" system assumes only HTML. We operate according to the HTML 4 DTD.
marking wontfix, the current editor model is to not allow the user to create non-html 4.0 elements.
Status: UNCONFIRMED → RESOLVED
Closed: 25 years ago
Resolution: --- → WONTFIX
The editor _can_ handle non-html elements and render them with css. It seems a shame that it cannot create non-html elements. I was hoping to create a xpfe xml-editor in this way.
verified in 1/12 build.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.