Re: [Caml-list] ocaml glade gtk3
Samuel Mimram <[email protected]> Tue, 23 Jul 2013 23:54:23 +0200
| Newsgroups | gmane.comp.lang.ocaml.lib.gtk |
|---|---|
| Message-ID | <CA+7PP=EqWTfgv+5_qEsoBFJk+-7EYbQRrEfEAKF9dHStyGcuCg@mail.gmail.com> |
Hi,
Just my 2 cents, I managed to get simple glade files generated by
glade3 working with lablgtk2 using the following makefile rule:
gui_glade.ml: gui.glade
cat gui.glade | sed 's/interface/glade-interface/' | sed
's/object/widget/' | sed 's/GtkBox/GtkVBox/' > gui2.glade
lablgladecc2 gui2.glade > $@
ocamlc -I +lablgtk2 -i $@ > $@i
Not ideal (I'd really like to see lablgtk3 out soon) but it might help!
Cheers,
Samuel.
On Fri, Jul 19, 2013 at 2:39 PM, <[email protected]> wrote:
> On 19/07/2013 12:04, Jacques Garrigue wrote:
>
> On 2013/07/19, at 18:58, [email protected] wrote:
>
> Hello,
>
> I was using ocaml + lablgtk2 + glade.
> Glade is a tool to graphically design user interfaces. It used to generate
> glade 2 files (designed for gtk2) until version 3.8. Then I used
> "lablgladecc2" to convert them in ocaml.
>
> Now "lablgladecc2" is not appropriate anymore starting with glade 3.10 that
> generates glade 3 files (designed for gtk3). I was using as a workaround
> "glade-gtk2" in ubuntu that still generated glade 2 files. But glade-gtk2 is
> not available anymore in debian, and is not supposed to be available forever
> in ubuntu.
>
> Also, lablgtk3 is still in development.
>
> What do you think is the most sensible thing to do (max benefits, less
> efforts) ?
>
> - wait for lablgtk3 with gtkbuilder support
> - wait for lablgtk3 without gtkbuilder support, forget glade, and hardcode
> all graphical windows (30 windows to convert maybe ?) in lablgtk3
> - forget glade, and hardcode all graphical windows (30 windows to convert
> maybe ?) in lablgtk2
> - other ?
>
> Unfortunately, I must say that lablgtk3 is not around the corner yet.
> There is a stub generator, which should make the transition easier,
> but there is still a lot of work if we want to keep some compatibility with
> gtk2,
> and I do not have much time to invest in it.
>
> The other option is to add gtkbuilder support to lablgtk2.
> I started once, but stopped thinking that moving to gtk3 would be faster.
> Since this is not the case, this may be worth it, as this should not be a
> big effort.
>
> Jacques
>
>
> If I understand well, there are already stubs to access gtk3. I think I
> would be interested in making a full transition to gtk3.
> - are those stubs the equivalent of Gtk* (GtkList, GtkMisc, GtkObject, ...)
> modules ?
> - what project should I start with ? who shall I contact ?
> - is there already a gtkbuilder implementation ?
>
> I would also appreciate to keep the ocaml "labl" way of wrapping functions
> in objects, etc. This is what you call the "compatibility with gtk2". How
> can this be done ?
> - Shall we start with gtk2 modules (GPango, GDraw, GObj, ...) such as , and
> modify it progressively to connect to gtk3 stubs ?
> - Or build directly from gtk3, using lablgtk2 as a reference ?
> - are there already some work on it ? where ?
>
> - How long would it take to port to gtk3 ? 1 full week, l full month, 1 full
> year ?
>
>
> All advice you could give me to help me start in helping with the project
> would be nice.
>
> Thanks,
> William
>
> _______________________________________________
> Lablgtk-list mailing list
> [email protected]
> https://lists.ocamlcore.org/cgi-bin/listinfo/lablgtk-list
>