Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [orion-dev] Orion editor with server-side parser ?

Hi Rémi,

Error markers and completion proposals are provided by implementing an Orion service. Services are inherently asynchronous, so yes -- you can keep the "real" work on your remote server, and just call it from the client.

Syntax highlighting is another matter. We experimented with asynchronous highlighting in the past: a service could asynchronously feed highlighting info into the editor, based on text changes. This allowed you to use arbitrary parsing logic, but the user experience was poor.

Instead, I would recommend trying the current declarative grammar-based approach. It allows the editor to update the syntax highlighting in realtime with no delay. While the grammar is more restrictive than a full-blown parser, we've found that a reasonable subset of most languages can be parsed using regexps and simple begin..end nesting blocks.

Regards,
Mark


On Mon, Jan 19, 2015 at 8:45 AM, Remi Vankeisbelck <VANKEISB@xxxxxxxxxx> wrote:
Hi,

We'd like to use Orion in order to support a custom language of ours. We already have a parser, completion engine etc. for this language. In fact, we even already have a JS editor, but it's based on content-editable div and has limitations. Therefore, we are looking at alternative "web-based text editors" that we could plug our services into, and let it handle all the dirty GUI business... Orion looks quite nice, and we're IBM as well, so we'd like to try it first.

Our "problem" is that our parser etc is written in Java, and runs in a server back-end. We have a protocol that allows our client-side editor to interact with the server : basically parse the text and send back highlighting infos, error markers, or completion proposals.

Does Orion support this kind of async, server-managed custom languages ?

I've googled a bit and seen in the doc that a grammar can be passed, or that the proposals could be customized. Can all this be done asynchronously, by communicating with a server ?

Thanks for any info.

Cheers

Rémi
Sauf indication contraire ci-dessus:/ Unless stated otherwise above:
Compagnie IBM France
Siège Social : 17 avenue de l'Europe, 92275 Bois-Colombes Cedex
RCS Nanterre 552 118 465
Forme Sociale : S.A.S.
Capital Social : 657.364.587 €
SIREN/SIRET : 552 118 465 03644 - Code NAF 6202A

_______________________________________________
orion-dev mailing list
orion-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/orion-dev


Back to the top