[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Questions on Centaur



In article <2cakgu$9f8@sophia.inria.fr>, Marcus Rotzoll <rotzoll@fzi.de> writes:
=> we have some problems with Centaur 1.2 that we purchased from you.
=> Some help from you would be greatly appreciated.

Okay, i'll quickly answer the parts i know about and hope that others will
chime in for the rest.  [By the way, i consider Centaur a research tool and
a useful one at that, but then i'm biased! ;-)  Your purchase price covered 
the cost of having someone do up a streamer and print out the doc.]

Now onto the important part, your questions.

=> We would like Centaur to generate an editor for a specific language.
=> Is it possible for this editor to be stand-alone as an executable
=> program? 

No, Centaur can be used to develop an editor for a specific language
but your editor is "running under/within Centaur" and we are not "generating
an executable".  With an eventual passage to LeLisp v16 ---Centaur
runs on top of LeLisp 15.25 currently--- we would be able to generate
an executable but this is not foreseen for anytime soon.

=> We used the "ctedit" and later on the "ASF+SDF" system. We found out
=> that there is no direct editing in the "ctedit". In the ASF+SDF system
=> (GSE) we couldn't make an editor as an executable program and we couldn't
=> find out, how to add a ppml-specification for pretty-printing. Can you
=> help us with this problem?

In-line, or in place, editing within a ctedit will be available with the next
release of Centaur.  The ctedit was conceived initially as a centaur structure
editor, giving one only syntactically correct editing (copy-cut-paste) and 
one would use Emacs to do general textual edition, albeit in a separate window.

The Asf+Sdf environment does not use the ctedit graphical object but rather
the gse graphical object.  In this window, you can have in place editing but
the parsing is not done automatically at each carriage-return/line-feed but
rather on demand ---effectively the user gives the go-ahead to parse.  i don't
know how to use a ppml specification in a gse since they do not use the same 
same display list structure that is used by a ctedit formatter.  Their graphical
editor is completely different.  

=> Also, is Centaur able to complete a syntactical structure like for instance
=> a 'begin/end'; i.e. if 'begin' has been typed then 'end' should automatically
=> be added and the user should go on typing in the space in between?

Within Centaur, there is a guided editing mode that allows for template style
editing.  This is generated automatically based on the formalism structure.  You 
might want to check on "contrib/menumode" in your centaur directory.  There is
a small document that explains how this works.  This tool is currently
(in Centaur v1.2) more mouse driven than anything else, you click on the 
structures you want to introduce and it automatically advances you to the 
next placeholder in your program.  There are beginner and expert modes to aid
one in this task.  Current developments (again for the next release) include
a keyboard interface, where you type the menu/template entries rather than 
clicking.  However, once again this is structure-oriented.  Some of our
developers swear by guided editing, they develop centaur by programming
under centaur.  

=> Another question we have is: does Centaur allow for context-sensitive
=> information. For instance, is it possible to check that a variable used
=> somewhere in a program has been declared previously?

This kind of thing can be programmed under Centaur but we don't furnish this,
we furnish the primitives that make this possible.  There are primitives that
allow for matching (sub)trees.  

=> Perhaps there are already examples of structured editors being built
=> with Centaur. It would be helpful to get any examples of Centaur
=> applications. Surprisingly, the pico specification wasn't shippped with
=> the rest of the system.

Unfortunately, i can't give you examples that are not mine.  People develop
environments under Centaur and they (the specifications of the environment) 
are the property of the person who developed them.  You may have seen recently
i posted a list of languages for which environments (more or less complete) have  
been developed under Centaur.  Even this list (about 25 languages) may be 
incomplete.   Normally with the tape, you should have access to a number
of environments for the specification languages used by Centaur (PPML, Metal, 
Typol, SDF) and a small example given in the tutorial, Exp.  The centaur 
formalisms are under "centaur/tables/", while i believe Exp is found under
"contrib/Exp".   As far as pico, i assume this is used in asd+sdf, i am not 
an adept, and thus can't answer this question.  However, the SDF specifications 
seem to be provided under centaur/tables.

	i hope this helps clear things up a bit.   
	regards
	janet bertot