unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Richard Stallman <rms@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: No possibility of determining image position/object from click
Date: Sun, 9 Jun 2002 09:19:15 -0600 (MDT)	[thread overview]
Message-ID: <200206091519.g59FJFk00269@aztec.santafe.edu> (raw)
In-Reply-To: <x5r8jnfi8a.fsf@tupik.goethe.zz> (David.Kastrup@t-online.de)

    GNU Emacs is missing an API for finding out where a click occured.  If
    I have a string or an image as part of a display property, or as a
    before-string or after-string, the only way to let Emacs react to
    clicks on different images differently is to generate individual
    keymaps for each of them.

I see.  All it provides is the buffer position, which won't tell
you the position within the before-string.

I think we should replace the buffer position with a list that gives
the full story.

      Even then, you cannot find out the
    relative coordinates of a click on such an image.

It does give the x and y pixel coordinates of the click.  If you can
determine the coordinates of a corner of the image, you can subtract
and get the relative position.  But I am not sure there is any way to
determine the corner's coordinates, if the image comes from a
before-string.

In principle, these are good features to add.  Do you have an
immediate practical application for them?

       reply	other threads:[~2002-06-09 15:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <x5r8jnfi8a.fsf@tupik.goethe.zz>
2002-06-09 15:19 ` Richard Stallman [this message]
2002-06-09 20:36   ` No possibility of determining image position/object from click David Kastrup
2002-06-15 14:13     ` Richard Stallman
2002-06-15 14:34       ` David Kastrup
2002-06-15 16:58         ` Eli Zaretskii
2002-06-15 17:10           ` David Kastrup
2002-06-16 23:29         ` Richard Stallman

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=200206091519.g59FJFk00269@aztec.santafe.edu \
    --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 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).