Any way to force filebrowser content completion for RNG hrefs?
Posted: Mon Sep 10, 2018 4:54 pm
I have an attribute @href, used to refer to the URIs of external documents and defined in my RelaxNG schema like this:
There are also ID attributes on other elements in my schema defined as "<data type="ID"/>". When I open an instance document and add an href attribute, the content completion dropdown initially offers the values of these IDs (e.g. "#foo,#bar,#baz") rather than the filebrowser dropdown.
If I use the 'Learn Structure' menu option on my instance document, then subsequent hrefs _do_ display the filebrowser dropdown (I guess because it has correctly observed that other hrefs in the document contain file paths).
Is there any way to force the filebrowser behaviour? Ideally, is there something I could add to the RNG schema that would have the desired effect? I do already have a document type association for these documents, but would rather avoid writing any plugin code if at all possible.
Code: Select all
<attribute name="href">
<data type="anyURI"/>
</attribute>
If I use the 'Learn Structure' menu option on my instance document, then subsequent hrefs _do_ display the filebrowser dropdown (I guess because it has correctly observed that other hrefs in the document contain file paths).
Is there any way to force the filebrowser behaviour? Ideally, is there something I could add to the RNG schema that would have the desired effect? I do already have a document type association for these documents, but would rather avoid writing any plugin code if at all possible.