Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!purdue!mentor.cc.purdue.edu!j.cc.purdue.edu!nwd From: nwd@j.cc.purdue.edu (Daniel Lawrence) Newsgroups: comp.emacs Subject: Re: UE310 add mode from .rc? Summary: uEMACS startup Message-ID: <10079@j.cc.purdue.edu> Date: 19 Sep 89 14:40:43 GMT References: <340001@hpdml93.HP.COM> Reply-To: nwd@j.cc.purdue.edu (Daniel NLawrence) Organization: Purdue University Lines: 28 In article <340001@hpdml93.HP.COM> campbell@hpdml93.HP.COM (Gary Campbell) writes: >I would like to have MicroEmacs 3.10 start up whith wrap mode in effect >on the buffer associated with the first file on the command line. When >I put 'add-mode "wrap"' in the emacs.rc file, it works if there is no >file specified on the command line, but it doesn't work if you specify a >file. Is there a way to do this, or do I need to use a global mode? MicroEMACS processes the startup file before it reads the initial file in. This is the only way it can have things set up properly before the file gets thier (like CRYPTing) and as such, no local mode exists until the file is read. If it is a particular type of file you want in WRAP mode you could add the check for it in macro 20 in the standard emacs.rc file (the one that gets bound to $readhook). Or, as you pointed out, you could just add it as a global mode, but then all your other files in the same session will be in WRAP mode as well. I think I would really need to know more about how you are using emacs to determine the best solution. If many enough people simply wanted the ability to do this, I could add a new command line switch for it as well. (The code would not be difficult, look at the code in main.c handling the -v switch). Daniel Lawrence voice: (317) 742-5153 arpa: dan@midas.mgmt.purdue.edu The Programmer's Room Fido: 1:201/10 - (317) 742-5533