On Mon, Aug 20, 2012 at 8:03 AM, Chen Cheng <
chengchendoc@xxxxxxxxx> wrote:
> Hi,
>
> Why i can not edit the gdoc? i can only read.
>
> 2012/8/20 Marcel Bruch <
bruch@xxxxxxxxxxxxxxxxxx>
>>
>> I've updated the comments and example screenshots.
>>
>>
>> And for your commend below:
>> 1. SnipMatch inserts the $varname for every variable
>> Now, SnipMatch does not always do this. for example, if there is a snip
>> like this "print $info" and its code is "System.out.println($info)", if you
>> input "print message" to find and get this snip match, then you press ENTER.
>>
>>
>>
>>
>> Ok. nice. But it's not the way a developer is used to work. Also you don't
>> get code completion for this then. See code completion screenshot in the
>> gdoc for SWT button template.
>
>
> As you described in the gdoc, i know what you want now. But before my work
> of SnipMatch, Doug and Ye Zi have a definitely different design with JDT
> templates here, including snip grammar, variable design/autocomplete, we are
> on the way of transferring SnipMatch into JDT work way.
>
> As you comment in gock, i know you feel oddly why there are so much
> *strange* grammar in SnipMatch's code snip file. That is because you do not
> know how SnipMatch first design, it is
> not designed in JDT way, it has its own grammar, its own variable
> define/implement etc. During my gsoc, i have changed it search result into
> JDT
> code assist way, and now, i have finished it grammar reconstruction job.
> SnipMatch will first parse codesnip as JDT template, if failed,
> then use its custom grammar to parse the codesnip. Maybe we can remove its
> custom grammar, use only JDT template grammar in the future.
>
> The most dispute part, the variables/parameters:
> SnipMatch has its own variable auto-complete feature, and Doug likes it so
> much, but i know you would like it works in JDT template way. I think it
> is possible to add "linked mode with built-in variables completion" feature
> for SnipMatch, i can start this part of job soon, but need some survey
> before real coding job.
>
> Doug, what do you think here ?
>
>> SnipMatch will insert "System.out.println(message)".
>>
>> We call it a _in-order match_, Snipmatch will compute variables in user's
>> input text.
>>
>> Or SnipMatch will insert $varname to replace the in the variable place,
>> but after my last patch, it will insert a default variable name without "$"
>> here, just like what JDT template autocomplete does.
>>
>>
>> Okay, but it's still not using the face template language properly.
>
>
> If you mean we still does not support the variables navigate by pressing TAB
> after the code inserted into current editor, yes, SnipMatch does not support
> this yet.
>
>>
>> Please see the SWT Button template example to see how this linked mode
>> with built-in variables completion is used. I'm asking you to use this
>> feature from the very first day; all that code to replace that $ sign, parse
>> the completion etc. is just not required as you get all that stuff for free.
>>
>>
>> 2. About the tests
>>
>> Yeah, we are lack of test cases as we have several BIG features to develop
>> during GSoC,
>>
>>
>> Sorry, this is a lame excuse ;-)
>>
>>
>> Cheers,
>> Marcel
>>
>>
>> --
>> Eclipse Code Recommenders:
>>
www.eclipse.org/recommenders
>>
>>
>>
>> On Aug 20, 2012, at 12:10 PM, Chen Cheng <
chengchendoc@xxxxxxxxx> wrote:
>>
>> Hi Marcel,
>>
>> I just merge the "JDT template support"
>> patch(
https://git.eclipse.org/r/#/c/7282/) for SnipMatch, it means that
>> SnipMatch can support JDT template now, but of course, we need more test for
>> this feature.
>>
>> And for your commend below:
>> 1. SnipMatch inserts the $varname for every variable
>> Now, SnipMatch does not always do this. for example, if there is a snip
>> like this "print $info" and its code is "System.out.println($info)", if you
>> input "print message" to find and get this snip match, then you press ENTER.
>> SnipMatch will insert "System.out.println(message)".
>>
>> We call it a _in-order match_, Snipmatch will compute variables in user's
>> input text.
>>
>> Or SnipMatch will insert $varname to replace the in the variable place,
>> but after my last patch, it will insert a default variable name without "$"
>> here, just like what JDT template autocomplete does.
>>
>> 2. About the tests
>> Yeah, we are lack of test cases as we have several BIG features to develop
>> during GSoC, i focus on coding job too much. But we still have a unit test
>> project "org.eclipse.recommenders.tests.snipmatch.rcp" in our GIT code
>> repository, i have not added it into Recommenders' build projects yet. But i
>> will add more test cases in this project and add it in pom.xml.
>>
>> AND thank so much for your feedback in the gdoc, i am working for the
>> issues currently :-)
>>
>>
>> 2012/8/20 Marcel Bruch <
marcel.bruch@xxxxxxxxx>
>>>
>>> So here they are - my comments on Snipmatch. Finally :)
>>>
>>> First I'd like to say I see many improvements in many different areas. So
>>> I'm happy to say that I'm very happy with your achievements during the GSOC!
>>>
>>> As always, there are a few things that need more polishing. Few of them
>>> are easy to fix, others may be more more complicated. The most serious issue
>>> I have is the template insertion which inserts the $varname for every
>>> variable and the non-closable and dragable view. This should be addressed
>>> before a release IMHO.
>>>
>>> You find other things that I would propose to fix in the gdoc
>>> "scrapbook".
>>>
>>> Again, over all I'm happy with the development (except that there are no
>>> tests which is not good).
>>>
>>> Cheers,
>>> Marcel
>>>
>>> On Aug 20, 2012, at 7:54 AM, Marcel Bruch <
marcel.bruch@xxxxxxxxx> wrote:
>>>
>>> hit me! Forget about my issue. I moved to a new laptop and the backup did
>>> not copy the old template files… my fault :)
>>>
>>>
>>> On Aug 20, 2012, at 7:37 AM, Marcel Bruch <
marcel.bruch@xxxxxxxxx> wrote:
>>>
>>> No, the second last picture in the gdoc shows what I see. I enter the
>>> keyword but nothing happens. It worked a few days before so I wonder if you
>>> changed anything there? Rebuilding the index (by clicking the button) did
>>> not make it work. My index file is empty (it only contains "{}").
>>>
>>> It would be nice if the update operation would warn me or give me some
>>> stats how many snippets have been indexed etc. Until I triggered code
>>> completion everything looked ok.
>>>
>>>
>>> On Aug 20, 2012, at 3:24 AM, Chen Cheng <
chengchendoc@xxxxxxxxx> wrote:
>>>
>>> Hi Marcel,
>>>
>>> You mean you can get the target code snip, but after print ENTER, no code
>>> insert into your editor?
>>>
>>> 2012/8/19 Marcel Bruch <
bruch@xxxxxxxxxxxxxxxxxx>
>>>>
>>>> Hi Chen, Hi Doug,
>>>>
>>>> I started playing with snipmatch but completion did not work for me
>>>> anymore. Is there some error reporting functionality? The index update
>>>> operation says "all good" :-(
>>>>
>>>> Best,
>>>> Marcel
>>>>
>>>> FWIW, comments I had so far can be found here:
>>>>
>>>>
https://docs.google.com/document/d/1fTryHCV41qr8JxUJY3gmWcSlxNe9aqSFYDhHKGQGqOA/edit
>>>>
>>>> --
>>>> Eclipse Code Recommenders:
>>>>
www.eclipse.org/recommenders
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> recommenders-dev mailing list
>>>>
recommenders-dev@xxxxxxxxxxx
>>>>
http://dev.eclipse.org/mailman/listinfo/recommenders-dev
>>>
>>>
>>>
>>>
>>> --
>>> Best Regards From Cheng Chen [
chengchendoc@xxxxxxxxx]
>>> _______________________________________________
>>> recommenders-dev mailing list
>>>
recommenders-dev@xxxxxxxxxxx
>>>
http://dev.eclipse.org/mailman/listinfo/recommenders-dev
>>>
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> recommenders-dev mailing list
>>>
recommenders-dev@xxxxxxxxxxx
>>>
http://dev.eclipse.org/mailman/listinfo/recommenders-dev
>>>
>>
>>
>>
>> --
>> Best Regards From Cheng Chen [
chengchendoc@xxxxxxxxx]
>> _______________________________________________
>> recommenders-dev mailing list
>>
recommenders-dev@xxxxxxxxxxx
>>
http://dev.eclipse.org/mailman/listinfo/recommenders-dev
>>
>>
>>
>> _______________________________________________
>> recommenders-dev mailing list
>>
recommenders-dev@xxxxxxxxxxx
>>
http://dev.eclipse.org/mailman/listinfo/recommenders-dev
>>
>
>
>
> --
> Best Regards From Cheng Chen [
chengchendoc@xxxxxxxxx]
>
> _______________________________________________
> recommenders-dev mailing list
>
recommenders-dev@xxxxxxxxxxx
>
http://dev.eclipse.org/mailman/listinfo/recommenders-dev
>
_______________________________________________
recommenders-dev mailing list
recommenders-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/recommenders-dev