all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Reitter <david.reitter@gmail.com>
To: martin rudalics <rudalics@gmx.at>
Cc: Jin Choi <jsc@alum.mit.edu>, 1372@emacsbugs.donarmstrong.com
Subject: bug#1372: posn-at-x-y reports wrong window
Date: Wed, 19 Nov 2008 10:27:15 -0500	[thread overview]
Message-ID: <F5CF2ABC-B56C-4A10-9D01-0FFD91D63160@gmail.com> (raw)
In-Reply-To: <49242C33.4090702@gmx.at>

[-- Attachment #1: Type: text/plain, Size: 1380 bytes --]

Thanks, this patch fixes the problem.

- David

On 19 Nov 2008, at 10:09, martin rudalics wrote:

> > (fringe-mode 0)
> > C-x 3 C-x 2 C-x o C-x o
> > (we're now in the large window on the right, with two small  
> windows in
> > the left half of the frame).
> >
> > Insert enough newlines to be vertically just above the horizontal
> > divider on the left.
> >
> > M-: (posn-at-x-y 0 (cdr (posn-x-y (posn-at-point)))) RET
> >
> > Insert newline, now we're next to the divider line.
> >
> > M-: (posn-at-x-y 0 (cdr (posn-x-y (posn-at-point)))) RET
> >
> > --> wrong window (the window in the upper left) is given in the  
> structure.
> > Instead of 0, the x value can be up to 6 ((frame-char-width)  
> reports 7).
>
> Can you try the attached patch?
>
> martin
> *** window.c.~1.634.~	2008-11-18 18:56:23.703125000 +0100
> --- window.c	2008-11-19 16:04:02.078125000 +0100
> ***************
> *** 774,780 ****
>  	}
>        else
>  	{
> ! 	  if (eabs (*x - x1) < grabbable_width)
>  	    {
>  	      /* Convert X and Y to window relative coordinates.
>  		 Vertical border is at the right edge of window.  */
> --- 774,781 ----
>  	}
>        else
>  	{
> ! 	  if ((WINDOW_RIGHTMOST_P (w) || *x < x1)
> ! 	      && eabs (*x - x1) < grabbable_width)
>  	    {
>  	      /* Convert X and Y to window relative coordinates.
>  		 Vertical border is at the right edge of window.  */


[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 2193 bytes --]

  reply	other threads:[~2008-11-19 15:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <356ECE88-9412-46FD-A227-C52D5C87E212@mac.com>
2008-11-19  0:45 ` bug#1372: posn-at-x-y reports wrong window David Reitter
2008-11-19 15:09   ` martin rudalics
2008-11-19 15:27     ` David Reitter [this message]
2008-11-20 10:30   ` bug#1372: marked as done (posn-at-x-y reports wrong window) Emacs bug Tracking System

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=F5CF2ABC-B56C-4A10-9D01-0FFD91D63160@gmail.com \
    --to=david.reitter@gmail.com \
    --cc=1372@emacsbugs.donarmstrong.com \
    --cc=jsc@alum.mit.edu \
    --cc=rudalics@gmx.at \
    /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.