Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 366429 - XML Design Editor allows editing text of node which is specified as empty by DTD
Summary: XML Design Editor allows editing text of node which is specified as empty by DTD
Status: NEW
Alias: None
Product: WTP Source Editing
Classification: WebTools
Component: wst.xml (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Salvador Zalapa CLA
QA Contact: Nick Sandonato CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-12 11:06 EST by Alex Marin CLA
Modified: 2013-06-19 11:14 EDT (History)
2 users (show)

See Also:


Attachments
A project for easy reproduction of the issue (977 bytes, application/zip)
2011-12-12 11:09 EST, Alex Marin CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Marin CLA 2011-12-12 11:06:41 EST
Build Identifier: M20110909-1335

I have an element described by the following DTD:

<!ELEMENT foo EMPTY>

Suppose in an xml file (using this DTD) I have the tag:

<foo/>

The XML Design Editor will allow me to add some text into this node.

If I validate the document at this point, the following (correct) error is reported:

The content of element type "foo" must match "EMPTY".

I'd expect it NOT to be editable due to the DTD specification of the element.

Reproducible: Always

Steps to Reproduce:
I've attached a testcase for the sake of simplicity:

1. Open NewFile.xml in the xml Design Editor
2. Edit the content of foo element
Comment 1 Alex Marin CLA 2011-12-12 11:09:04 EST
Created attachment 208266 [details]
A project for easy reproduction of the issue