This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
When a XML uses a schema that includes another schema that defines the root node, then the auto-completion fails <?xml version="1.0" encoding="utf-8"?> <rootnode xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="schema.xsd"> <!-- NetBeans suggests nothing here --> <!-- While it actually validates well --> <subnode>auio</subnode> </rootnode> <?xml version="1.0"?> <xs:schema version="1.0" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> <xs:include schemaLocation="included.xsd"/> </xs:schema> <?xml version="1.0"?> <xs:schema version="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> <xs:element name="rootnode"> <xs:complexType mixed="true"> <xs:sequence> <xs:element name="subnode" minOccurs="1" maxOccurs="1"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:pattern value="[aeiouy]+"/> </xs:restriction> </xs:simpleType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> </xs:schema> If the XML uses directly included.xsd, then the auto-completion works <?xml version="1.0" encoding="utf-8"?> <rootnode xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="included.xsd"> <!-- These will be suggested by NetBean's autocompletion --> <subnode>auio</subnode> </rootnode> I'm not sure whether it's a NB bug or a normal XML schema behavior.
Created attachment 162051 [details] Showcase
Support for xs:include and xs:import was missing from the underlying model. Implemented in jet-main#0e7654675b8b
Integrated into 'main-silver', will be available in build *201703160002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/0e7654675b8b User: Svata Dedic <sdedic@netbeans.org> Log: #268029: Added read support for xs:include/import. Updated completion