all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Madore <david+news@madore.org>
To: help-gnu-emacs@gnu.org
Subject: How to avoid newline insertion / reindentation by sgml-tag (C-c C-t) in html-mode
Date: Wed, 2 Jan 2019 01:18:45 +0100	[thread overview]
Message-ID: <q0h015$1966$1@saria.nerim.net> (raw)

Dear group,

I only recently upgraded from Emacs 24.5 to 25.1.  One of the changes 
which is causing me considerable pain is that the html-mode (which I use 
a lot to edit XHTML files) now tries to perform some kind of 
reindentation whenever a tag is inserted by the sgml-tag (C-c C-t) 
function.  In particular, a line break appears to be inserted whenever 
there is a following closed tag.

I would like no such reindentation to occur.  For example, if I type 
"C-c C-t em" between <p> and </p> (say), I would just like for "<em>" to 
be inserted before the point and "</em>" after, with no changes to 
indentation or anything else, and certainly no extra newline character.

I tried understanding sgml-mode.el but it is way beyond my knowledge of 
Emacs Lisp; and I don't see in the diff between the 24.5 and 25.1 
versions anything pertaining to identation that would explain the 
difference.  I even tried using the 24.5 version of sgml-mode.el but it 
did not revert to the previous behavior (so I assume the difference 
comes from somewhere else but I don't even know where to start looking).

Does anybody know how I can revert to the previous behaviour and avoid 
the spurious insertion of newlines by the sgml-tag function?

Failing that, can anybody suggest some way to get help on this 
particular issue?

Many thanks in advance for any advice,

-- 
      David A. Madore
WWW: http://www.madore.org/~david/



             reply	other threads:[~2019-01-02  0:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-02  0:18 David Madore [this message]
2019-01-02 13:14 ` How to avoid newline insertion / reindentation by sgml-tag (C-c C-t) in html-mode Stephen Berman

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='q0h015$1966$1@saria.nerim.net' \
    --to=david+news@madore.org \
    --cc=help-gnu-emacs@gnu.org \
    /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.