From: Mark Watson
Subject: why not use HTML for simple user interfaces
Date: 
Message-ID: <8hjnu7$jqf$1@nnrp1.deja.com>
I have been spending a few evenings lately experimenting with GUIs in
LispWorks. I agree with a few recent posters on:

  CAPI is cool, but requires constant experimentation
  CLIM is a little old-fashioned, but nicely portable

Anyway, I need a fairly simple GUI for a commercial product idea that I
am trying to work on in some spare time (don't even think of looking at
www.knowledgebooks.com, because it is not even close to being ready!)

Anyway, for my purposes (query inputs, display of strutured data, etc.)
I have decided to use a simple embedded web server with HTML form
generation to act as a menu, collect queries, etc.

Another nice thing about LispWorks is that the multi-threaded support
seems rock solid, no problems running an embedded web server.

I like simple solutions, and it looks like a few hundred lines of code
will meet my simple GUI requirements. Making a GUI browser based is
actually convienent; for example, bookmarking a URL like:

  http://localhost:8215

if the embedded web server is using 8215 drops you right into a HTML
forms-based user interface.

-Mark

PS. I was going to use Java for this project (I have written 4 Java
books, and I like Java in addition to LISP), but benchmarking prototype
code quickly convinced me that for my particular application, LISP was
faster, and LISP is a little better for AI-like code.


--
Mark Watson    www.markwatson.com


Sent via Deja.com http://www.deja.com/
Before you buy.

From: Fernando Rodríguez
Subject: Re: why not use HTML for simple user interfaces
Date: 
Message-ID: <393D755D.EF1A9EC@wanadoo.es>
Mark Watson escribi�:

> I have been spending a few evenings lately experimenting with GUIs in
> LispWorks. I agree with a few recent posters on:
>
>   CAPI is cool, but requires constant experimentation
>   CLIM is a little old-fashioned, but nicely portable
>
> Anyway, I need a fairly simple GUI for a commercial product idea that I
> am trying to work on in some spare time (don't even think of looking at
> www.knowledgebooks.com, because it is not even close to being ready!)
>
> Anyway, for my purposes (query inputs, display of strutured data, etc.)
> I have decided to use a simple embedded web server with HTML form
> generation to act as a menu, collect queries, etc.
>

What web server are you going to use? O:-)
From: Mark Watson
Subject: Re: why not use HTML for simple user interfaces
Date: 
Message-ID: <8hjvif$pnp$1@nnrp1.deja.com>
In article <················@wanadoo.es>,
  Fernando =?iso-8859-1?Q?Rodr=EDguez?= <···@wanadoo.es> wrote:
>
> What web server are you going to use? O:-)

I found a 30 line sample program, I think on the Harlequin/Xanalys web
site, that uses the comm and mp (threading) packages to implement a
simple TCP server.

I added about 40 lines of code to this to make it a mini-web server and
provide a simple HTML form. The whole thing will be about 200 lines of
code by the time the GUI is implemented.

Email me (my address is on my web site), if you want the source code.

You will need LispWorks to run it.

-Mark

--
Mark Watson    www.markwatson.com


Sent via Deja.com http://www.deja.com/
Before you buy.
From: Will Hartung
Subject: Re: why not use HTML for simple user interfaces
Date: 
Message-ID: <iPs%4.217433$bm.1338546@news1.alsv1.occa.home.com>
Mark Watson wrote in message <············@nnrp1.deja.com>...

>Anyway, for my purposes (query inputs, display of strutured data, etc.)
>I have decided to use a simple embedded web server with HTML form
>generation to act as a menu, collect queries, etc.


I dunno. In my experience, whenever something I was working on needed
"something simple", the simple something inevitably turned into a pandoras
box.

Oh, sure, things move along great in the beginning. The sun is shining, the
birds chirping. Then, you reach The Wall. That one little thing that you
didn't see coming that tends to turn the simple something into an
uncooperative nightmare. Of course, it's not really a wall, it's more like a
hill you're climbing, and you don't realize until you're 3/4 to the top that
the last little hurdle is a lot steeper than it looked on the map. Sure, you
should have seen it coming as the hill was slowly getting steeper and
steeper, but you felt you were getting So Close, that this bit of extra work
to make this late climb was worth it. I mean, how much farther can it really
be.

Then, it hits, you stand up, look around, and hindsight beats you about the
neck and head showing that if you had just made the left turn at
Albuquerque, 3 weeks ago, you wouldn't be stuck here on a cliff face in the
Rockies, rather you'd be in Kansas by now, drifting along the plains. Now
you have some real hard choices to make, and going backward may be looking
really good.

HTML works great for Simple Cases, but it really sucks hard when the going
gets tough. It's a real mish mash of paradigms and idioms, scripts and
syntaxes. Half are technology based, half are just browser workarounds, half
are rush to market and lack of design.

If you're unhappy the CAPI, then perhaps concocting an extensible comm layer
between Java and Lisp would be better time served, then you've got something
more robust than an HTML browser to let you do your GUI layout. The Lisp can
be your Model, and the Java can be your View and Controller (if you like tha
t method of GUI interaction).

Your Lisp doesn't really change, you can still use HTTP as your packet
protocol if you're happy with it. If your data volume isn't huge, then
communicating with S-exprs is a fine protocol. Real extensible. I hear folks
do a lot with S-exprs :-).

But, working with HTML can be so aggravating, that it seems it would be
worth the higher first step to make your application not only easier to
write up front, but easier to maintain and, particularly, easier to expand.
Plus, you get all those whizzy form painter tools and stuff from the IDEs
giving you more flexible widgets and whatnot compared to the basic set in
HTML.

It's not a panacea, but I think that the HTML side is still a bit of a mess.
The compelling reason for HTML for applications is distribution and
portablity, not necessarily functionality.

If your requirements are so limited that HTML will work, then feel free.
It's just that most of the time, those simple needs tend to be wolves in
cheap clothing.

If you're convinced about HTML, then at least consider porting AllegroServe
(it's pretty simple server, really) and using LSPs or one of the other
engines being developed (Craigs IMHO stuff may be a bit overkill, I think it
needs a seperate web server). Raise a couple of boats along with yours.

Luck!

Best Regards,

Will Hartung
(······@home.com)
From: Mark Watson
Subject: Re: why not use HTML for simple user interfaces
Date: 
Message-ID: <8hlohq$3b7$1@nnrp1.deja.com>
Hello Will,

re:

In article <·······················@news1.alsv1.occa.home.com>,
  "Will Hartung" <······@home.com> wrote:
> I dunno. In my experience, whenever something I was working on needed
> "something simple", the simple something inevitably turned into a
pandoras
> box.

It is a matter of understanding what the requirements are up front. I
have also written a few GUIs for Java by embedding a small web server
in an app; one advantage is being able to access services from any web
browser (security issues aside, for now), and supporting more than one
user at once.

Anyway, my app is basically a background service that runs continually.
The GUI is simple and generation of pure HTML fits the bill perfectly!

Thanks for your comments.

-Mark

--
Mark Watson    www.markwatson.com


Sent via Deja.com http://www.deja.com/
Before you buy.
From: Fernando Rodríguez
Subject: Re: why not use HTML for simple user interfaces
Date: 
Message-ID: <393FC58A.A78A471A@wanadoo.es>
Will Hartung escribi�:

>
> more robust than an HTML browser to let you do your GUI layout. The Lisp can
> be your Model, and the Java can be your View and Controller (if you like tha
> t method of GUI interaction).
>

What other methods exist? :-?
From: ···@usa.net
Subject: Re: why not use HTML for simple user interfaces
Date: 
Message-ID: <8hloem$335$1@nnrp1.deja.com>
Yes, HTML is a fine solution to simple GUI.
I used it for my portable inspect (and it doesn't need MP).
see http://clocc.sourceforge.net (clocc/src/cllib/inspect.lisp)

In article <············@nnrp1.deja.com>,
  Mark Watson <···········@my-deja.com> wrote:
> I have decided to use a simple embedded web server with HTML form
> generation to act as a menu, collect queries, etc.
>
> Another nice thing about LispWorks is that the multi-threaded support
> seems rock solid, no problems running an embedded web server.
>
> I like simple solutions, and it looks like a few hundred lines of code
> will meet my simple GUI requirements. Making a GUI browser based is
> actually convienent; for example, bookmarking a URL like:
>
>   http://localhost:8215
>
> if the embedded web server is using 8215 drops you right into a HTML
> forms-based user interface.


Sent via Deja.com http://www.deja.com/
Before you buy.