all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: martin rudalics <rudalics@gmx.at>
To: Aaron Jensen <aaronjensen@gmail.com>, emacs-devel@gnu.org
Subject: Re: How do I position a child-frame below the point?
Date: Sun, 07 Jan 2018 17:09:04 +0100	[thread overview]
Message-ID: <5A524620.5050702@gmx.at> (raw)
In-Reply-To: <m2wp0v1m31.fsf@gmail.com>

 > Question #1: I'm trying to create a new child-frame and position it
 > below the point in the parent frame. If I don't use a child-frame, this
 > isn't hard:
 >
 > (defun make-peek-frame ()
 >    (interactive)
 >    (let* ((current-frame (selected-frame))
 >           (abs-pixel-pos (save-excursion
 >                            (beginning-of-thing 'symbol)
 >                            (window-absolute-pixel-position)))

`window-absolute-pixel-position' is a function I wrote so on systems
where child frames are not available (or do not behave well) normal
frames can be used instead.  If you look at its code you will see that
`pos-visible-in-window-p' does all the work, so that's the function to
use.  Thereafter you have to translate window coordinates to native
frame coordinates using `window-inside-pixel-edges' IIRC.  Our
documentation of this is still unsatisfactory.

 > Question #3:
 >
 > How do I hide the point? I've tried (cursor-type . nil) as above, but it
 > shows up as a block nonetheless. I do wonder if evil is doing that,
 > however...

Which "evil"?  The window manager?

martin



  parent reply	other threads:[~2018-01-07 16:09 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-06  7:29 How do I position a child-frame below the point? Aaron Jensen
2018-01-07 13:26 ` Alan Third
2018-01-07 16:09   ` martin rudalics
2018-01-07 16:09 ` martin rudalics [this message]
2018-01-07 19:44   ` Aaron Jensen
2018-01-08  5:30     ` Aaron Jensen

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=5A524620.5050702@gmx.at \
    --to=rudalics@gmx.at \
    --cc=aaronjensen@gmail.com \
    --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.