* appt-disp-window raising frame toggle patch
@ 2011-11-05 2:25 Scott Jaderholm
2011-11-07 19:44 ` Glenn Morris
0 siblings, 1 reply; 3+ messages in thread
From: Scott Jaderholm @ 2011-11-05 2:25 UTC (permalink / raw
To: emacs-devel
[-- Attachment #1.1: Type: text/plain, Size: 385 bytes --]
Currently if you use the display window method with appt it will also raise
the frame in your window manager. I didn't like this as my keyboard focus
kept being taking so I added a custom variable to toggle this. Attached is
a patch. If anyone knows a simple way for me to eliminate raising in this
function on my system until (if) this patch gets applied please share.
Thanks,
Scott
[-- Attachment #1.2: Type: text/html, Size: 419 bytes --]
[-- Attachment #2: 0001-Add-custom-variable-for-toggling-whether-displaying-.patch --]
[-- Type: text/x-patch, Size: 1186 bytes --]
From 572c98a0b4281884c9727bdba5ce5d8c4f228c1e Mon Sep 17 00:00:00 2001
From: Scott Jaderholm <jaderholm@gmail.com>
Date: Fri, 4 Nov 2011 22:14:08 -0400
Subject: [PATCH] Add custom variable for toggling whether displaying appointment window raises frame.
---
lisp/calendar/appt.el | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/lisp/calendar/appt.el b/lisp/calendar/appt.el
index c44eb6e..b720356 100644
--- a/lisp/calendar/appt.el
+++ b/lisp/calendar/appt.el
@@ -166,6 +166,10 @@ Only relevant if reminders are being displayed in a window."
:type 'function
:group 'appt)
+(defcustom appt-disp-window-raises-frame t
+ "Non-nil raises the frame when displaying appointment window."
+ :type 'boolean
+ :group 'appt)
;;; Internal variables below this point.
@@ -472,7 +476,8 @@ separate appointment."
(shrink-window-if-larger-than-buffer (get-buffer-window appt-disp-buf t))
(set-buffer-modified-p nil)
(setq buffer-read-only t)
- (raise-frame (selected-frame))
+ (when appt-disp-window-raises-frame
+ (raise-frame (selected-frame)))
(select-window this-window)))
(defun appt-delete-window ()
--
1.7.0.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: appt-disp-window raising frame toggle patch
2011-11-05 2:25 appt-disp-window raising frame toggle patch Scott Jaderholm
@ 2011-11-07 19:44 ` Glenn Morris
2011-11-07 21:03 ` Glenn Morris
0 siblings, 1 reply; 3+ messages in thread
From: Glenn Morris @ 2011-11-07 19:44 UTC (permalink / raw
To: Scott Jaderholm; +Cc: emacs-devel
Scott Jaderholm wrote:
> Currently if you use the display window method with appt it will also raise
> the frame in your window manager. I didn't like this as my keyboard focus
> kept being taking so I added a custom variable to toggle this. Attached is
> a patch.
This is too late for Emacs 24.1 It could go in 24.2, but I am not sure
it is generally useful, because it means that if the Emacs window is
iconified, or behind another window, you will go no visible notification.
> If anyone knows a simple way for me to eliminate raising in this
> function on my system until (if) this patch gets applied please share.
Customize appt-disp-window-function, eg
(require 'cl)
(setq appt-disp-window-function 'foo)
(defun foo (min-to-app new-time appt-msg)
(flet ((raise-frame (&optional frame) (ignore)))
(appt-disp-window min-to-app new-time appt-msg)))
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: appt-disp-window raising frame toggle patch
2011-11-07 19:44 ` Glenn Morris
@ 2011-11-07 21:03 ` Glenn Morris
0 siblings, 0 replies; 3+ messages in thread
From: Glenn Morris @ 2011-11-07 21:03 UTC (permalink / raw
To: Scott Jaderholm; +Cc: emacs-devel
BTW: for me, simply raising a frame does not give it focus.
This seems consistent with the documentation of raise-frame.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-11-07 21:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-05 2:25 appt-disp-window raising frame toggle patch Scott Jaderholm
2011-11-07 19:44 ` Glenn Morris
2011-11-07 21:03 ` Glenn Morris
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.