unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* `select-frame' or `select-frame-set-input-focus'?
@ 2004-01-09  3:18 leo
  2004-01-09  8:46 ` Eli Zaretskii
  0 siblings, 1 reply; 2+ messages in thread
From: leo @ 2004-01-09  3:18 UTC (permalink / raw)


i 've written a couple of lttle function making a new frame and doing some
stuff there eg.

(defun info-new-frame ()
  (select-frame (make-frame-command))
  (info))

now i stumbled across the function `select-frame-set-input-focus' which
doesn't do anything different to `select-frame' on my system win2000 system.
i guess its something X11-related.

so what's the generally more recommended function for a new frame:
`select-frame' or `select-frame-set-input-focus'?

thanks, leo

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: `select-frame' or `select-frame-set-input-focus'?
  2004-01-09  3:18 `select-frame' or `select-frame-set-input-focus'? leo
@ 2004-01-09  8:46 ` Eli Zaretskii
  0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2004-01-09  8:46 UTC (permalink / raw)


> From: "leo" <halloleo@noospaam.myrealbox.com>
> Newsgroups: gnu.emacs.help
> Date: Fri, 9 Jan 2004 14:18:45 +1100
> 
> now i stumbled across the function `select-frame-set-input-focus' which
> doesn't do anything different to `select-frame' on my system win2000 system.

This is only true for the default configuration of the MS-Windows
window management policy, whereby you need to click on a window to
switch the input focus to it.  But if you change that (as I like to
do on my systems) so that merely moving the mouse pointer to another
window sets input focus to that other window, the two functions will
give different results.

Also, `select-frame-set-input-focus' raises the frame, which is
important if the frame was minimized.

> so what's the generally more recommended function for a new frame:
> `select-frame' or `select-frame-set-input-focus'?

It looks to me that the latter is marginally better (more portable and
its effect is more reliably predictable in all possible situations).

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-01-09  8:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-01-09  3:18 `select-frame' or `select-frame-set-input-focus'? leo
2004-01-09  8:46 ` Eli Zaretskii

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).