Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] Complex Numbers
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: CREGUT Pierre FTRD/DTL/LAN <pierre.cregut@r...>
Subject: Re: [Caml-list] Using HTML as a standard GUI for Ocaml
That's the way I program GUI now. I found I lost too much time with GUI 
that were supposed to be the standard way with CAML (do you remember 
Daniel's (de Rauglaudre) RT lib ?  the various versions of Tk libs, etc.).

Nowadays there is a browser (Netscape or IE) on any machine and most of the
time it is running anyway. This gives you distributed, multi user interfaces,
may be not for free but at least you will not have to rethink everything when
you need it. Furthermore you really get more independance between the 
contents and its presentation than with a regular GUI (unless you are
careful to design your application as two separate sub applications). XML
will improve the situation further.

HTML GUI has weaknesses (handling the back button, old contexts, etc.) but
they are relatively small. For bandwidth : I do not program video games. 

So I use a modified version of Daniel de Rauglaudre wserver using threads
instead of fork and a home brew
library for HTML where text is basically a stream of string but HTML
constructs are hided behind functions.
The major task of the library is to hide URLs behind a notion of callbacks 
with arguments and maintain notions of contexts (lifetime of a user
interaction).
Drawings are done with Thomas Boutel gd library sometimes with some DHTML
code for layering. Another solution for very dynamic parts is to use
a socket with a  java applet (a  generic graphics applet would be nice).

Pierre Crégut

PS> Another solution for the HTTP server is to use Jserv and program
an interface between CAML and Apache replacing the Java integration.
This is not difficult but I only experimented it briefly.
The major advantage is that you get all the apache modules for free (for
example so far I only have basic authentification with my server).

-- 
Pierre Cregut - pierre.cregut@rd.francetelecom.fr - +33 2 96 05 16 28
FTR&D - DTL/MSV - 2 avenue Pierre Marzin - 22307 Lannion Cedex - France
-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr