Petter M�hl�n writes:
 > You may have something there, Suraj, because I am setting it in .emacs,
 > since I want it to be on for all Java files I work with.
 > 
 > / Petter 
 > 
 > > -----Ursprungligt meddelande-----
 > > Fr�n: Suraj Acharya [mailto:[EMAIL PROTECTED] 
 > > Skickat: den 1 juli 2004 00:15
 > > Till: Paul Kinnucan
 > > Kopia: Petter M�hl�n; [EMAIL PROTECTED]
 > > �mne: Re: SV: Jde-electric-return sometimes off
 > > 
 > > Paul, I think the problem might occur if you set jde-electric-return-p
 > > in your .emacs (using custom-set-variable) and don't set in your jde
 > > project files.Petter, are setting the variable
 > > in your .emacs or your project file? I've just upgraded to jde beta5
 > > from beta3 so I'm not sure there is new jde custom variable code that
 > > calls the :set methods for variables set globally when switching
 > > projects or loading a new one.

Yes, project switching handles the case where a variable is set in the 
.emacs file but not in a project file. In this case, when switching to
the project that does not set the variable, the JDEE sets the variable
to the value in the .emacs file.

I have tried setting jde-electric-return-p to "on" in my .emacs file, closing
Emacs, reopening Emacs, loading two files, each from separate projects,
and switching back and forth between the two projects. The electric
return mode is on at Emacs startup, as expected, and remains on through
multiple switching back and forth among projects.

Further, if I customize jde-electric-return-p "off" in one project, it
remains off in that project even if I switch to the other project in which
it is on and then switch back.

On the other hand, if I leave jde-electric-return-p "on" for both projects
and then toggle JDEE->Code Generation->Modes->Electric Return to turn it
off in one project temporarily and then switch to the other project and
then back, electric return mode is reenabled. This is because the .emacs
file setting overrides the "temporary" disabling of electric return mode.

Paul

 > > 
 > > Suraj
 > > 
 > > On Wed, 30 Jun 2004 08:01:11 -0400, Paul Kinnucan 
 > > <[EMAIL PROTECTED]> wrote:
 > > > 
 > > > Petter M�hl�n writes:
 > > >  > Well, have to correct myself - the 'toggle' function has 
 > > been changed to
 > > >  > jde-electric-return-mode in beta5, the text referred to 
 > > beta3. Nevertheless,
 > > >  > the behaviour as such is the same in both betas, that 
 > > is, the electric
 > > >  > return doesn't work automatically for newly opened files.
 > > > 
 > > > I can't reproduce this problem on my system. Please note 
 > > that intended
 > > > behavior is for you to use the customization variable
 > > > jde-electric-return-p to specify the default setting for 
 > > this mode (on
 > > > or off) and jde-electric-return-mode to toggle the setting 
 > > temporarily
 > > > during a session.
 > > > 
 > > > Paul
 > > > 
 > > > 
 > > > 
 > > >  >
 > > >  > / Petter
 > > >  >
 > > >  > > -----Ursprungligt meddelande-----
 > > >  > > Fr�n: Petter M�hl�n [mailto:[EMAIL PROTECTED]
 > > >  > > Skickat: den 30 juni 2004 10:16
 > > >  > > Till: '[EMAIL PROTECTED]'
 > > >  > > �mne: Jde-electric-return sometimes off
 > > >  > >
 > > >  > > Hi,
 > > >  > >
 > > >  > > I like the jde-gen-embrace functionality that Suraj provided
 > > >  > > and that is included in the last few betas. However, that
 > > >  > > feature is often turned off when I open up a new buffer, even
 > > >  > > though jde-electric-return-p is true. I can turn the feature
 > > >  > > on by doing two "jde-toggle-electric-return" (not one), but
 > > >  > > it should work from the start. My guess is that the
 > > >  > > key-mapping doesn't "take" when I open or create a new
 > > >  > > buffer, could that be true? I have tried to understand what
 > > >  > > goes on, but haven't quite gotten there.
 > > >  > >
 > > >  > > I'm on 2.3.4beta5, by the way.
 > > >  > >
 > > >  > > / Petter
 > > >  >
 > > > 
 > > >
 > > 
 > 

Reply via email to