Gnus development mailing list
 help / color / mirror / Atom feed
* add summary mode hook for calling macro
@ 2001-11-18  6:54 Harry Putnam
  0 siblings, 0 replies; only message in thread
From: Harry Putnam @ 2001-11-18  6:54 UTC (permalink / raw)


I want to add a local key command to summary mode. That gives a key
binding to a defined and named macro.

I found a section in gnus manual that seems to deal with adding key
commands in summary mode under the unlikely topic:
         Generic Marking Commands
info://gnus/Summary+Buffer/Marking+Articles/Generic+Marking+Commands
    (add-hook 'gnus-summary-mode-hook 'my-alter-summary-map)
     (defun my-alter-summary-map ()
       (local-set-key "!" 'gnus-summary-put-mark-as-ticked-next))

But that is more directly about changing existing keymands to
different behavior.

I want to set a key to run a macro that embodies the keys needed to
respool a summary buffer.  Some code I thought might be close below
just beeps.  Probably way off base.

    (add-hook 'gnus-summary-mode-hook 'my-macro-respool-command)
     (defun my-macro-respool-command()
     "define a key combo to run a macro that respools summary buffer"
;      WHAT goes here? .. maybe:
      (require 'macro)
       (local-set-key "\C-c r" 'spool))

The macro is named and in a file macro.el along with a global key
binding that I would rather do with a summary mode hook.

cat macro.el
  (fset 'spool
     [?M ?P ?a ?B ?r return])
;  (global-set-key [24 26] 'spool)
  
  (provide 'macro)




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2001-11-18  6:54 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-11-18  6:54 add summary mode hook for calling macro Harry Putnam

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 NNTP newsgroup(s).