unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* frame parameters user-size and user-position
@ 2005-05-28 18:01 Drew Adams
  2005-05-29 12:04 ` Richard Stallman
  0 siblings, 1 reply; 2+ messages in thread
From: Drew Adams @ 2005-05-28 18:01 UTC (permalink / raw)


1. Frame parameter `user-position' can be used to tell the window manager
that the user has positioned a frame. Is there an equivalent `user-size'
parameter to tell the window manager whether the user has sized the frame?

I don't see `user-size' documented anywhere (e.g. Info (elisp)), but I see
it used in these files: faces.el, frame.el, mac-win.el, w32-win.el,
x-win.el, and frame.c. If it is similar to `user-position', shouldn't it be
documented?


2. The doc for `user-position' says that you can use it to tell the window
manager that the user positioned the frame, in hopes that the w-m will leave
the position alone. I assume something similar is behind `user-size'.

I have never seen either of these parameters in any of my frames, so I
assume they are only there if I add them myself. (I'm using Emacs in
Windows, if that makes a difference.) That would seem to agree with the doc,
which just says you can specify them when you create a frame.

Would it be possible (after the release) to have Emacs update these frame
parameters whenever a user repositioned or resized a frame (e.g. using the
mouse)? That is, could we perhaps use these parameters to _indicate_ whether
the user has repositioned or resized a frame (even if the indication is not
100% reliable)? Would this be possible (for at least some window managers),
or is this information not available from a window manager?

For this to work, Emacs would need to record a non-nil value for the
frame-parameter whenever the user manually moved or sized a frame and (by
default) set it to nil when a frame is created or moved/sized by program.

My question is one of feasibility, for now. I don't want to start a
discussion about a possible new feature; I'm just wondering if this is
feasible.

Such an indication of user frame-sizing could be useful, for example, for
code that tries to automatically resize a frame to fit its buffer. If the
user has previously sized the frame, an automatic resize would presumably
not be done, in order to not override the user's intention.

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

* Re: frame parameters user-size and user-position
  2005-05-28 18:01 frame parameters user-size and user-position Drew Adams
@ 2005-05-29 12:04 ` Richard Stallman
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Stallman @ 2005-05-29 12:04 UTC (permalink / raw)
  Cc: emacs-devel

    I don't see `user-size' documented anywhere (e.g. Info (elisp)), but I see
    it used in these files: faces.el, frame.el, mac-win.el, w32-win.el,
    x-win.el, and frame.c. If it is similar to `user-position', shouldn't it be
    documented?

Thanks.  I will document it.

    Would it be possible (after the release) to have Emacs update these frame
    parameters whenever a user repositioned or resized a frame (e.g. using the
    mouse)? That is, could we perhaps use these parameters to _indicate_ whether
    the user has repositioned or resized a frame (even if the indication is not
    100% reliable)?

It might be a good idea, but we can think about it later.

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

end of thread, other threads:[~2005-05-29 12:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-05-28 18:01 frame parameters user-size and user-position Drew Adams
2005-05-29 12:04 ` Richard Stallman

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