[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook] Configure Emacs to autocomplete the tags
On 2016-02-12 16:51 Dave Pawson was heard to say:
You'll need to tell emacs (nxml-mode) 1. Where your schema-locating file is (setq rng-schema-locating-files '("/sgml/schemas.xml")) 2. In that file, where to find the docbook *(rnc) schema <typeId id="DocBook" uri="docbook/v5/rng/docbookxi.rnc"/> <documentElement localName="book" uri="/sgml/docbook/v5/rng/docbookxi.rnc"/> etc 3. What associations to make (e.g. the root elements you'll be using) (setq auto-mode-alist (append (list '("\\.xml\\'" . nxml-mode) etc (defun bind-nxml-mode-keys () (define-key nxml-mode-map (kbd "<C-return>") 'completion-at-point) ;; add further customizations here )
I somehow assumed that the OP would reuse his .emacs which apparently had worked in a previous installation. But you may be right, he'll have to add this stuff if he started from scratch. I prefer to keep backups of my .emacses to avoid this toil.
regards, Markus -- Markus Hoenicka http://www.mhoenicka.de AQ score 38