<div dir="ltr"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> On 2019-12-23, at 7:41 PM, Chris Muller <<a href="mailto:asqueaker@gmail.com" target="_blank">asqueaker@gmail.com</a>> wrote:<br>
> <br>
> It is only the autoEnclose preference that causes problems in<br>
> workspaces,<br>
> <br>
> What "problems" are those?   Just as you see in the subject-line of this email, for every open-parenthesis, there's a closing, as well as for every open bracket, a closing.  That's the structure of these characters in every normal context.  "Problems" arise when they get out of balance, which is why other editors have this feature too.  IIRC, eclipse was doing it in 2005.<br>
> <br>
> IMO, it's a good thing for developers and users alike.<br>
<br>
Problem is that when you type a ( you get () - which is fine if you're about to type (fooble +2) but really irritating if you already have fooble + 2) and want to add the ( in front. Which seems to be something that happens frequently enough to me that the irritation level is very considerable.  </blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Now, the 'enclose selection with brackets' option is much less annoying *to me* - apart from anything else I got used to it decades ago. It's useful when editing, as opposed to 'streaming', code. Of course, it gets annoying if you wanted to replace the selection with (.<br>
Happily cmd-shift-( actually does a "wrap selection with ( and leave selection as-is" so it is possible to do both ways almost without any problem. With both the auto-enclose and enclose-selection disabled you can<br>
type (foo<br>
type foo, go back and add ( in front<br>
type foo, select it, wrap with cmd-( to get (foo)<br>
type cmd-(foo and get (foo)<br>
So *at worst* you'd have to hit cmd-( to get the () you want, and of course the preference is still there for you and any other people that are able to stream out code without having to stop and ponder after every (small prime number of) characters.<br></blockquote><div><br></div><div>I think it boils down to whether you want to edit "expressions" or edit "text".  The preferences are optimized to let you choose one or the other and, if you stick to it, serve you well.  As someone who prefers the expression-editing style, I never run into "fooble + 2)" because I never type a closing paren-bracket, ever, I just don't, because it means you're instantly out of balance which, I simply can't do in my editing.  Unbalanced paren-brackets forces me into tedious "text editing" mode where all analysis stops so I can hunt down the missing whatever just to get back to syntactical validity.  If I need to enclose an expression, I always only select it and use the hot key.  In that way of working, autoEnclose is always fine.</div><div> <br></div><div> - Chris</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
<br>
tim<br>
--<br>
tim Rowledge; <a href="mailto:tim@rowledge.org" target="_blank">tim@rowledge.org</a>; <a href="http://www.rowledge.org/tim" rel="noreferrer" target="_blank">http://www.rowledge.org/tim</a><br>
Computers are only human.<br>
<br>
<br>
</blockquote></div></div>