all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Friedrich Laher <fritz.laher@schmieder-laher.de>
Subject: Re: editing html - auto insert end tags
Date: Thu, 18 Aug 2005 13:02:41 +0200	[thread overview]
Message-ID: <43046AD1.802@schmieder-laher.de> (raw)
In-Reply-To: <weQMe.7554$4y6.6022@newsfe7-gui.ntli.net>

just some idea

(setq htmlTagWriting nil)

(defun htmlOpeningTag () (interactive)

  (insert     "<>") (setq htmlStartTagMarkEnd (point-marker))
  (backward-char 1) (setq htmlStartTagMarkBeg (point-marker))

  (setq htmlTagWriting t)
)
(defun htmlClosingTag () (interactive)

  (when  htmlTagWriting

     (goto-char htmlStartTagMarkEnd)

     (insert "</" (buffer-substring htmlStartTagMarkBeg 
htmlStartTagMarkEnd) )

     (goto-char htmlStartTagMarkEnd)

     (setq htmlTagWriting nil)
 )
)
(local-set-key "<" 'htmlOpeningTag)
(local-set-key [tab] 'htmlClosingTag)



chris wrote:

> Gian Uberto Lauri wrote:
>
>>>>>>> "c" == chris  <spamoff.danx@ntlworld.com> writes:
>>>>>>
>>
>> c> Hi, Does anyone know of a html mode that will auto insert the end
>> c> tags as I type.  If <html> is typed, it'll add </html> straight
>> c> away?
>>
>> html-helper-mode does something like this for some tags...
>
>
> Do you have to turn it on manually?  I have html-helper-mode here but 
> it doesn't do it.  I had a look for a more recent version, but there 
> are loads of pages out there hosting it all with varying versions.
>
>
> Thanks,
> Chris
> _______________________________________________
> Help-gnu-emacs mailing list
> Help-gnu-emacs@gnu.org
> http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
>

  reply	other threads:[~2005-08-18 11:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-17 22:55 editing html - auto insert end tags chris
2005-08-17 23:03 ` Lennart Borgman
2005-08-17 23:30 ` Gian Uberto Lauri
     [not found] ` <mailman.4112.1124321986.20277.help-gnu-emacs@gnu.org>
2005-08-18  0:02   ` chris
2005-08-18 11:02     ` Friedrich Laher [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-08-17 23:16 Dave Humphries
     [not found] <mailman.4110.1124321756.20277.help-gnu-emacs@gnu.org>
2005-08-19 21:47 ` chris
2005-08-20  9:33 ` David Hansen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=43046AD1.802@schmieder-laher.de \
    --to=fritz.laher@schmieder-laher.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.