Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Xtext editor for lightweight markup language
Xtext editor for lightweight markup language [message #1106186] Tue, 10 September 2013 20:18 Go to next message
Jeremie Bresson is currently offline Jeremie BressonFriend
Messages: 124
Registered: November 2010
Senior Member
Do you think that it is possible to create a Lightweight markup language [1] editor with Xtext?

I know a lot of this language have difficulties to define a proper grammar, but in my opinion it could also be a language inspired by these markup languages and not exactly one of them.

Do you know if something like this already exists?

Could the work done by Alex Lagarde (EMF Model of structured text [2]) be useful?

[1] http://en.wikipedia.org/wiki/Lightweight_markup_language
[2] http://alagarde.tumblr.com/post/54018014032/markup-bridge-from-wikitext-to-emf
Re: Xtext editor for lightweight markup language [message #1106325 is a reply to message #1106186] Wed, 11 September 2013 00:57 Go to previous messageGo to next message
Henrik Lindberg is currently offline Henrik LindbergFriend
Messages: 2509
Registered: July 2009
Senior Member
The lightweight markup languages typically depend heavily on lexing,
significant whitespace, and position of tokens (both individually and as
token pairs; i.e. there is one meaning if they are on same line, in an
unbroken sequence of text, or similar contextual rules).

The fit is far from ideal for Xtext.

I integrated support for Rdoc/markdown inside comments in cloudsmith /
geppetto @ github. I did not implement the text parser using Xtext, but
I integrated formatting into the overall Xtext process of doing formatting.

Have you looked Mylyn text?

(I would love to have something like Mou (Mac application) in Eclipse
instead of as a separate application - it is a markdown editor).

Regards
- henrik

On 2013-10-09 22:19, Jeremie Bresson wrote:
> Do you think that it is possible to create a Lightweight markup language
> [1] editor with Xtext?
>
> I know a lot of this language have difficulties to define a proper
> grammar, but in my opinion it could also be a language inspired by these
> markup languages and not exactly one of them.
>
> Do you know if something like this already exists?
>
> Could the work done by Alex Lagarde (EMF Model of structured text [2])
> be useful?
>
> [1] http://en.wikipedia.org/wiki/Lightweight_markup_language
> [2]
> http://alagarde.tumblr.com/post/54018014032/markup-bridge-from-wikitext-to-emf
>
>
Re: Xtext editor for lightweight markup language [message #1108938 is a reply to message #1106186] Sat, 14 September 2013 16:50 Go to previous messageGo to next message
Lorenzo Bettini is currently offline Lorenzo BettiniFriend
Messages: 1812
Registered: July 2009
Location: Firenze, Italy
Senior Member
On 10/09/2013 22:19, Jeremie Bresson wrote:
> Do you think that it is possible to create a Lightweight markup language
> [1] editor with Xtext?
>
> I know a lot of this language have difficulties to define a proper
> grammar, but in my opinion it could also be a language inspired by these
> markup languages and not exactly one of them.
>
> Do you know if something like this already exists?

You may want to have a look at Xdoc

https://github.com/RvonMassow/xDoc


--
Lorenzo Bettini, PhD in Computer Science, DI, Univ. Torino
HOME: http://www.lorenzobettini.it
Xtext Book:
http://www.packtpub.com/implementing-domain-specific-languages-with-xtext-and-xtend/book


Re: Xtext editor for lightweight markup language [message #1109336 is a reply to message #1108938] Sun, 15 September 2013 08:14 Go to previous messageGo to next message
Jeremie Bresson is currently offline Jeremie BressonFriend
Messages: 124
Registered: November 2010
Senior Member
@Lorenzo Bettini:
Thanks for the pointer on XDoc, I will try to have a look into it.
Where can I see text examples (that are valid XDoc snippet) to figure out the syntax?

@Henrik Lindberg:
Thanks for your explanations...

If I reverse the problem:
Given the "EMF Model of structured text" (which is the EMF version of the internal model used by Mylyn Docs WikiText), what kind of text representation can I obtain with the XText technologies?

I was thinking of:
{h2: Hello World}
This some {strong: structured} text.


PS: after having a look at the markup.ecore model, I think my example is still to far from the proposed model.
Re: Xtext editor for lightweight markup language [message #1110170 is a reply to message #1109336] Mon, 16 September 2013 13:27 Go to previous message
Lorenzo Bettini is currently offline Lorenzo BettiniFriend
Messages: 1812
Registered: July 2009
Location: Firenze, Italy
Senior Member
On 15/09/2013 10:14, Jeremie Bresson wrote:
> @Lorenzo Bettini:
> Thanks for the pointer on XDoc, I will try to have a look into it.
> Where can I see text examples (that are valid XDoc snippet) to figure
> out the syntax?

here are some files
http://git.eclipse.org/c/emf-parsley/org.eclipse.emf-parsley.git/tree/doc/org.eclipse.emf.parsley.doc/xdoc

or you may want to have a look at the xdoc files in the xtext sources:
Xtext help is written in Xdoc.

cheers
Lorenzo

--
Lorenzo Bettini, PhD in Computer Science, DI, Univ. Torino
HOME: http://www.lorenzobettini.it
Xtext Book:
http://www.packtpub.com/implementing-domain-specific-languages-with-xtext-and-xtend/book


Previous Topic:Simple example - generation problem
Next Topic:Find references across languages?
Goto Forum:
  


Current Time: Wed Apr 24 22:45:49 GMT 2024

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

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

Back to the top