help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using html-quick-keys with nxml-mode


From: Kevin Rodgers
Subject: Re: Using html-quick-keys with nxml-mode
Date: Thu, 04 Mar 2004 09:32:10 -0700
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2

Steffen Glu"ckselig wrote:
> I am new to emacs and plan to mainly use it for publishing xhtml. I've
> got the TEI-emacs-package and set up nxml-mode to be associated with
> html-files (I have not converted to the xhtml-extension yet).  I've
> noticed in html-mode there is an entry in the menu-bar (HTML) that
> holds some html-elements associated to hotkeys to place them into the
> source.
>
> I would like to have that menu-entry and the shortcuts available in
> nxml-mode, too. Is that possible? I've noticed that the entries are
> defined in sgml-mode.el. Could I link that definition to the
> nxml-mode?  How so?

Most of the HTML menu-bar commands in sgml-mode.el are defined as
skeletons, so I think they could be used in any other major mode.  It
might be as simple as this:

(require 'sgml-mode)    ; for html-mode-map
(define-key nxml-mode-map [menu-bar html]
  (lookup-key html-mode-map [menu-bar html]))

> Or should I switch back to sgml/html-mode, though my documents are
> actually xhtml?

I haven't tried it yet, but I suspect nxml-mode is better for XHTML
documents.  You might also want to ask on the emacs-nxml-mode discussion
group: http://groups.yahoo.com/group/emacs-nxml-mode/

--
Kevin Rodgers



reply via email to

[Prev in Thread] Current Thread [Next in Thread]