[plt-scheme] Emacs modes and s-expression comments

From: Paulo J. Matos (pocmatos at gmail.com)
Date: Thu Feb 16 20:46:38 EST 2006

On 16/02/06, Robby Findler <robby at cs.uchicago.edu> wrote:
> At Thu, 16 Feb 2006 20:54:32 +0000, "Paulo J. Matos" wrote:
> > Indeed, I started a thread some time ago exactly with that question in
> > mind and he did tell me that he worked on it. I think the differences
> > were obvious. The GUI improved a lot but obviously, we always want
> > more! :)
> >
> > I've been thinking about the following, which I don't think it might
> > be hard but I'm not that sure. How hard would it be to implement, as
> > tool,  an extra horizontal frame (like interactions for example) that
> > would show up real-time documentation for what you are currently
> > typing. Imagine you write "define", that would probably show you
> > define syntax and maybe some comments on it.
> >
> > One of the difficulties would be to adjust the syntax shown to the
> > language the user is using. The syntax for define probably shift a bit
> > depending on the current language.
> >
> > Still, a first step would be to have a tool that at any moment is able
> > to get what the user is typing. If it is in a cond expression, an if
> > expression etc, so that a function can then be called to show doc
> > about that.
> >
> > Any comments if this is useful, on any todo list, etc?
> >
> > Which difficulties would one have to face?
>
> Sounds like a great idea. Most of the pieces are already there -- it
> will be a question doing something good to avoid destroying
> interactivity.
>
> To create a new sub-window in DrScheme, see the tools manual to see how
> to wire that window into an existing window. In particular, see
> drscheme:get/extend:extend-unit-frame.
>
> To see how to search in Help Desk, look at how the "f1" callback is
> implemented in plt/collects/drscheme/private/rep.ss.
>
> I think that you can start by queuing low-priority callbacks to handle
> the searches and you'll want to be a little clever to avoid queuing
> multiple callbacks at once -- just queue a single callback and use
> `set!' to change what the callback is going to do, once it gets
> serviced. If that takes away from interactivity too much, see how the
> online syntax coloring works. It is much more sophisticated, tho. Maybe
> some abstraction can be built from it, tho.
>
> Good luck.
>

Thanks for the tips, I'll be looking into it.

And I'll most surely get back to the list with more questions... :)

Paulo Matos

> Robby
>


--
Paulo Jorge Matos - pocm at sat inesc-id pt
Web: http://sat.inesc-id.pt/~pocm
Computer and Software Engineering
INESC-ID - SAT Group


Posted on the users mailing list.