🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Brian L. Kahn Sun, 07 Jun 1992 00:14
select-window-hook
#1327
Author: Brian L. Kahn
Date: Sun, 07 Jun 1992 00:14
40 lines
1892 bytes
I've always wanted my screens to be renamed as I changed buffers, but
I've never been able to get this to work right.  Too much happens
behind the scenes.  Today I broke down and changed the C-code (much to
my shame, its just not the elisp way) to give a select-window-hook.
Maybe this could be put in the distribution?  Now it is easy to track
current buffer on screens (set this and set-window-buffer-hook to
'epoch::do-titles), and I've thought up many other nifty and exotic
uses for this hook.


The patch is really short, so here it is:


*** window.c.orig	Sat Jun  6 18:36:49 1992
--- window.c	Sat Jun  6 18:36:33 1992
***************
*** 1140,1145 ****
--- 1140,1157 ----
    windows_or_buffers_changed++;
    screen_changed++;
  
+     {
+     /* blk@mitre.org  Sat Jun  6 19:11:01 1992
+      * Call value of window-select-hook if it is bound and non-nil
+      * derived from epoch code for set-window-buffer-hook
+      */
+     register Lisp_Object tem;
+     tem = intern("window-select-hook");
+     tem = XSYMBOL (tem)->value;	/* convert to value */
+     if (! EQ (tem, Qunbound) && ! EQ (tem, Qnil))
+       tem = call1 (tem,window);
+     }
+ 
    return window;
  }
  

--
B<   Brian Kahn   blk@security.mitre.org   "may the farce be with you"
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads