all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Jim Paris <jim@jtan.com>
To: Andreas Schwab <schwab@linux-m68k.org>
Cc: 6758@debbugs.gnu.org, "Johan Bockgård" <bojohan@gnu.org>
Subject: bug#6758: 23.2; xterm.el: please provide an option to not discard input in terminal-init-xterm
Date: Mon, 2 Aug 2010 17:36:18 -0400	[thread overview]
Message-ID: <20100802213618.GA7767@psychosis.jim.sh> (raw)
In-Reply-To: <m2sk2wogby.fsf@igel.home>

Andreas Schwab wrote:
> Jim Paris <jim@jtan.com> writes:
> 
> > +    ;; The reply should be of the form: \e ] 11 ; rgb: NUMBER1 / NUMBER2 / NUMBER3 \e \\
> > +    (while (not (equal (setq chr (read-char)) ?\\))
> > +      (setq str (concat str (string chr))))
> 
> At least this loop needs to have a timeout, in case the terminator
> character gets lost for whatever reason.
> 
> > +    ;; The reply should be of the form: \e [ > NUMBER1 ; NUMBER2 ; NUMBER3 c
> > +    (while (not (equal (setq chr (read-char)) ?c))
> > +      (setq str (concat str (string chr))))
> 
> Likewise.  (It isn't all that hard to type ESC [ > by accident).

Ok, (read-char) can be replaced with (read-event nil nil 2).  There
may also need to be a (let (coding-system-for-read 'binary)) in there
somewhere -- I'm really not familiar with emacs programming, this is
mostly just based on other code I've found (like xt-mouse.el)

-jim





  reply	other threads:[~2010-08-02 21:36 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-29 20:15 bug#6758: 23.2; xterm.el: please provide an option to not discard input in terminal-init-xterm Jim Paris
2010-08-01 23:03 ` Stefan Monnier
2010-08-02 20:38   ` Johan Bockgård
2010-08-02 20:59   ` Jim Paris
2010-08-02 21:27     ` Andreas Schwab
2010-08-02 21:36       ` Jim Paris [this message]
2010-08-02 22:21     ` Stefan Monnier
2010-08-03 20:14       ` Jim Paris
2010-08-24  0:48         ` Jim Paris
2010-09-11 14:08           ` Stefan Monnier
2010-09-11 14:59           ` Stefan Monnier
2013-03-11 14:12           ` Stefan Monnier
2012-06-17  5:28 ` Chong Yidong
2012-06-19  4:03 ` bug#6758: So what do I need to do to keep emacs from eating my typeahead? Karl O. Pinc
2012-06-19  7:51   ` Glenn Morris

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=20100802213618.GA7767@psychosis.jim.sh \
    --to=jim@jtan.com \
    --cc=6758@debbugs.gnu.org \
    --cc=bojohan@gnu.org \
    --cc=schwab@linux-m68k.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.