Loading ...
Sorry, an error occurred while loading the content.

565disabling xml-mode autoload in emacs (in favor of nxml-mode)

Expand Messages
  • Aaron Falk
    Jul 1, 2004
    • 0 Attachment
      Hi-

      I'm new at nxml and am working on getting it to automatically load when
      I open an XML file with emacs (21.3.50.2 powerpc-apple-darwin7.0.0).
      Right now I've put some magic in my .emacs which should autoload nxml
      (see below) but emacs overrides it when I open an XML file and goes
      into XML/SGML mode. I've looked at the SGML configuration options and
      can't see where to disable this. Of course, I can manually launch nxml
      by M-x nxml-mode but I'd like it to 'just work.'

      Any hints?

      Thanks,

      --aaron

      ============================

      nak:~ falk$ cat .emacs
      (custom-set-variables
      ;; custom-set-variables was added by Custom.
      ;; If you edit it by hand, you could mess it up, so be careful.
      ;; Your init file should contain only one such instance.
      ;; If there is more than one, they won't work right.
      '(ispell-program-name "/sw/bin/ispell")
      '(rng-schema-locating-files (quote ("schemas.xml"
      "/Users/falk/.schemas.xml"))))
      ;;;
      (custom-set-faces
      ;; custom-set-faces was added by Custom.
      ;; If you edit it by hand, you could mess it up, so be careful.
      ;; Your init file should contain only one such instance.
      ;; If there is more than one, they won't work right.
      '(default ((t (:stipple nil :background "white" :foreground "black"
      :inverse-video nil :box nil :strike-through nil :overline nil
      :underline nil :slant normal :weight normal :height 100 :width normal
      :family "apple-monaco")))))
      (require 'notes-variables)

      ;;; enable URL recognition in notes-mode
      (setq notes-w3-alternate-url 'browse-url)

      ;;; enable auto-fill in notes-mode
      ;;;(setq max-specpdl-size 32000)
      ;;;(setq max-lisp-eval-depth 32000)
      ;;;(require 'fa-extras)
      ;;;(add-hook 'notes-mode-hooks 'turn-on-filladapt-mode)

      (when (eq system-type 'darwin)
      (setq ispell-program-name "/sw/bin/ispell")
      (set-frame-font "fontset-mac")
      (set-keyboard-coding-system 'mac-roman-unix)
      ;;; (set-frame-font
      "-etl-fixed-medium-r-normal--14-140-75-75-m-140-iso8859-1")
      (modify-frame-parameters (selected-frame) '((font .
      "-*-Monaco-*-140-*"))))

      ;;; load necessary files to enable nXML major mode
      (load "/usr/share/nxml/rng-auto.el")
      (set-variable 'nxml-slash-auto-complete-flag t)
      (setq auto-mode-alist
      (cons '("\\.\\(xml\\|xsl\\|rng\\|xhtml\\)\\'" . nxml-mode)
      auto-mode-alist))
    • Show all 3 messages in this topic