Home » Archived » IMP » "Mark occurrences" service in IMP
"Mark occurrences" service in IMP [message #511708] |
Tue, 02 February 2010 15:51 |
Margus Freudenthal Messages: 12 Registered: February 2010 |
Junior Member |
|
|
Hi again,
now I am stuck with implementing the "mark occurrences" service. For some reason, the service is only called once, when the DSL file is opened. If I navigate around the file, the service is not called again to update the occurrence display. I am using IMP language meta-tooling 0.1.96 and IMP runtime 0.1.102 (downloaded from the update site). Does this functionality work in the release or should I check out the SVN version?
Margus
|
|
|
Re: "Mark occurrences" service in IMP [message #516717 is a reply to message #511708] |
Wed, 24 February 2010 21:30 |
Robert M. Fuhrer Messages: 294 Registered: July 2009 |
Senior Member |
|
|
On 2/2/10 10:51 AM, Margus Freudenthal wrote:
> Hi again,
>
> now I am stuck with implementing the "mark occurrences" service. For
> some reason, the service is only called once, when the DSL file is
> opened. If I navigate around the file, the service is not called again
> to update the occurrence display. I am using IMP language meta-tooling
> 0.1.96 and IMP runtime 0.1.102 (downloaded from the update site). Does
> this functionality work in the release or should I check out the SVN
> version?
Hi there,
[Terribly sorry for not getting back to you sooner... my Thunderbird
install got mucked up and it took a while to get it back and healthy.]
This should work as you expect in the latest releases (e.g. the ones
available on the update site). In particular, I think it should be
working in 0.1.102, though there are newer versions available.
Is there anything in the Error Log that might indicate what's happening?
--
Cheers,
-- Bob
--------------------------------
Robert M. Fuhrer
Research Staff Member
Programming Technologies Dept.
IBM T.J. Watson Research Center
IDE Meta-tooling Platform Project Lead (http://www.eclipse.org/imp)
X10: Productive High-Performance Parallel Programming (http://x10.sf.net)
|
|
|
Re: "Mark occurrences" service in IMP [message #517108 is a reply to message #516717] |
Fri, 26 February 2010 09:45 |
Margus Freudenthal Messages: 12 Registered: February 2010 |
Junior Member |
|
|
Quote: |
This should work as you expect in the latest releases (e.g. the ones
available on the update site). In particular, I think it should be
working in 0.1.102, though there are newer versions available.
|
I upgraded to 0.1.103 yesterday and the problem persists.
Quote: |
Is there anything in the Error Log that might indicate what's happening?
|
No, there are no errors reported. I played with it today and noticed:
* If the mark occurrences service is called, the SourcePositionLocator is called for each of the returned nodes (and it returns correct answer). However, nothing is highlighted. Maybe it is just using colors black on white for highlighting matches?
* When I move the cursor around in the file, the mark occurrences service is not called.
* However, if I switch between different tabs in Eclipse (for example, click on the outline view and click back on the editor), then the mark occurrences service is called again.
Since I implemented the occurrence service from scratch, I am not very sure that I did everything correctly (maybe the runtime makes some additional assumptions that I do not fullfill).
Margus
|
|
|
Re: "Mark occurrences" service in IMP [message #517218 is a reply to message #517108] |
Fri, 26 February 2010 15:24 |
Robert M. Fuhrer Messages: 294 Registered: July 2009 |
Senior Member |
|
|
On 2/26/10 4:45 AM, Margus Freudenthal wrote:
> Quote:
>> This should work as you expect in the latest releases (e.g. the ones
>> available on the update site). In particular, I think it should be
>> working in 0.1.102, though there are newer versions available.
>
>
> I upgraded to 0.1.103 yesterday and the problem persists.
>
> Quote:
>> Is there anything in the Error Log that might indicate what's happening?
>
>
> No, there are no errors reported. I played with it today and noticed:
> * If the mark occurrences service is called, the SourcePositionLocator
> is called for each of the returned nodes (and it returns correct
> answer). However, nothing is highlighted. Maybe it is just using colors
> black on white for highlighting matches?
The highlighting should be a fairly noticeable color (green-ish, IIRC).
But it certainly does sound as though either it's not getting as far as
applying the text attributes, or the attributes got messed up somehow.
> * When I move the cursor around in the file, the mark occurrences
> service is not called.
Hmmm... that shouldn't be; needless to say, it should recompute the
occurrence set each time the text selection changes.
I'll take a look at the latest code and see what sort of behavior I get.
At any rate, sorry for the troubles, and thanks for the info!
> * However, if I switch between different tabs in Eclipse (for example,
> click on the outline view and click back on the editor), then the mark
> occurrences service is called again.
>
> Since I implemented the occurrence service from scratch, I am not very
> sure that I did everything correctly (maybe the runtime makes some
> additional assumptions that I do not fullfill).
--
Cheers,
-- Bob
--------------------------------
Robert M. Fuhrer
Research Staff Member
Programming Technologies Dept.
IBM T.J. Watson Research Center
IDE Meta-tooling Platform Project Lead (http://www.eclipse.org/imp)
X10: Productive High-Performance Parallel Programming (http://x10.sf.net)
|
|
|
Re: "Mark occurrences" service in IMP [message #559348 is a reply to message #511708] |
Thu, 16 September 2010 13:01 |
Margus Freudenthal Messages: 12 Registered: February 2010 |
Junior Member |
|
|
Hello again,
I experimented a bit with the latest IMP version from the update site. When I select the "Mark Occurrences" button on the toolbar, the mark occurrences service is called and occurrences are highlighted in green. However, when I move the cursor, the markings do not move -- the service is not called again and the highlighting also stays. When I deselect-select the mark occurrences button, the service is called and the highlighting moves to cursor. Interestingly, when I click between editor windows, the highlighting is again performed, but old highlighting also remains present. See the screenshot below for example of this cumulative marking.
Does this service work normally for other people? Given that I used custom ANTLR-based parser to implement language, can this be problem in my implementation?
Margus
|
|
|
Re: "Mark occurrences" service in IMP [message #577453 is a reply to message #516717] |
Fri, 26 February 2010 09:45 |
Margus Freudenthal Messages: 12 Registered: February 2010 |
Junior Member |
|
|
Quote:
> This should work as you expect in the latest releases (e.g. the ones
> available on the update site). In particular, I think it should be
> working in 0.1.102, though there are newer versions available.
I upgraded to 0.1.103 yesterday and the problem persists.
Quote:
> Is there anything in the Error Log that might indicate what's happening?
No, there are no errors reported. I played with it today and noticed:
* If the mark occurrences service is called, the SourcePositionLocator is called for each of the returned nodes (and it returns correct answer). However, nothing is highlighted. Maybe it is just using colors black on white for highlighting matches?
* When I move the cursor around in the file, the mark occurrences service is not called.
* However, if I switch between different tabs in Eclipse (for example, click on the outline view and click back on the editor), then the mark occurrences service is called again.
Since I implemented the occurrence service from scratch, I am not very sure that I did everything correctly (maybe the runtime makes some additional assumptions that I do not fullfill).
--
Margus
Margus
|
|
|
Re: "Mark occurrences" service in IMP [message #577475 is a reply to message #577453] |
Fri, 26 February 2010 15:24 |
Robert M. Fuhrer Messages: 294 Registered: July 2009 |
Senior Member |
|
|
On 2/26/10 4:45 AM, Margus Freudenthal wrote:
> Quote:
>> This should work as you expect in the latest releases (e.g. the ones
>> available on the update site). In particular, I think it should be
>> working in 0.1.102, though there are newer versions available.
>
>
> I upgraded to 0.1.103 yesterday and the problem persists.
>
> Quote:
>> Is there anything in the Error Log that might indicate what's happening?
>
>
> No, there are no errors reported. I played with it today and noticed:
> * If the mark occurrences service is called, the SourcePositionLocator
> is called for each of the returned nodes (and it returns correct
> answer). However, nothing is highlighted. Maybe it is just using colors
> black on white for highlighting matches?
The highlighting should be a fairly noticeable color (green-ish, IIRC).
But it certainly does sound as though either it's not getting as far as
applying the text attributes, or the attributes got messed up somehow.
> * When I move the cursor around in the file, the mark occurrences
> service is not called.
Hmmm... that shouldn't be; needless to say, it should recompute the
occurrence set each time the text selection changes.
I'll take a look at the latest code and see what sort of behavior I get.
At any rate, sorry for the troubles, and thanks for the info!
> * However, if I switch between different tabs in Eclipse (for example,
> click on the outline view and click back on the editor), then the mark
> occurrences service is called again.
>
> Since I implemented the occurrence service from scratch, I am not very
> sure that I did everything correctly (maybe the runtime makes some
> additional assumptions that I do not fullfill).
--
Cheers,
-- Bob
--------------------------------
Robert M. Fuhrer
Research Staff Member
Programming Technologies Dept.
IBM T.J. Watson Research Center
IDE Meta-tooling Platform Project Lead (http://www.eclipse.org/imp)
X10: Productive High-Performance Parallel Programming (http://x10.sf.net)
|
|
|
Goto Forum:
Current Time: Fri Apr 26 04:04:29 GMT 2024
Powered by FUDForum. Page generated in 0.04417 seconds
|