[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Texmacs-dev] Roadmap porting TeXmacs and the TMGUI API
From: |
Joris van der Hoeven |
Subject: |
[Texmacs-dev] Roadmap porting TeXmacs and the TMGUI API |
Date: |
Fri, 2 Aug 2002 16:19:49 +0200 (MET DST) |
Here follows a more precise roadmap about how to port TeXmacs
to a new toolkit and some generalities about the TMGUI API.
The roadmap refines the one in a previous thread.
As to the TMGUI API, I tend to agree with Stéphane that
1. We really should be able to see TeXmacs as a particular widget
for the toolkit (this is what the GUI needs from TeXmacs);
2. We might try to directly port TeXmacs to the new toolkit
instead of first porting the whole src/Window/X logic and
next the widgets.
In order to compensate 2, the TMGUI API should specify what
I already called a comprehensive collection of widget constructors.
That is precisely what TeXmacs will need from the GUI and
this is also what should be given a direct Guile/Scheme counterpart,
so that all widget construction logic can be transferred to
the extension language.
Here follows a concrete roadmap for implementations:
1. Remove virtually everything in src/Window except ps_device.
Remove virtually everything which depends on that in src/Edit
and src/Texmacs.
2. Create two Qt (or whatever) widgets to replace edit_interface and
tm_widget. The first one should do nothing. The second one should
be capable of displaying the first one in a canvas.
3. Verify that TeXmacs compiles and runs again; it will do nothing
interesting, but at least it should work again. At this point,
we got rid of X and are ready to replace it by something else
in a stepwise manner.
4. Progressively enrich the widget which replaces edit_interface with
all methods of ps_device (except maybe postscript graphics,
which may be postponed to step 6). Also enrich the interface between
the replacements of edit_interface and tm_widget, so that you can set
the extents of the main canvas. After this, you should be able to
display and scroll your TeXmacs documents by launching
texmacs some-old-file.tm &
5. Enrich the edit_interface with methods to retrieve keyboard and
mouse events. As to the keyboard events, you may start with
the most simple ones. Later, support should be added for
all possible keyboard modifiers. After this step,
you should be able to edit files again.
6. Replace the widget creation factory which is now in widget.hh by
a similar one based on the new toolkit and improve tm_widget
so that we again have menus, iconbars a footer, etc.
We might need an equivalent of "box_widget" for displaying
a box inside a widget in a read only manner (for the menu entries).
This box_widget should also be added to the TMGUI API.
After this point, and some final adjustments, TeXmacs has been
completely ported to the new toolkit.
7. Factor both the old and new implementations through a clean,
abstract TMGUI API. After this, other people may port TeXmacs
to the toolkit they want (Qt, Gtk, wxWindows, GNUstep, etc.),
just by conforming to this specification.
8. Further discussions on how to *improve* the TMGUI API.
This is where David will be regiven the occasion to
convince us of his far reached philosophy :^)
Stéphane: does this plan seems reasonable to you?
Are there some points which need further clarification?
I repropose to create a texmacs-tmgui subdirectory in
the CVS repository for the texmacs project at Savannah.
I suggest that you and anyone else who wants to participate
use this as a central point to give the above strategy a try.
As soon as sufficient progress has been made, we will sync
this branch with the main distribution in a similar way as
we did for nogencc and incorporate it into the main distribution.
- [Texmacs-dev] Roadmap porting TeXmacs and the TMGUI API,
Joris van der Hoeven <=