SlickEdit Community

SlickEdit Product Discussion => SlickEdit® => Topic started by: Ganesh Venkitachalam on February 25, 2015, 05:24:47 pm

Title: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Ganesh Venkitachalam 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!
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Clark 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.
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Dennis 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.
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Ganesh Venkitachalam 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!
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Dennis on March 05, 2015, 10:37:54 pm
C/C++ Options > Auto-Close
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Ganesh Venkitachalam 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).
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Dennis on March 05, 2015, 11:26:30 pm
Look closely.  The option you want is on the C/C++ Auto-Close options tab.
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Ganesh Venkitachalam on March 05, 2015, 11:26:31 pm
Here's an attachment with my C/C++ settings. Thanks!
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Dennis 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.
Title: Re: Disable auto-close does not work (for C)? Bug in Slickedit?
Post by: Ganesh Venkitachalam 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.