From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 1EC36820A1 for ; Wed, 11 Sep 2013 12:14:31 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of kakadu.hafanana@gmail.com) identity=pra; client-ip=209.85.160.49; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="kakadu.hafanana@gmail.com"; x-sender="kakadu.hafanana@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of kakadu.hafanana@gmail.com designates 209.85.160.49 as permitted sender) identity=mailfrom; client-ip=209.85.160.49; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="kakadu.hafanana@gmail.com"; x-sender="kakadu.hafanana@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-pb0-f49.google.com) identity=helo; client-ip=209.85.160.49; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="kakadu.hafanana@gmail.com"; x-sender="postmaster@mail-pb0-f49.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgoCAERBMFLRVaAxk2dsb2JhbABbFoMpUbAUklWBFAgWDgEBAQEHCwsJFAQkgiUBAQMCQAEbEgsBAwwGBQsNDSEiAREBBQEKBAENBhMSAodbAQMPDKQLjFGDB4QrChknAwpkiCYBBQyPWgeEHQOJMIV8iEyBL45aGCmETTc X-IPAS-Result: AgoCAERBMFLRVaAxk2dsb2JhbABbFoMpUbAUklWBFAgWDgEBAQEHCwsJFAQkgiUBAQMCQAEbEgsBAwwGBQsNDSEiAREBBQEKBAENBhMSAodbAQMPDKQLjFGDB4QrChknAwpkiCYBBQyPWgeEHQOJMIV8iEyBL45aGCmETTc X-IronPort-AV: E=Sophos;i="4.90,883,1371074400"; d="scan'208";a="26467253" Received: from mail-pb0-f49.google.com ([209.85.160.49]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 11 Sep 2013 12:14:29 +0200 Received: by mail-pb0-f49.google.com with SMTP id xb4so8799166pbc.36 for ; Wed, 11 Sep 2013 03:14:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=JriNq0cfLoB5MDQc96ykU7ALXjhq+lbZYez+Z9rWO4Q=; b=PmSGw4XtDIXTeNsfGocj8VjDMmEiHi3/a+91xry+4Qyyfh7/KDOg1XEkHbVJkCrjg1 aGVkUQvdwhCNv/c0iOtRX/nD5t+EQN9jSox3Jv3Zmv+ivRoW4Ms4zjA/lVVtm7fbAR5b 3LWuQ0xu+6NCgoDH3CLjpAf9LTjmg+ZQDGhKNJ70bPvLOD4XWTF73NhPjzKaCGSE541D FJLCqaJGjhfOqAt/b1/arLt0bGOCAqEpzqEYP09H/x7PDBoYEocB0gb54zJ0ezoNWRg/ Z4MlizIPtZ1W2l3BrTppwxIAuKCLaw/G2z7P7MiOMhV/vbOqAg/YdHw97tg3JfGe3ML7 8avQ== MIME-Version: 1.0 X-Received: by 10.66.243.196 with SMTP id xa4mr2209024pac.174.1378894465775; Wed, 11 Sep 2013 03:14:25 -0700 (PDT) Received: by 10.70.50.71 with HTTP; Wed, 11 Sep 2013 03:14:25 -0700 (PDT) In-Reply-To: References: <20130910230928.2d51cd39@atmarama.noip.me> <20130911052437.GA9514@notk.org> Date: Wed, 11 Sep 2013 14:14:25 +0400 Message-ID: From: Kakadu To: David MENTRE Cc: OCaml mailing list Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [Caml-list] OCaml vs Ada and/or GUI options Hi! I think that QtQuick team have solved problems with decalrativity and business-logic. For example, you can declare _states_ which your application can have and declaratively specify how properties of your elements change after switching to every state. You can also declare some action for your menu items and toolbar buttons declaratively. You can declaratively join actions in exclusive groups to be sure that only one is enabled on every moment. And, of course, you can do some simple things like element borders and gradient filling declaratively. Kind regards, Kakadu On Wed, Sep 11, 2013 at 1:49 PM, David MENTRE wrote: > Hello Adrien, > > 2013/9/11 Adrien Nader : >> I'm trying to get a list of things that people find bad in (labl)gtk. >> Would you be able to put clear words on what you dislike? > > From past experiment, GUI of demexp OCaml application > (http://www.linux-france.org/~dmentre/demexp/latest-src/demexp-book-0.8.2.pdf > , look at part IV p. 90), about 5-8 years ago: > > 1. Lack of documentation. LablGTK doc says "look at C GTK doc". But > the lablgtk binding changes things compared to the C API, so this not > a one-to-one mapping neither. And the "obvious" changes weren't so > obvious to me. A tutorial made by a Korean guy IIRC helped a lot; > > 2. Verbosity of GTK: it takes a lot of code to put 2 buttons > together (probably not GTK specific). At one point I used the GTK > graphical tool (can't remember its name) to design the GUI graphically > and load it into OCaml as XML file. It improved a lot my productivity; > > 3. As other said, GTK is dead end: bad support of non-Linux > platforms, not a lot of developers, etc. It was very difficult to get > my labgtk application working on Windows. A windows developer helped > me a lot: picking the good versions of libraries, solve Windows > specific issues, etc. I couldn't have compiled my OCaml GTK GUI on > Windows without him. > > 4. The use of callbacks everywhere looks to me like writing > spaghetti code. I still hope somebody will write an > API/Framework/whatever were one writes declaratively how the GUI > should react and interact with application code, and all the needed > code is generated automatically. Adobe had such a tool at one point > for its internal use (i.e. for its applications). I don't know if > reactive approaches would help in that regard. > > > To answer original Gour question: I don't think anything in the OCaml > world fits the bill (safe, available at long term, documented, big > user community, ...). Should I do the same thing, I would write the > GUI as an external process (probably in C++ Qt) and use a > communication protocol to control it from my OCaml program. Or maybe > use the binding with Tk, if the graphical aspect has improved. > > I still hope that somebody will propose a sane environment to write > GUI apps. :-) > > Best regards, > david > > -- > Caml-list mailing list. Subscription management and archives: > https://sympa.inria.fr/sympa/arc/caml-list > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > Bug reports: http://caml.inria.fr/bin/caml-bugs