On Mon, Mar 5, 2012 at 5:31 PM, Mark Macdonald <
mamacdon@xxxxxxxxx> wrote:
> This would be awesome. I miss "mark occurrences" too.
>
> There is a way to provide styling for the editor from a plugin -- the
> orion.edit.highlighter service [1], which is what powers the CodeMirror
> plugin. But this API won't solve your problem in its current state, for a
> few reasons:
>
> It can't combine contributions from multiple plugins.
> You can't write a plugin that just styles identifiers and expect someone
> else to provide the regular language syntax highlighting. You have to
> provide everything, or nothing.
> The annotation treatment is limited.
> You can supply styled regions to be styled as "errors" (squiggly line under
> the text) in the editor. But you can't specify annotations to appear in the
> overview ruler, which is important for marking occurrences.
>
> To do a decent job here, we'll have to pull out a more generic way of
> supplying styling. Or make "mark occurrences" into a first-class extension
> point that plugins can implement, but leave the presentation up to the Orion
> side. Maybe both of these.
>
> This extension is really a first crack, powerful enough to support the
> CodeMirror plugin, but no more. I'd be happy to evolve it into something
> more useful in 0.5.
>
> Mark
>
> [1]
>
http://wiki.eclipse.org/Orion/Documentation/Developer_Guide/Plugging_into_the_editor#orion.edit.highlighter
>
> On Mon, Mar 5, 2012 at 7:33 PM, Andrew Eisenberg <
andrew@xxxxxxxxxxxx>
> wrote:
>>
>> One thing that I have been missing in the Orion editor is mark
>> occurrences. When I select an identifier, I'd like to have all
>> occurrences highlighted in some way (just like in Eclipse's Java
>> editor). So, I started implementing a plugin for this. As a first
>> step, mark occurrences will just use a regular _expression_ to find
>> occurrences (and this makes it possible to work across languages and
>> content types, but will not have any smarts).
>>
>> I got far enough such that I have a plugin that spits occurrence
>> information to the console on all selection changes. However, I am
>> stuck now in that I don't see any infrastructure to add styling
>> information to a region of text. Is this currently possible?
>>
>> thanks,
>> Andrew
>> _______________________________________________
>> orion-dev mailing list
>>
orion-dev@xxxxxxxxxxx
>>
https://dev.eclipse.org/mailman/listinfo/orion-dev
>
>
>
> _______________________________________________
> orion-dev mailing list
>
orion-dev@xxxxxxxxxxx
>
https://dev.eclipse.org/mailman/listinfo/orion-dev
>
_______________________________________________
orion-dev mailing list
orion-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/orion-dev