all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Richard Stallman <rms@gnu.org>
To: emacs-devel@gnu.org
Subject: Re: Fix previous-button to work with connected buttons
Date: Sun, 01 Apr 2007 10:00:01 -0400	[thread overview]
Message-ID: <E1HY0bB-0006rs-OS@fencepost.gnu.org> (raw)
In-Reply-To: <87648gzv45.fsf@x3y2z1.net> (message from Diane Murray on Sun, 01 Apr 2007 04:28:10 +0200)

Would someone please install this, if it is correct, and then ack?

Date: Sun, 01 Apr 2007 04:28:10 +0200
From: Diane Murray <disumu@x3y2z1.net>
To: emacs-devel@gnu.org
Subject: Re: Fix previous-button to work with connected buttons

The latest changes to button.el have added a new distinct button
property which makes it possible to correctly determine that
neighboring buttons are different and to navigate through them even
when they are right next to each other.  There is still one little
bug, however, which I corrected in a patch I sent in my original email
- the problem it fixes is that any previous adjacent button is
skipped.  Please see the patch below with a new diff from the latest
revision.


2007-04-01  Diane Murray  <disumu@x3y2z1.net>

	* button.el (previous-button): Fixed to work correctly when two
	buttons are next to each other.


*** button.el	28 Mar 2007 03:20:30 -0000	1.23
--- button.el	1 Apr 2007 02:21:12 -0000
***************
*** 372,378 ****
    (unless count-current
      (setq pos (previous-single-char-property-change pos 'button)))
    (and (> pos (point-min))
!        (or (button-at (1- pos))
  	   ;; We must have originally been on a button, and are now in
  	   ;; the inter-button space.  Recurse to find a button.
  	   (previous-button pos))))
--- 372,378 ----
    (unless count-current
      (setq pos (previous-single-char-property-change pos 'button)))
    (and (> pos (point-min))
!        (or (button-at pos)
  	   ;; We must have originally been on a button, and are now in
  	   ;; the inter-button space.  Recurse to find a button.
  	   (previous-button pos))))


_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

  reply	other threads:[~2007-04-01 14:00 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-10 23:53 Fix previous-button to work with connected buttons Diane Murray
2007-03-11  2:08 ` Stefan Monnier
2007-03-11  2:45   ` Miles Bader
2007-03-11  6:00     ` Stefan Monnier
2007-03-11  6:12       ` Miles Bader
2007-03-11 10:55         ` David Kastrup
2007-03-11 12:53           ` Miles Bader
2007-03-11 13:04             ` David Kastrup
2007-03-11 21:46         ` Stefan Monnier
2007-03-11 22:52           ` Miles Bader
2007-04-01  2:28 ` Diane Murray
2007-04-01 14:00   ` Richard Stallman [this message]
2007-04-01 17:15   ` Chong Yidong

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=E1HY0bB-0006rs-OS@fencepost.gnu.org \
    --to=rms@gnu.org \
    --cc=emacs-devel@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.