Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » generated content outline view
generated content outline view [message #420410] Sat, 28 June 2008 14:20 Go to next message
Lorenzo Bettini is currently offline Lorenzo BettiniFriend
Messages: 1813
Registered: July 2009
Location: Firenze, Italy
Senior Member
Hi

for an eclipse plugin (gengetopt_eclipse) that provides an editor for
gengetopt input files, I was trying to add some parsing functionalities
and also the outline view; since this relies on a model (which should be
built by the parser starting from the AST generated by the parser) I was
thinking of using emf functionalities; first of all, do you think it's a
feasible use/design? Does it make sense?

Moreover, I noticed that the outline viewer in the editor generated by
EMF is actually hardcoded in the generated editor so it cannot be
re-used outside the editor (I only need the content outline view
generated by emf, and not the editor generated by emf). I know that
it's quite easy to extract (copy/paste) and adapt the generated content
outline from the generated editor, but wouldn't it be better to have emf
generate the outline independently from the editor?

thanks in advance
cheers
Lorenzo

--
Lorenzo Bettini, PhD in Computer Science, DI, Univ. Torino
ICQ# lbetto, 16080134 (GNU/Linux User # 158233)
HOME: http://www.lorenzobettini.it MUSIC: http://www.purplesucker.com
http://www.myspace.com/supertrouperabba
BLOGS: http://tronprog.blogspot.com http://longlivemusic.blogspot.com
http://www.gnu.org/software/src-highlite
http://www.gnu.org/software/gengetopt
http://www.gnu.org/software/gengen http://doublecpp.sourceforge.net


Re: generated content outline view [message #420414 is a reply to message #420410] Sun, 29 June 2008 07:26 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33216
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------030804020203060105080000
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Lorenzo,

Comments below.

Lorenzo Bettini wrote:
> Hi
>
> for an eclipse plugin (gengetopt_eclipse) that provides an editor for
> gengetopt input files, I was trying to add some parsing
> functionalities and also the outline view; since this relies on a
> model (which should be built by the parser starting from the AST
> generated by the parser) I was thinking of using emf functionalities;
> first of all, do you think it's a feasible use/design? Does it make
> sense?
Yes, it's easy to hook into ResourceImpl.doSave/doLoad in order to
support loading and saving something other than XML.
>
> Moreover, I noticed that the outline viewer in the editor generated by
> EMF is actually hardcoded in the generated editor so it cannot be
> re-used outside the editor (I only need the content outline view
> generated by emf, and not the editor generated by emf).
There are lots of things in the editor that are assumed will only be
used there...
> I know that it's quite easy to extract (copy/paste) and adapt the
> generated content outline from the generated editor, but wouldn't it
> be better to have emf generate the outline independently from the editor?
There isn't actually anything model specific in the generated editor, so
it's even possible to have a generic outline. In fact, almost nothing
in the editor is model-specific, so there's already a bugzilla asking
for just a generic editor. You might want to add your suggestion there:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=108470

>
> thanks in advance
> cheers
> Lorenzo
>

--------------030804020203060105080000
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Lorenzo,<br>
<br>
Comments below. <br>
<br>
Lorenzo Bettini wrote:
<blockquote cite="mid:g45hbm$k8u$1@build.eclipse.org" type="cite">Hi
<br>
<br>
for an eclipse plugin (gengetopt_eclipse) that provides an editor for
gengetopt input files, I was trying to add some parsing functionalities
and also the outline view; since this relies on a model (which should
be built by the parser starting from the AST generated by the parser) I
was thinking of using emf functionalities; first of all, do you think
it's a feasible use/design?&nbsp; Does it make sense?
<br>
</blockquote>
Yes, it's easy to hook into ResourceImpl.doSave/doLoad in order to
support loading and saving something other than XML.<br>
<blockquote cite="mid:g45hbm$k8u$1@build.eclipse.org" type="cite"><br>
Moreover, I noticed that the outline viewer in the editor generated by
EMF is actually hardcoded in the generated editor so it cannot be
re-used outside the editor (I only need the content outline view
generated by emf, and not the editor generated by emf). <br>
</blockquote>
There are lots of things in the editor that are assumed will only be
used there...<br>
<blockquote cite="mid:g45hbm$k8u$1@build.eclipse.org" type="cite"> I
know that it's quite easy to extract (copy/paste) and adapt the
generated content outline from the generated editor, but wouldn't it be
better to have emf generate the outline independently from the editor?
<br>
</blockquote>
There isn't actually anything model specific in the generated editor,
so it's even possible to have a generic outline.&nbsp; In fact, almost
nothing in the editor is model-specific, so there's already a bugzilla
asking for just a generic editor.&nbsp; You might want to add your
suggestion there:<br>
<blockquote><a
href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=108470">https://bugs.eclipse.org/bugs/show_bug.cgi?id=108470</a><br>
</blockquote>
<blockquote cite="mid:g45hbm$k8u$1@build.eclipse.org" type="cite"><br>
thanks in advance
<br>
cheers
<br>
&nbsp;&nbsp;&nbsp;&nbsp;Lorenzo
<br>
<br>
</blockquote>
</body>
</html>

--------------030804020203060105080000--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: generated content outline view [message #420798 is a reply to message #420414] Thu, 10 July 2008 14:22 Go to previous message
Lorenzo Bettini is currently offline Lorenzo BettiniFriend
Messages: 1813
Registered: July 2009
Location: Firenze, Italy
Senior Member
Ed Merks wrote:
> Lorenzo,
>
> Comments below.
>
> Lorenzo Bettini wrote:
>> Hi
>>
>> for an eclipse plugin (gengetopt_eclipse) that provides an editor for
>> gengetopt input files, I was trying to add some parsing
>> functionalities and also the outline view; since this relies on a
>> model (which should be built by the parser starting from the AST
>> generated by the parser) I was thinking of using emf functionalities;
>> first of all, do you think it's a feasible use/design? Does it make
>> sense?
> Yes, it's easy to hook into ResourceImpl.doSave/doLoad in order to
> support loading and saving something other than XML.
>>
>

Actually I was thinking of creating the model during the parsing or
starting from the AST model generated by the parser...


Previous Topic:ChangeRecorder
Next Topic:Customize XML serialization / extendedMetaData / annotations
Goto Forum:
  


Current Time: Sun Sep 22 05:47:30 GMT 2024

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

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

Back to the top