Author Topic: Disable auto-close does not work (for C)? Bug in Slickedit?  (Read 2403 times)

Ganesh Venkitachalam

  • Community Member
  • Posts: 32
  • Hero Points: 0
Disable auto-close does not work (for C)? Bug in Slickedit?
« on: February 25, 2015, 05:24:47 pm »
My project is set to be C/C++. I disabled autoclose, but whenever I type if (blah) {, SE inserts the closing "}". I have disabled auto-close for both ansi-c and c/c++, to no avail. This is driving me nuts - I've had actual bugs introduced because of this. Help! Any way to turn off the auto-close for real?

See attachment. Much thanks for help!

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 5177
  • Hero Points: 428
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #1 on: February 26, 2015, 12:55:06 am »
You need to turn off "Use dynamic surround" in the auto-complete section of the language settings.

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2934
  • Hero Points: 438
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #2 on: February 26, 2015, 06:08:51 pm »
Actually, while Clark is correct, given your preferences, you would probably also prefer to turn off Dynamic Surround, the option for ANSI-C you want to turn off is Document > ANSIC Options > Formatting > Quick brace/unbrace one line statements.

Ganesh Venkitachalam

  • Community Member
  • Posts: 32
  • Hero Points: 0
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #3 on: March 05, 2015, 10:30:24 pm »
Hi, Thanks. I had dynamic surround disabled already. My project is C/C++, not ANSI-C. So I found Documents->C/C++. That does not seem to have this option. Help!

I created a test ANSI-C project, ANSI-C does seem to have this option, and in a quick test it does seem to do what I want. Is there a way to set this option for C/C++? Thanks!

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2934
  • Hero Points: 438
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #4 on: March 05, 2015, 10:37:54 pm »
C/C++ Options > Auto-Close

Ganesh Venkitachalam

  • Community Member
  • Posts: 32
  • Hero Points: 0
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #5 on: March 05, 2015, 11:24:10 pm »
Hi Dennis, please see my original post with screenshot - I have it disabled there, and it still inserts the brace. Thanks! (Am I missing some option in that screenshot? I don't think so, but still).

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2934
  • Hero Points: 438
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #6 on: March 05, 2015, 11:26:30 pm »
Look closely.  The option you want is on the C/C++ Auto-Close options tab.

Ganesh Venkitachalam

  • Community Member
  • Posts: 32
  • Hero Points: 0
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #7 on: March 05, 2015, 11:26:31 pm »
Here's an attachment with my C/C++ settings. Thanks!

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2934
  • Hero Points: 438
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #8 on: March 06, 2015, 12:07:11 am »
Looks like the best workaround for the version you are using is to go to Tools > Options... > Languages > All Languages > Formatting and then turn off the quick brace option.
« Last Edit: March 06, 2015, 01:16:49 am by Dennis »

Ganesh Venkitachalam

  • Community Member
  • Posts: 32
  • Hero Points: 0
Re: Disable auto-close does not work (for C)? Bug in Slickedit?
« Reply #9 on: March 06, 2015, 06:14:51 pm »
That seems to have done the trick so far.

Thank you so much! This was super helpful, thank you.