Automatic Insertion of Required Elements and Attributes
"garbage_goal" <[email protected]>
| Newsgroups | gmane.emacs.nxml.general |
|---|---|
| Message-ID | <[email protected]> |
Hi there,
I hope I am not posting a previously asked question, but I am not having
much luck searching on this topic.
I've been a psgml user but want to switch to nxml since psgml broke with
Emacs 24. One thing psgml does is automatically add required elements
and attributes as you go along.
For example, if I were to insert a tag <compact-disc> which requires a
"name" attribute and at least one "track" element, psgml would generate
and insert the following fragment, placing my cursor between the quotes
for the "name" element:
<compact-disc name="">
<track></track>
</compact-disc>
Is there any way to make nxml behave similarly? I've found nxml will at
least warn me if I am missing a required child element/attribute, but
then I have to remember myself which child elements/attributes are
required and begin typing them before I can take advantage of auto
completion.
I'd appreciate it if anyone can point me in the right direction. Is
there an existing feature I haven't found yet, a minor mode, perhaps
some code I could find on the internet, do I have to write this myself?
Thanks!