Xref: utzoo comp.emacs:7585 gnu.emacs:2163 Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!uunet!amara!mcdaniel From: mcdaniel@amara.UUCP (Tim McDaniel) Newsgroups: comp.emacs,gnu.emacs Subject: Re: Seeking Truly Electric-C mode for Gnu Emacs Message-ID: <568@amara.UUCP> Date: 22 Jan 90 18:28:56 GMT References: <13364@granite.BBN.COM> Reply-To: mcdaniel@amara.UUCP (Tim McDaniel) Followup-To: comp.emacs Distribution: comp Organization: Applied Dynamics Int'l. Lines: 25 >;; Mark Davies - Dec 1985, revised Jun 1987 >;; I invoke this from my .emacs file with the following incantation >;; (defvar c-mode-hook 'elec-c-mode) >;; (defvar elec-c-mode-hook '(lambda () (auto-fill-mode 1))) >;; (setq c-auto-newline t) This didn't work for me. It would load my text .emacs file, but not the byte-compiled "equivalent" of it. I'm not sure why: my version of emacs? the way I autoloaded elec-c? Anyway, I did (autoload 'elec-c-mode "elec-c" "" t) ... (setq c-mode-hook 'elec-c-mode) (setq elec-c-mode-hook '(lambda () (setq c-auto-newline t) ... ) ) instead, and that works both ways. -- Tim McDaniel Applied Dynamics International, Ann Arbor, MI Internet: mcdaniel%amara.uucp@mailgw.cc.umich.edu UUCP: {uunet,sharkey}!amara!mcdaniel