caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Re: [Caml-list] labltk for tk 8.4 BETA release
@ 2007-05-12 14:37 Jeffrey Loren Shaw
  2007-05-14 21:48 ` David Teller
  0 siblings, 1 reply; 5+ messages in thread
From: Jeffrey Loren Shaw @ 2007-05-12 14:37 UTC (permalink / raw)
  To: caml-list


* ease of installation 

http://downloads.activestate.com/ActiveTcl/Windows/8.3.5/ 

or for the beta labltk... 

http://downloads.activestate.com/ActiveTcl/Windows/8.4.14/ 

Yup that link should be updated. I don't think it should be bundled with 
ocaml, however. The end-user might already have it installed, or might not 
need it. But this is a decision for the ocaml devs. 

* Documentation 

You're right, it's not very good. I used the ocamlbrowser extensively to 
learn how to use labltk. It took me a lot of experimenting, and I'm still 
terrible at getting widgets laid out the way I want. 

I'm not sure how to do the documentation in an automated way without 
changing the grammar for widgets.src to allow ocamldoc comments. That's 
beyond my abilities, but I suppose it's a worthy project for someone. On the 
other hand, widgets.src is already very cluttered. 

* Other libraries 

I don't know anything about these, but again these are questions for the 
ocaml devs. 

Anyway, my focus right now is getting this beta version of labltk working 
correctly... there's a lot of functions to test. 

Now here's an idea... 

Instead of documenting labltk, which is difficult for the beginner ocaml 
programmer anyway, make a wrapper to make it more ocaml-y. I'm not sure if 
this would be easy or possible, but coercing labltk into one style of 
programming (preferably functional) could go a long way towards making it 
easier to learn for the beginner. Also the wrapper would potentially be 
easier to document. As I recall, the most difficult aspects of labltk are 
those that are imperative, eg: 

event functions are unit -> unit, (maybe this can't be avoided)
pack is difficult to deal with,
the need to use optionmenu and Textvariable.handle together is not obvious 

Another huge but useful project would be a type-safe parser for the outputs 
given by the Widget.configure_get functions. 

Now back to testing.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Caml-list] labltk for tk 8.4 BETA release
  2007-05-12 14:37 [Caml-list] labltk for tk 8.4 BETA release Jeffrey Loren Shaw
@ 2007-05-14 21:48 ` David Teller
  2007-05-15  8:08   ` Richard Jones
  0 siblings, 1 reply; 5+ messages in thread
From: David Teller @ 2007-05-14 21:48 UTC (permalink / raw)
  To: OCaml

On Sat, 2007-05-12 at 10:37 -0400, Jeffrey Loren Shaw wrote:
> Yup that link should be updated. I don't think it should be bundled with 
> ocaml, however. The end-user might already have it installed, or might not 
> need it. But this is a decision for the ocaml devs. 

Of course. The congratulations were for you. The wish list was for OCaml
Devs.


> Instead of documenting labltk, which is difficult for the beginner ocaml 
> programmer anyway, make a wrapper to make it more ocaml-y. I'm not sure if 
> this would be easy or possible, but coercing labltk into one style of 
> programming (preferably functional) could go a long way towards making it 
> easier to learn for the beginner. 

I'm currently thinking about the best way to write the equivalent of
JavaFX for OCaml : both the user-interface and the "new features" (e.g.
list comprehension, SQL-ish selections from data structures, etc.). The
user-interface part doesn't look too difficult. I'll start to work on
it... well, if I ever get time.

Cheers,
 David


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Caml-list] labltk for tk 8.4 BETA release
  2007-05-14 21:48 ` David Teller
@ 2007-05-15  8:08   ` Richard Jones
  2007-05-18 12:35     ` David Teller
  0 siblings, 1 reply; 5+ messages in thread
From: Richard Jones @ 2007-05-15  8:08 UTC (permalink / raw)
  To: David Teller; +Cc: OCaml

On Mon, May 14, 2007 at 11:48:49PM +0200, David Teller wrote:
> On Sat, 2007-05-12 at 10:37 -0400, Jeffrey Loren Shaw wrote:
> > Yup that link should be updated. I don't think it should be bundled with 
> > ocaml, however. The end-user might already have it installed, or might not 
> > need it. But this is a decision for the ocaml devs. 
> 
> Of course. The congratulations were for you. The wish list was for OCaml
> Devs.
> 
> 
> > Instead of documenting labltk, which is difficult for the beginner ocaml 
> > programmer anyway, make a wrapper to make it more ocaml-y. I'm not sure if 
> > this would be easy or possible, but coercing labltk into one style of 
> > programming (preferably functional) could go a long way towards making it 
> > easier to learn for the beginner. 
> 
> I'm currently thinking about the best way to write the equivalent of
> JavaFX for OCaml : both the user-interface and the "new features" (e.g.
> list comprehension, SQL-ish selections from data structures, etc.). The
> user-interface part doesn't look too difficult. I'll start to work on
> it... well, if I ever get time.

PG'OCaml does the SQL part: http://merjis.com/developers/pgocaml

Rich.

-- 
Richard Jones
Red Hat


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Caml-list] labltk for tk 8.4 BETA release
  2007-05-15  8:08   ` Richard Jones
@ 2007-05-18 12:35     ` David Teller
  0 siblings, 0 replies; 5+ messages in thread
From: David Teller @ 2007-05-18 12:35 UTC (permalink / raw)
  To: Richard Jones; +Cc: OCaml

On Tue, 2007-05-15 at 09:08 +0100, Richard Jones wrote:
> > I'm currently thinking about the best way to write the equivalent of
> > JavaFX for OCaml : both the user-interface and the "new features" (e.g.
> > list comprehension, SQL-ish selections from data structures, etc.). The
> > user-interface part doesn't look too difficult. I'll start to work on
> > it... well, if I ever get time.
> 
> PG'OCaml does the SQL part: http://merjis.com/developers/pgocaml

Actually, it doesn't.

What I'm talking about is applying SELECT to a OCaml (or, in that case,
Java) data structure, not to a SQL database. I'm not completely clear
about the semantics of the primitive, but it does look interesting.

Cheers,
 David


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Caml-list] labltk for tk 8.4 BETA release
  2007-05-12  2:56 Jeffrey Loren Shaw
@ 2007-05-12  9:19 ` David Teller
  0 siblings, 0 replies; 5+ messages in thread
From: David Teller @ 2007-05-12  9:19 UTC (permalink / raw)
  To: OCaml

That's a very good initiative.

In my mind, a few other things are missing in LablTk.

* Ease of installation.

 At the moment, beginners who wish to use LablTk under Windows (or who
are pressed to do this by, say, their teacher) must first find and
install the correct version by inferring the location of the installer
from an erroneous link hidden in the fine print of the documentation of
LablTk [1].

 As Tk is so important, i'm not sure why Tk is not bundled with OCaml's
Windows version. I suggest either bundling it or at least providing an
(up-to-date) link from OCaml's official download page [2]. 

* Documentation

 At the moment, LablTk has virtually no documentation. The page in the
manual is barely an overview and suggests reading the documentation of
Tcl/Tl. Which is all fine and good, except that it doesn't help with
types, I can't for the life of me remember how I found out that type
~~  color ~~ is actually a polymorphic variant ~~ `Color of string ~~
and beginners who learn OCaml as their first or second programming
language will never manage that much. 

 I suggest including a LablTk tutorial, perhaps inspired of [3] and
actually ocamldocumenting the .mli .


* Other libraries

 Ok, I might be asking a lot, but I personally consider that Graphics is
half-useless without CamlImages. I also consider that LablGl is a good
way to demonstrate the power of OCaml to students and perhaps to bring
them to something like game programming in OCaml. It requires CamlImages
for textures. The list could continue with LablGtk and plenty of others
but these two would be my personal priority. 

 Consequently, in my mind, both should be easy to install at the same
time as OCaml, which is not the case at the moment. Again, under Linux,
that's not much of a problem. Under Windows (and perhaps Mac OS X), it
is very much so.

 I don't suggest providing a package manager under Windows and I do know
about GODI but I also know that students will never be bothered to
install GODI. What I do suggest is just either adding inside OCaml's
Windows installer the option to add "extension libraries", with a short
description of what each extension does, or providing links to binary
installers from OCaml's download page.


What do you think ?

Cheers,
 David


[1] http://caml.inria.fr/pub/docs/manual-ocaml/manual042.html
[2] http://caml.inria.fr/ocaml/release.en.html
[3] http://www.cs.uiuc.edu/class/sp07/cs421/resources/labltk/

On Fri, 2007-05-11 at 22:56 -0400, Jeffrey Loren Shaw wrote:
> Dear Ocaml-ers, 
> 
> I've updated labltk to use some new widgets and commands that are available 
> in Tk 8.4. 
> 
> DIRECTIONS:
> get the ocaml 3.10 beta release
> extract the ocaml beta archive
> replace otherlibs/labltk with the one from the following link
> http://www.msu.edu/~shawjef3/labltk-8.4-BETA1.zip 
> 
> configure, make world, make install 
> 
> This is a BETA release, meaning that I believe I've implemented all the new 
> features, but I haven't tested them much. 
> 
> Here are my additions to the changelog: 
> 
> 2007-05-11 (*BETA release from shawjef3@msu.edu*)
>  ----------
> *labltk now requires Tk 8.4
> *added spinbox widget
> *added TkConsole module
> *added labelframe widget
> *added panedwindow widget
> *added functions tk_textCopy, tk_textCut, tk_text_Paste to the text widget
> *Removed CamlTk
> *Removed tkanim (depended on Camltk)
> *Removed Frx (Depended on Camltk)
> *Removed examples_camltk (Depended on Camltk) 
> 
> Please note that this is an unofficial release. I'm not affiliated with the 
> ocaml development team. 
> 
> Enjoy!
> Jeff
> 
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-05-18 12:35 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-05-12 14:37 [Caml-list] labltk for tk 8.4 BETA release Jeffrey Loren Shaw
2007-05-14 21:48 ` David Teller
2007-05-15  8:08   ` Richard Jones
2007-05-18 12:35     ` David Teller
  -- strict thread matches above, loose matches on Subject: below --
2007-05-12  2:56 Jeffrey Loren Shaw
2007-05-12  9:19 ` [Caml-list] " David Teller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).