Hi Tim,

Thank you for the contribution. I will definitely look at it as soon
as I get access to a computer  again (i am a few days away right now).

Testing this would be definitely cool, especially given all the edge
cases. It is certainly testable, but kind of tricky to setup
everything.

Lukas

On Tuesday, August 3, 2010, Tim Mackinnon <tamackin...@gmail.com> wrote:
> Guys - this is my first attempt at a contribution - and I'm not sure how 
> literally to take the advice on "how to contribute to Pharo" for a small 
> change. Should I create an issue, and post it here (happy to do that, but 
> wondered if conversation might be useful first as I'm new to this).
>
> Given that I'm not sure what the relationship between eCompletion and 
> oCompletion is (someone mentioned the latter is built on top of the former?) 
> - so maybe I'm barking up the wrong tree, however I was impressed with how 
> much quicker Lucas' Hudson built pharo image was with eCompletion so I've 
> been trying that for a few days (although I've noticed some mails on 
> oCompletion but haven't gone back to retry it).
>
> Anyway - I have attached a change set that changes how smart characters work 
> - instead of turning them off because half of the time they do the wrong 
> thing for me and I madly press delete, I wanted to preserve the other half of 
> the time when I'm entering new code and they give me a helpful template.
>
> My proposed fix is for the following scenario - if I go to add an extra 
> bracket around an expression (becuase I later realise that I need to 
> designate a keyword expression) I get two brackets - and then I backspace and 
> they both go, so then I do it again and press delete... Instead I think there 
> is a heuristic which says that says if you type a smart character with the 
> cursor next to a non-whitespace item, you probably don't want the matching 
> character. e.g.
>
> 5 max: 4 > 3 ifTrue: [] {cursor here} - and I click next to the 4 (or the 5) 
> to put the bracket and I get 2, and I really only want one.
>
> My patch tries to address this.
>
> I also didn't see any test cases for this stuff (and possibly some could be 
> written - should I try to do that too?).
>
> Tim

-- 
Lukas Renggli
www.lukas-renggli.ch

_______________________________________________
Pharo-project mailing list
Pharo-project@lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

Reply via email to