Oliver Elphick wrote: > > (If it matters, I'm using xemacs 21). > > I want to define a function key to run a macro. > > I can do it within a session: > > ESC x global-set-key RET <f9> eif-indent-buffer RET > > but I can't get it to work in the initialisation file ~/.emacs: > > (defalias 'eif-indent-buffer (read-kbd-macro > "ESC x mark- whole- buffer RET ESC x eif- indent- region RET")) > (global-set-key <f9> 'eif-indent-buffer) > > What should I put for <f9>? I've tried "f9", <f9>, "<f9>", (<f9>) and it > doesn't like any of them. I can't see anything about it in the docs either.
Try (global-set-key [f9] 'eif-indent-buffer) /Johan -- Johan Groth (xghjn) ! Tel. mobil: 0703 - 24 25 27 Cell Network ! Kontoret: 054 - 14 25 27 [EMAIL PROTECTED] ! Bofors: 0586 - 820 14 [EMAIL PROTECTED]