We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexSuggestions & BugsSoftware Bugs › auto format and commented curly brackets
Page Index Toggle Pages: 1
auto format and commented curly brackets (Read 1228 times)
auto format and commented curly brackets
May 7th, 2005, 12:28am
 
I have just spent the last half hour going insane over this.

Like most people I use star comments (/* */) to disable large blocks of code. I even use this to take functions offline between web and API versions.

I would warn against using autoformat at the moment to manage one's curly brackets when one has curly brackets that have been commented out.
Code:

void setup(){
}
void draw(){
//try auto format{{{{{{{{
}
Re: auto format and commented curly brackets
Reply #1 - May 7th, 2005, 7:00am
 
you spent half an hour? i don't understand.. could you not just hit undo when something went wrong?

martin gomez contributed a new beautify a while back, and i've just hacked it in, so i'll release that with 0088 and hopefully that'll improve things.
Re: auto format and commented curly brackets
Reply #2 - May 7th, 2005, 5:13pm
 
I was busy tidying up the code and used auto format to fix things. My major changes involved putting a long
//-----------------------------------------------
to break up the mess. No undo memory left. Then it kept telling me it couldn't find my classes. ("They're right there you stupid machine!") I didn't know about this wierd effect so I began to think I was going mad.

I've encountered an undo memory on certain applications. Is there a way I can set that on Processing? (New preference perhaps?)
Re: auto format and commented curly brackets
Reply #3 - May 7th, 2005, 6:13pm
 
not sure what's up with the undo stuff. if you can reproduce it, please start a fresh thread about it so that i can keep track. the undo is a pretty basic java undo setup, it should just have infinite levels.
Re: auto format and commented curly brackets
Reply #4 - May 7th, 2005, 7:10pm
 
k, i've patched in martin gomez's nutty auto format for 88. should fix things and if not we can yell at him.

and also several undo fixes have been made for rev 88 so that may also help clear up some of the other problems.

so, closing thread..
Page Index Toggle Pages: 1