Author Topic: Disable auto-close does not work (for C)? Bug in Slickedit?  (Read 3797 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: 6823
  • Hero Points: 526
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

  • Senior Community Member
  • Posts: 3954
  • Hero Points: 515
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

  • Senior Community Member
  • Posts: 3954
  • Hero Points: 515
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

  • Senior Community Member
  • Posts: 3954
  • Hero Points: 515
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

  • Senior Community Member
  • Posts: 3954
  • Hero Points: 515
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.