Skip to main content



      Home
Home » Modeling » TMF (Xtext) » writing to IXtextDocument(writing to IXtextDocument)
writing to IXtextDocument [message #1006523] Thu, 31 January 2013 10:00 Go to next message
Eclipse UserFriend
I have I Xtext Document (eclipse editor) and i want to write to it a new value.
i can read the xtext node (ILeaf Node) but i don't know how to write to it.
Re: writing to IXtextDocument [message #1006530 is a reply to message #1006523] Thu, 31 January 2013 10:22 Go to previous messageGo to next message
Eclipse UserFriend
Am 31.01.13 16:00, schrieb Dana Klein:
> I have I Xtext Document (eclipse editor) and i want to write to it a new
> value. i can read the xtext node (ILeaf Node) but i don't know how to
> write to it.

You can set the text of the document. The node model cannot be modified.
The text change in the document will trigger a reparse.

Regards,
Sebastian
--
Looking for professional support for Xtext, Xtend or Eclipse Modeling?
Go visit: http://xtext.itemis.com
Re: writing to IXtextDocument [message #1006535 is a reply to message #1006530] Thu, 31 January 2013 10:41 Go to previous messageGo to next message
Eclipse UserFriend
i figured that as it doesn't have any setters but how can i edit the document? i want to do it in the code and not in the editor..
like the ProposalProvider that allow me to add code to the document
Re: writing to IXtextDocument [message #1006812 is a reply to message #1006535] Sat, 02 February 2013 05:30 Go to previous message
Eclipse UserFriend
What's wrong with IDocument.set() and IDocument.replace() ?


Am 31.01.13 16:41, schrieb Dana Klein:
> i figured that as it doesn't have any setters but how can i edit the
> document? i want to do it in the code and not in the editor.. like the
> ProposalProvider that allow me to add code to the document


--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com
Previous Topic:Get text from texteditor
Next Topic:How to turn an expression String into an Xtext object?
Goto Forum:
  


Current Time: Wed Jul 02 22:48:29 EDT 2025

Powered by FUDForum. Page generated in 0.06729 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top