help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Maximize/restore frame function


From: Subhan Michael Tindall
Subject: RE: Maximize/restore frame function
Date: Sun, 5 Oct 2014 18:13:53 +0000

> -----Original Message-----
> From: Drew Adams [mailto:drew.adams@oracle.com]
> Sent: Friday, October 03, 2014 10:50 PM
> To: Subhan Michael Tindall; help-gnu-emacs@gnu.org
> Subject: RE: Maximize/restore frame function
> 
> > Hi, I'm looking for a simple (hopefully!) function to maximize a
> > frame/restore to it's previous size.
> > I've looked through the apropos and the closest I could find was
> > iconify-frame and iconify-or-deiconify-frame, neither of which quite
> > does what I want.
> > What I want is function to toggle a given frame between being
> > maximized on it's display and it's original size I work in windows
> > (bleh), I get this same functionality by double clicking on the top
> > bar of the frame. This maximizes it to the monitor It's on.
> > Dual monitor setup with virtuawin multiple desktops if that helps.
> > Any ideas?
> 
> As Oscar indicated, Emacs 24.4 has this.
> 
> You can also toggle maximization (but not fullscreen), on all platforms in all
> Emacs versions (starting with Emacs 20), using library `frame-cmds.el', which
> you can get from Emacs Wiki (or MELPA), http://www.emacswiki.org/emacs-
> en/download/frame-cmds.el
> 
> There you will find commands `maximize-frame' and `restore-frame', aka
> `toggle-max-frame'.  From the doc string:
> 
> ,----
> | Toggle maximization of FRAME horizontally, vertically, or both.
> | Reverses or (if restored) repeats the effect of the Emacs maximize
> | commands.  Does not restore from maximization effected outside Emacs.
> |
> | With no prefix arg, toggle both directions.
> | With a non-negative prefix arg, toggle only vertically.
> | With a negative prefix arg, toggle horizontally.
> |
> | When toggling both directions, each is toggled from its last maximize
> | or restore state.  This means that using this after
> | `maximize-frame-horizontally', `maximize-frame-vertically',
> | `toggle-max-frame-horizontally', or `toggle-max-frame-vertically' does
> | not necessarily just reverse the effect of that command.
> `----
> 
> If you use a standalone minibuffer frame then "maximizing" another frame
> leaves room for the minibuffer frame; it does not occlude it.
> 
> All of the commands in the library work with all Emacs versions (starting with
> Emacs 20).
[>] 

The commands are exactly what I want, but don't work properly with a 
multi-monitor setup.
Maximize & restore will jump the frame from left monitor to right & vice versa. 
 It doesn't appear to be tracking the original location either.
So, for example, when I maximize a frame in the left monitor(which does not 
have a menu bar), the frame is moved to the right monitor, maximized for that 
monitor, and igores the menu bar so oversizes the frame.  
Subhan

This message is intended for the sole use of the individual and entity to which 
it is addressed and may contain information that is privileged, confidential 
and exempt from disclosure under applicable law. If you are not the intended 
addressee, nor authorized to receive for the intended addressee, you are hereby 
notified that you may not use, copy, disclose or distribute to anyone the 
message or any information contained in the message. If you have received this 
message in error, please immediately advise the sender by reply email and 
delete the message.  Thank you.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]