From: "Stefan-W. Hahn" <stefan.hahn@s-hahn.de>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 17281@debbugs.gnu.org
Subject: bug#17281: 24.4.50; emacs hangs in next-line
Date: Thu, 17 Apr 2014 13:00:47 +0200 [thread overview]
Message-ID: <20140417110047.GE23131@pille.home> (raw)
In-Reply-To: <83r44wi7l7.fsf@gnu.org>
Mail von Eli Zaretskii, Thu, 17 Apr 2014 at 13:16:52 +0300:
> Btw, just FYI, this code:
>
> (defun test ()
> (interactive)
> (goto-char (point-min))
> (save-match-data (re-search-forward "^$" nil t))
> (next-line 1))
>
> doesn't do what you think. next-line does TRT for the selected
> window, but in this case the mode function 'test' runs when the buffer
> that visits the file is not yet displayed in any window, certainly not
> in the selected one. You want to call forward-line instead.
Thx.
It's just an excerpt from
; $Id: post.el,v 1.10 2008/02/24 23:49:23 rreid Exp $
;; post.el --- Use (X?)Emacs(client) as an external editor for mail and news.
#+BEGIN_SRC elisp
(defun post-goto-body ()
"Go to the beginning of the message body."
(interactive)
(goto-char (point-min))
;; If the message has header, slide downward.
(and header-mode (save-match-data (re-search-forward "^$" nil t))
(next-line 1))
)
#+END_SRC
Is there a better mode for writing emails (I use mutt calling emacs for
that).
With kind regards,
Stefan
--
Stefan-W. Hahn It is easy to make things.
It is hard to make things simple.
next prev parent reply other threads:[~2014-04-17 11:00 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-17 6:10 bug#17281: 24.4.50; emacs hangs in next-line Stefan-W. Hahn
2014-04-17 7:13 ` Eli Zaretskii
2014-04-17 7:25 ` Stefan-W. Hahn
2014-04-17 8:00 ` Eli Zaretskii
2014-04-17 8:29 ` Stefan-W. Hahn
2014-04-17 9:03 ` Eli Zaretskii
2014-04-17 10:16 ` Eli Zaretskii
2014-04-17 11:00 ` Stefan-W. Hahn [this message]
2014-04-17 11:25 ` Eli Zaretskii
2014-04-17 12:39 ` Stefan Monnier
2014-04-17 12:37 ` Stefan Monnier
2014-04-17 12:47 ` Eli Zaretskii
2014-04-17 13:16 ` Stefan Monnier
2014-04-17 12:56 ` Stefan-W. Hahn
2014-04-17 13:13 ` Eli Zaretskii
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140417110047.GE23131@pille.home \
--to=stefan.hahn@s-hahn.de \
--cc=17281@debbugs.gnu.org \
--cc=eliz@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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).